Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 1 | # |
| 2 | # For a description of the syntax of this configuration file, |
| 3 | # see scripts/kbuild/config-language.txt. |
| 4 | # |
| 5 | |
| 6 | mainmenu "BusyBox Configuration" |
| 7 | |
Eric Andersen | 068b6b0 | 2002-12-13 22:53:28 +0000 | [diff] [blame] | 8 | config HAVE_DOT_CONFIG |
| 9 | bool |
| 10 | default y |
| 11 | |
Rob Landley | 9dc6913 | 2006-03-13 02:52:23 +0000 | [diff] [blame] | 12 | menu "Busybox Settings" |
Mike Frysinger | 72d59db | 2006-03-10 23:17:17 +0000 | [diff] [blame] | 13 | |
Denis Vlasenko | 7d219aa | 2006-10-05 10:17:08 +0000 | [diff] [blame] | 14 | config DESKTOP |
Bernhard Reutner-Fischer | 68532b3 | 2006-11-17 12:47:50 +0000 | [diff] [blame] | 15 | bool "Enable options for full-blown desktop systems" |
Denys Vlasenko | ba085c6 | 2010-07-21 08:58:11 +0200 | [diff] [blame] | 16 | default y |
Denis Vlasenko | 97a8dd3 | 2006-10-01 15:55:11 +0000 | [diff] [blame] | 17 | help |
| 18 | Enable options and features which are not essential. |
Denys Vlasenko | 3360226 | 2016-11-24 22:08:12 +0100 | [diff] [blame] | 19 | Select this if you plan to use busybox on full-blown desktop machine |
| 20 | with common Linux distro, which needs higher level of command-line |
| 21 | compatibility. |
| 22 | |
| 23 | If you are preparing your build to be used on an embedded box |
| 24 | where you have tighter control over the entire set of userspace |
Denys Vlasenko | f560422 | 2017-01-10 14:58:54 +0100 | [diff] [blame] | 25 | tools, you can unselect this option for smaller code size. |
Denis Vlasenko | 97a8dd3 | 2006-10-01 15:55:11 +0000 | [diff] [blame] | 26 | |
Denis Vlasenko | 3fd15e1 | 2008-08-09 16:15:14 +0000 | [diff] [blame] | 27 | config EXTRA_COMPAT |
| 28 | bool "Provide compatible behavior for rare corner cases (bigger code)" |
| 29 | default n |
| 30 | help |
| 31 | This option makes grep, sed etc handle rare corner cases |
| 32 | (embedded NUL bytes and such). This makes code bigger and uses |
| 33 | some GNU extensions in libc. You probably only need this option |
| 34 | if you plan to run busybox on desktop. |
| 35 | |
Denys Vlasenko | a8df4c0 | 2009-10-19 18:56:26 +0200 | [diff] [blame] | 36 | config INCLUDE_SUSv2 |
| 37 | bool "Enable obsolete features removed before SUSv3" |
| 38 | default y |
| 39 | help |
| 40 | This option will enable backwards compatibility with SuSv2, |
| 41 | specifically, old-style numeric options ('command -1 <file>') |
| 42 | will be supported in head, tail, and fold. (Note: should |
| 43 | affect renice too.) |
| 44 | |
Denys Vlasenko | aa7da73 | 2009-09-13 14:57:24 +0200 | [diff] [blame] | 45 | config USE_PORTABLE_CODE |
| 46 | bool "Avoid using GCC-specific code constructs" |
| 47 | default n |
| 48 | help |
| 49 | Use this option if you are trying to compile busybox with |
| 50 | compiler other than gcc. |
| 51 | If you do use gcc, this option may needlessly increase code size. |
| 52 | |
Denis Vlasenko | 7d219aa | 2006-10-05 10:17:08 +0000 | [diff] [blame] | 53 | config SHOW_USAGE |
Bernhard Reutner-Fischer | b9f4cd8 | 2011-11-09 20:23:38 +0100 | [diff] [blame] | 54 | bool "Show applet usage messages" |
Bernhard Reutner-Fischer | 81901a0 | 2006-03-31 18:43:55 +0000 | [diff] [blame] | 55 | default y |
| 56 | help |
Bernhard Reutner-Fischer | b9f4cd8 | 2011-11-09 20:23:38 +0100 | [diff] [blame] | 57 | Enabling this option, BusyBox applets will show terse help messages |
| 58 | when invoked with wrong arguments. |
| 59 | If you do not want to show any (helpful) usage message when |
| 60 | issuing wrong command syntax, you can say 'N' here, |
| 61 | saving approximately 7k. |
Bernhard Reutner-Fischer | 81901a0 | 2006-03-31 18:43:55 +0000 | [diff] [blame] | 62 | |
Denis Vlasenko | 7d219aa | 2006-10-05 10:17:08 +0000 | [diff] [blame] | 63 | config FEATURE_VERBOSE_USAGE |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 64 | bool "Show verbose applet usage messages" |
Denys Vlasenko | 2f32bf8 | 2010-06-06 04:14:28 +0200 | [diff] [blame] | 65 | default y |
Denys Vlasenko | 0e5ba08 | 2010-06-05 23:11:07 +0200 | [diff] [blame] | 66 | depends on SHOW_USAGE |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 67 | help |
Bernhard Reutner-Fischer | b9f4cd8 | 2011-11-09 20:23:38 +0100 | [diff] [blame] | 68 | All BusyBox applets will show verbose help messages when |
Bernhard Reutner-Fischer | 3e8669f | 2008-07-22 18:27:53 +0000 | [diff] [blame] | 69 | busybox is invoked with --help. This will add a lot of text to the |
| 70 | busybox binary. In the default configuration, this will add about |
Eric Andersen | 5360182 | 2002-12-05 21:12:42 +0000 | [diff] [blame] | 71 | 13k, but it can add much more depending on your configuration. |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 72 | |
Denis Vlasenko | 7d219aa | 2006-10-05 10:17:08 +0000 | [diff] [blame] | 73 | config FEATURE_COMPRESS_USAGE |
Rob Landley | 7e21d5f | 2006-04-27 23:34:46 +0000 | [diff] [blame] | 74 | bool "Store applet usage messages in compressed form" |
| 75 | default y |
Denis Vlasenko | 7d219aa | 2006-10-05 10:17:08 +0000 | [diff] [blame] | 76 | depends on SHOW_USAGE |
Rob Landley | 7e21d5f | 2006-04-27 23:34:46 +0000 | [diff] [blame] | 77 | help |
Bernhard Reutner-Fischer | b9f4cd8 | 2011-11-09 20:23:38 +0100 | [diff] [blame] | 78 | Store usage messages in .bz compressed form, uncompress them |
| 79 | on-the-fly when <applet> --help is called. |
Rob Landley | 7e21d5f | 2006-04-27 23:34:46 +0000 | [diff] [blame] | 80 | |
Rob Landley | c7ddefc | 2006-06-14 01:24:33 +0000 | [diff] [blame] | 81 | If you have a really tiny busybox with few applets enabled (and |
| 82 | bunzip2 isn't one of them), the overhead of the decompressor might |
Bernhard Reutner-Fischer | 3e8669f | 2008-07-22 18:27:53 +0000 | [diff] [blame] | 83 | be noticeable. Also, if you run executables directly from ROM |
| 84 | and have very little memory, this might not be a win. Otherwise, |
Rob Landley | c7ddefc | 2006-06-14 01:24:33 +0000 | [diff] [blame] | 85 | you probably want this. |
| 86 | |
Denys Vlasenko | 8e95068 | 2016-05-31 02:42:49 +0200 | [diff] [blame] | 87 | config BUSYBOX |
| 88 | bool "Include busybox applet" |
| 89 | default y |
| 90 | help |
| 91 | The busybox applet provides general help regarding busybox and |
| 92 | allows the included applets to be listed. It's also required |
| 93 | if applet links are to be installed at runtime. |
| 94 | |
| 95 | If you can live without these features disabling this will save |
| 96 | some space. |
| 97 | |
Denis Vlasenko | 7d219aa | 2006-10-05 10:17:08 +0000 | [diff] [blame] | 98 | config FEATURE_INSTALLER |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 99 | bool "Support --install [-s] to install applet links at runtime" |
Denys Vlasenko | 2f32bf8 | 2010-06-06 04:14:28 +0200 | [diff] [blame] | 100 | default y |
Denys Vlasenko | 8e95068 | 2016-05-31 02:42:49 +0200 | [diff] [blame] | 101 | depends on BUSYBOX |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 102 | help |
Bernhard Reutner-Fischer | 3e8669f | 2008-07-22 18:27:53 +0000 | [diff] [blame] | 103 | Enable 'busybox --install [-s]' support. This will allow you to use |
Eric Andersen | 5360182 | 2002-12-05 21:12:42 +0000 | [diff] [blame] | 104 | busybox at runtime to create hard links or symlinks for all the |
Denis Vlasenko | a7825f2 | 2007-06-16 13:56:51 +0000 | [diff] [blame] | 105 | applets that are compiled into busybox. |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 106 | |
Denys Vlasenko | d4d289a | 2010-10-12 04:18:05 +0200 | [diff] [blame] | 107 | config INSTALL_NO_USR |
| 108 | bool "Don't use /usr" |
| 109 | default n |
Denys Vlasenko | d4d289a | 2010-10-12 04:18:05 +0200 | [diff] [blame] | 110 | help |
Denys Vlasenko | c60e88a | 2010-12-05 23:11:15 +0100 | [diff] [blame] | 111 | Disable use of /usr. busybox --install and "make install" |
| 112 | will install applets only to /bin and /sbin, |
| 113 | never to /usr/bin or /usr/sbin. |
Denys Vlasenko | d4d289a | 2010-10-12 04:18:05 +0200 | [diff] [blame] | 114 | |
Bartosz Golaszewski | 265a74b | 2014-02-11 21:31:42 +0100 | [diff] [blame] | 115 | config PAM |
Denys Vlasenko | f560422 | 2017-01-10 14:58:54 +0100 | [diff] [blame] | 116 | bool "Support PAM (Pluggable Authentication Modules)" |
Bartosz Golaszewski | 265a74b | 2014-02-11 21:31:42 +0100 | [diff] [blame] | 117 | default n |
| 118 | help |
| 119 | Use PAM in some busybox applets (currently login and httpd) instead |
| 120 | of direct access to password database. |
| 121 | |
Denys Vlasenko | f3b92d3 | 2009-06-19 12:10:38 +0200 | [diff] [blame] | 122 | config LONG_OPTS |
Denys Vlasenko | f560422 | 2017-01-10 14:58:54 +0100 | [diff] [blame] | 123 | bool "Support --long-options" |
Bernhard Reutner-Fischer | 7470419 | 2006-06-16 14:03:23 +0000 | [diff] [blame] | 124 | default y |
Denis Vlasenko | c61852a | 2006-11-29 11:09:43 +0000 | [diff] [blame] | 125 | help |
| 126 | Enable this if you want busybox applets to use the gnu --long-option |
| 127 | style, in addition to single character -a -b -c style options. |
Bernhard Reutner-Fischer | 01d23ad | 2006-05-26 20:19:22 +0000 | [diff] [blame] | 128 | |
Denis Vlasenko | 7d219aa | 2006-10-05 10:17:08 +0000 | [diff] [blame] | 129 | config FEATURE_DEVPTS |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 130 | bool "Use the devpts filesystem for Unix98 PTYs" |
Rob Landley | c7ddefc | 2006-06-14 01:24:33 +0000 | [diff] [blame] | 131 | default y |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 132 | help |
Eric Andersen | 5360182 | 2002-12-05 21:12:42 +0000 | [diff] [blame] | 133 | Enable if you want BusyBox to use Unix98 PTY support. If enabled, |
| 134 | busybox will use /dev/ptmx for the master side of the pseudoterminal |
Bernhard Reutner-Fischer | 3e8669f | 2008-07-22 18:27:53 +0000 | [diff] [blame] | 135 | and /dev/pts/<number> for the slave side. Otherwise, BSD style |
Eric Andersen | 5360182 | 2002-12-05 21:12:42 +0000 | [diff] [blame] | 136 | /dev/ttyp<number> will be used. To use this option, you should have |
Rob Landley | d5b9b60 | 2006-05-31 23:23:42 +0000 | [diff] [blame] | 137 | devpts mounted. |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 138 | |
Denis Vlasenko | 7d219aa | 2006-10-05 10:17:08 +0000 | [diff] [blame] | 139 | config FEATURE_CLEAN_UP |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 140 | bool "Clean up all memory before exiting (usually not needed)" |
| 141 | default n |
| 142 | help |
Rob Landley | 1ab4c3d | 2006-02-08 18:50:17 +0000 | [diff] [blame] | 143 | As a size optimization, busybox normally exits without explicitly |
Bernhard Reutner-Fischer | 3e8669f | 2008-07-22 18:27:53 +0000 | [diff] [blame] | 144 | freeing dynamically allocated memory or closing files. This saves |
Rob Landley | 1ab4c3d | 2006-02-08 18:50:17 +0000 | [diff] [blame] | 145 | space since the OS will clean up for us, but it can confuse debuggers |
| 146 | like valgrind, which report tons of memory and resource leaks. |
| 147 | |
| 148 | Don't enable this unless you have a really good reason to clean |
Eric Andersen | e564211 | 2003-07-14 19:37:08 +0000 | [diff] [blame] | 149 | things up manually. |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 150 | |
Denys Vlasenko | d4d289a | 2010-10-12 04:18:05 +0200 | [diff] [blame] | 151 | config FEATURE_UTMP |
| 152 | bool "Support utmp file" |
| 153 | default y |
| 154 | help |
| 155 | The file /var/run/utmp is used to track who is currently logged in. |
| 156 | With this option on, certain applets (getty, login, telnetd etc) |
| 157 | will create and delete entries there. |
| 158 | "who" applet requires this option. |
| 159 | |
Denys Vlasenko | 8d0e0cd | 2011-01-25 23:21:46 +0100 | [diff] [blame] | 160 | config FEATURE_WTMP |
| 161 | bool "Support wtmp file" |
| 162 | default y |
| 163 | depends on FEATURE_UTMP |
| 164 | help |
| 165 | The file /var/run/wtmp is used to track when users have logged into |
| 166 | and logged out of the system. |
| 167 | With this option on, certain applets (getty, login, telnetd etc) |
| 168 | will append new entries there. |
| 169 | "last" applet requires this option. |
| 170 | |
Denis Vlasenko | 10457b9 | 2007-03-27 22:01:31 +0000 | [diff] [blame] | 171 | config FEATURE_PIDFILE |
| 172 | bool "Support writing pidfiles" |
Denys Vlasenko | 2f32bf8 | 2010-06-06 04:14:28 +0200 | [diff] [blame] | 173 | default y |
Denis Vlasenko | 10457b9 | 2007-03-27 22:01:31 +0000 | [diff] [blame] | 174 | help |
Denis Vlasenko | bb23c06 | 2007-08-15 20:05:37 +0000 | [diff] [blame] | 175 | This option makes some applets (e.g. crond, syslogd, inetd) write |
Anthony G. Basile | 12677ac | 2012-12-10 14:49:39 -0500 | [diff] [blame] | 176 | a pidfile at the configured PID_FILE_PATH. It has no effect |
| 177 | on applets which require pidfiles to run. |
| 178 | |
| 179 | config PID_FILE_PATH |
| 180 | string "Path to directory for pidfile" |
| 181 | default "/var/run" |
| 182 | depends on FEATURE_PIDFILE |
| 183 | help |
| 184 | This is the default path where pidfiles are created. Applets which |
| 185 | allow you to set the pidfile path on the command line will override |
| 186 | this value. The option has no effect on applets that require you to |
| 187 | specify a pidfile path. |
Denis Vlasenko | 10457b9 | 2007-03-27 22:01:31 +0000 | [diff] [blame] | 188 | |
Denis Vlasenko | 7d219aa | 2006-10-05 10:17:08 +0000 | [diff] [blame] | 189 | config FEATURE_SUID |
Denys Vlasenko | f560422 | 2017-01-10 14:58:54 +0100 | [diff] [blame] | 190 | bool "Support SUID/SGID handling" |
Denys Vlasenko | 2f32bf8 | 2010-06-06 04:14:28 +0200 | [diff] [blame] | 191 | default y |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 192 | help |
Rob Landley | d5b9b60 | 2006-05-31 23:23:42 +0000 | [diff] [blame] | 193 | With this option you can install the busybox binary belonging |
Denys Vlasenko | d4d289a | 2010-10-12 04:18:05 +0200 | [diff] [blame] | 194 | to root with the suid bit set, enabling some applets to perform |
| 195 | root-level operations even when run by ordinary users |
| 196 | (for example, mounting of user mounts in fstab needs this). |
| 197 | |
Denys Vlasenko | 5ca853e | 2013-01-17 10:24:51 +0100 | [diff] [blame] | 198 | Busybox will automatically drop privileges for applets |
Denys Vlasenko | d4d289a | 2010-10-12 04:18:05 +0200 | [diff] [blame] | 199 | that don't need root access. |
Rob Landley | d5b9b60 | 2006-05-31 23:23:42 +0000 | [diff] [blame] | 200 | |
Bernhard Reutner-Fischer | aa2a1c0 | 2008-10-24 19:48:47 +0000 | [diff] [blame] | 201 | If you are really paranoid and don't want to do this, build two |
Rob Landley | d5b9b60 | 2006-05-31 23:23:42 +0000 | [diff] [blame] | 202 | busybox binaries with different applets in them (and the appropriate |
| 203 | symlinks pointing to each binary), and only set the suid bit on the |
Denys Vlasenko | d4d289a | 2010-10-12 04:18:05 +0200 | [diff] [blame] | 204 | one that needs it. |
| 205 | |
Denys Vlasenko | 3b5acaa | 2011-01-18 13:52:48 +0100 | [diff] [blame] | 206 | The applets which require root rights (need suid bit or |
| 207 | to be run by root) and will refuse to execute otherwise: |
| 208 | crontab, login, passwd, su, vlock, wall. |
Bernhard Reutner-Fischer | aa2a1c0 | 2008-10-24 19:48:47 +0000 | [diff] [blame] | 209 | |
Denys Vlasenko | 3b5acaa | 2011-01-18 13:52:48 +0100 | [diff] [blame] | 210 | The applets which will use root rights if they have them |
| 211 | (via suid bit, or because run by root), but would try to work |
| 212 | without root right nevertheless: |
| 213 | findfs, ping[6], traceroute[6], mount. |
| 214 | |
| 215 | Note that if you DONT select this option, but DO make busybox |
| 216 | suid root, ALL applets will run under root, which is a huge |
| 217 | security hole (think "cp /some/file /etc/passwd"). |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 218 | |
Denis Vlasenko | 7d219aa | 2006-10-05 10:17:08 +0000 | [diff] [blame] | 219 | config FEATURE_SUID_CONFIG |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 220 | bool "Runtime SUID/SGID configuration via /etc/busybox.conf" |
Denys Vlasenko | e0238f8 | 2011-05-14 15:23:55 +0200 | [diff] [blame] | 221 | default y |
Denis Vlasenko | 7d219aa | 2006-10-05 10:17:08 +0000 | [diff] [blame] | 222 | depends on FEATURE_SUID |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 223 | help |
Rob Landley | d5b9b60 | 2006-05-31 23:23:42 +0000 | [diff] [blame] | 224 | Allow the SUID / SGID state of an applet to be determined at runtime |
Bernhard Reutner-Fischer | 3e8669f | 2008-07-22 18:27:53 +0000 | [diff] [blame] | 225 | by checking /etc/busybox.conf. (This is sort of a poor man's sudo.) |
Rob Landley | d5b9b60 | 2006-05-31 23:23:42 +0000 | [diff] [blame] | 226 | The format of this file is as follows: |
Eric Andersen | e527207 | 2003-07-22 22:15:21 +0000 | [diff] [blame] | 227 | |
Denys Vlasenko | d83aff1 | 2011-05-16 13:53:19 +0200 | [diff] [blame] | 228 | APPLET = [Ssx-][Ssx-][x-] [USER.GROUP] |
Denys Vlasenko | 3770b6b | 2011-05-16 13:19:25 +0200 | [diff] [blame] | 229 | |
Denys Vlasenko | d83aff1 | 2011-05-16 13:53:19 +0200 | [diff] [blame] | 230 | s: USER or GROUP is allowed to execute APPLET. |
| 231 | APPLET will run under USER or GROUP |
| 232 | (reagardless of who's running it). |
| 233 | S: USER or GROUP is NOT allowed to execute APPLET. |
Denys Vlasenko | 3770b6b | 2011-05-16 13:19:25 +0200 | [diff] [blame] | 234 | APPLET will run under USER or GROUP. |
Denys Vlasenko | d83aff1 | 2011-05-16 13:53:19 +0200 | [diff] [blame] | 235 | This option is not very sensical. |
| 236 | x: USER/GROUP/others are allowed to execute APPLET. |
Denys Vlasenko | 3770b6b | 2011-05-16 13:19:25 +0200 | [diff] [blame] | 237 | No UID/GID change will be done when it is run. |
Denys Vlasenko | d83aff1 | 2011-05-16 13:53:19 +0200 | [diff] [blame] | 238 | -: USER/GROUP/others are not allowed to execute APPLET. |
Eric Andersen | 5043ea1 | 2005-06-23 19:15:40 +0000 | [diff] [blame] | 239 | |
Eric Andersen | e527207 | 2003-07-22 22:15:21 +0000 | [diff] [blame] | 240 | An example might help: |
| 241 | |
| 242 | [SUID] |
Bernhard Reutner-Fischer | 3e8669f | 2008-07-22 18:27:53 +0000 | [diff] [blame] | 243 | su = ssx root.0 # applet su can be run by anyone and runs with |
| 244 | # euid=0/egid=0 |
Eric Andersen | e527207 | 2003-07-22 22:15:21 +0000 | [diff] [blame] | 245 | su = ssx # exactly the same |
| 246 | |
Bernhard Reutner-Fischer | 3e8669f | 2008-07-22 18:27:53 +0000 | [diff] [blame] | 247 | mount = sx- root.disk # applet mount can be run by root and members |
Denys Vlasenko | d83aff1 | 2011-05-16 13:53:19 +0200 | [diff] [blame] | 248 | # of group disk (but not anyone else) |
| 249 | # and runs with euid=0 (egid is not changed) |
Eric Andersen | e527207 | 2003-07-22 22:15:21 +0000 | [diff] [blame] | 250 | |
| 251 | cp = --- # disable applet cp for everyone |
| 252 | |
Rob Landley | fdc4c20 | 2005-04-29 19:48:29 +0000 | [diff] [blame] | 253 | The file has to be owned by user root, group root and has to be |
| 254 | writeable only by root: |
Denis Vlasenko | 6cee58e | 2007-11-04 15:43:26 +0000 | [diff] [blame] | 255 | (chown 0.0 /etc/busybox.conf; chmod 600 /etc/busybox.conf) |
Rob Landley | fdc4c20 | 2005-04-29 19:48:29 +0000 | [diff] [blame] | 256 | The busybox executable has to be owned by user root, group |
| 257 | root and has to be setuid root for this to work: |
Denis Vlasenko | 6cee58e | 2007-11-04 15:43:26 +0000 | [diff] [blame] | 258 | (chown 0.0 /bin/busybox; chmod 4755 /bin/busybox) |
Rob Landley | fdc4c20 | 2005-04-29 19:48:29 +0000 | [diff] [blame] | 259 | |
Eric Andersen | e527207 | 2003-07-22 22:15:21 +0000 | [diff] [blame] | 260 | Robert 'sandman' Griebl has more information here: |
| 261 | <url: http://www.softforge.de/bb/suid.html >. |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 262 | |
Denis Vlasenko | 7d219aa | 2006-10-05 10:17:08 +0000 | [diff] [blame] | 263 | config FEATURE_SUID_CONFIG_QUIET |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 264 | bool "Suppress warning message if /etc/busybox.conf is not readable" |
Rob Landley | d5b9b60 | 2006-05-31 23:23:42 +0000 | [diff] [blame] | 265 | default y |
Denis Vlasenko | 7d219aa | 2006-10-05 10:17:08 +0000 | [diff] [blame] | 266 | depends on FEATURE_SUID_CONFIG |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 267 | help |
Bernhard Reutner-Fischer | 3e8669f | 2008-07-22 18:27:53 +0000 | [diff] [blame] | 268 | /etc/busybox.conf should be readable by the user needing the SUID, |
| 269 | check this option to avoid users to be notified about missing |
| 270 | permissions. |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 271 | |
Denis Vlasenko | 7d219aa | 2006-10-05 10:17:08 +0000 | [diff] [blame] | 272 | config SELINUX |
Eric Andersen | 9e48045 | 2003-07-03 10:07:04 +0000 | [diff] [blame] | 273 | bool "Support NSA Security Enhanced Linux" |
| 274 | default n |
Denys Vlasenko | e3b1a1f | 2011-02-26 22:24:08 +0100 | [diff] [blame] | 275 | select PLATFORM_LINUX |
Eric Andersen | 9e48045 | 2003-07-03 10:07:04 +0000 | [diff] [blame] | 276 | help |
Bernhard Reutner-Fischer | 3e8669f | 2008-07-22 18:27:53 +0000 | [diff] [blame] | 277 | Enable support for SELinux in applets ls, ps, and id. Also provide |
Rob Landley | 24b0a95 | 2006-03-29 15:35:23 +0000 | [diff] [blame] | 278 | the option of compiling in SELinux applets. |
Eric Andersen | 9e48045 | 2003-07-03 10:07:04 +0000 | [diff] [blame] | 279 | |
Rob Landley | 24b0a95 | 2006-03-29 15:35:23 +0000 | [diff] [blame] | 280 | If you do not have a complete SELinux userland installed, this stuff |
Denys Vlasenko | 18b699c | 2014-02-25 17:31:22 +0100 | [diff] [blame] | 281 | will not compile. Specifially, libselinux 1.28 or better is |
Rob Landley | 24b0a95 | 2006-03-29 15:35:23 +0000 | [diff] [blame] | 282 | directly required by busybox. If the installation is located in a |
| 283 | non-standard directory, provide it by invoking make as follows: |
| 284 | CFLAGS=-I<libselinux-include-path> \ |
| 285 | LDFLAGS=-L<libselinux-lib-path> \ |
| 286 | make |
Eric Andersen | 31d898f | 2004-02-05 00:18:26 +0000 | [diff] [blame] | 287 | |
| 288 | Most people will leave this set to 'N'. |
| 289 | |
Denis Vlasenko | 80d14be | 2007-04-10 23:03:30 +0000 | [diff] [blame] | 290 | config FEATURE_PREFER_APPLETS |
Denis Vlasenko | 2f0c0d0 | 2007-01-21 00:41:04 +0000 | [diff] [blame] | 291 | bool "exec prefers applets" |
| 292 | default n |
| 293 | help |
| 294 | This is an experimental option which directs applets about to |
| 295 | call 'exec' to try and find an applicable busybox applet before |
Denis Vlasenko | 92c0b82 | 2007-05-08 17:27:17 +0000 | [diff] [blame] | 296 | searching the PATH. This is typically done by exec'ing |
| 297 | /proc/self/exe. |
| 298 | This may affect shell, find -exec, xargs and similar applets. |
| 299 | They will use applets even if /bin/<applet> -> busybox link |
| 300 | is missing (or is not a link to busybox). However, this causes |
| 301 | problems in chroot jails without mounted /proc and with ps/top |
| 302 | (command name can be shown as 'exe' for applets started this way). |
Denis Vlasenko | 2f0c0d0 | 2007-01-21 00:41:04 +0000 | [diff] [blame] | 303 | |
Denis Vlasenko | 7d219aa | 2006-10-05 10:17:08 +0000 | [diff] [blame] | 304 | config BUSYBOX_EXEC_PATH |
Rob Landley | c7ddefc | 2006-06-14 01:24:33 +0000 | [diff] [blame] | 305 | string "Path to BusyBox executable" |
| 306 | default "/proc/self/exe" |
| 307 | help |
| 308 | When Busybox applets need to run other busybox applets, BusyBox |
Bernhard Reutner-Fischer | 3e8669f | 2008-07-22 18:27:53 +0000 | [diff] [blame] | 309 | sometimes needs to exec() itself. When the /proc filesystem is |
Rob Landley | c7ddefc | 2006-06-14 01:24:33 +0000 | [diff] [blame] | 310 | mounted, /proc/self/exe always points to the currently running |
Bernhard Reutner-Fischer | 3e8669f | 2008-07-22 18:27:53 +0000 | [diff] [blame] | 311 | executable. If you haven't got /proc, set this to wherever you |
Rob Landley | c7ddefc | 2006-06-14 01:24:33 +0000 | [diff] [blame] | 312 | want to run BusyBox from. |
| 313 | |
Denis Vlasenko | a7825f2 | 2007-06-16 13:56:51 +0000 | [diff] [blame] | 314 | # These are auto-selected by other options |
| 315 | |
| 316 | config FEATURE_SYSLOG |
Denis Vlasenko | 35a064b | 2008-11-06 00:49:59 +0000 | [diff] [blame] | 317 | bool #No description makes it a hidden option |
Denis Vlasenko | a7825f2 | 2007-06-16 13:56:51 +0000 | [diff] [blame] | 318 | default n |
Denis Vlasenko | 35a064b | 2008-11-06 00:49:59 +0000 | [diff] [blame] | 319 | #help |
| 320 | # This option is auto-selected when you select any applet which may |
| 321 | # send its output to syslog. You do not need to select it manually. |
Denis Vlasenko | a7825f2 | 2007-06-16 13:56:51 +0000 | [diff] [blame] | 322 | |
| 323 | config FEATURE_HAVE_RPC |
Denis Vlasenko | 35a064b | 2008-11-06 00:49:59 +0000 | [diff] [blame] | 324 | bool #No description makes it a hidden option |
Denis Vlasenko | a7825f2 | 2007-06-16 13:56:51 +0000 | [diff] [blame] | 325 | default n |
Denis Vlasenko | 35a064b | 2008-11-06 00:49:59 +0000 | [diff] [blame] | 326 | #help |
| 327 | # This is automatically selected if any of enabled applets need it. |
| 328 | # You do not need to select it manually. |
Denis Vlasenko | a7825f2 | 2007-06-16 13:56:51 +0000 | [diff] [blame] | 329 | |
Kang-Che Sung | 4d06b31 | 2017-01-07 15:16:46 +0800 | [diff] [blame] | 330 | config PLATFORM_LINUX |
| 331 | bool #No description makes it a hidden option |
| 332 | default n |
| 333 | #help |
| 334 | # For the most part, busybox requires only POSIX compatibility |
| 335 | # from the target system, but some applets and features use |
| 336 | # Linux-specific interfaces. |
| 337 | # |
| 338 | # This is automatically selected if any applet or feature requires |
| 339 | # Linux-specific interfaces. You do not need to select it manually. |
| 340 | |
Denys Vlasenko | 3360226 | 2016-11-24 22:08:12 +0100 | [diff] [blame] | 341 | comment 'Build Options' |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 342 | |
Denis Vlasenko | 7d219aa | 2006-10-05 10:17:08 +0000 | [diff] [blame] | 343 | config STATIC |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 344 | bool "Build BusyBox as a static binary (no shared libs)" |
| 345 | default n |
| 346 | help |
Eric Andersen | c7bda1c | 2004-03-15 08:29:22 +0000 | [diff] [blame] | 347 | If you want to build a static BusyBox binary, which does not |
| 348 | use or require any shared libraries, then enable this option. |
Eric Andersen | 88c916b | 2003-10-22 09:58:56 +0000 | [diff] [blame] | 349 | This can cause BusyBox to be considerably larger, so you should |
Eric Andersen | e527207 | 2003-07-22 22:15:21 +0000 | [diff] [blame] | 350 | leave this option false unless you have a good reason (i.e. |
| 351 | your target platform does not support shared libraries, or |
| 352 | you are building an initrd which doesn't need anything but |
| 353 | BusyBox, etc). |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 354 | |
Eric Andersen | e527207 | 2003-07-22 22:15:21 +0000 | [diff] [blame] | 355 | Most people will leave this set to 'N'. |
| 356 | |
Denis Vlasenko | 1da86d2 | 2008-06-04 11:28:24 +0000 | [diff] [blame] | 357 | config PIE |
| 358 | bool "Build BusyBox as a position independent executable" |
| 359 | default n |
| 360 | depends on !STATIC |
| 361 | help |
Gilles Espinasse | 26b80e8 | 2011-02-13 22:54:37 +0100 | [diff] [blame] | 362 | Hardened code option. PIE binaries are loaded at a different |
| 363 | address at each invocation. This has some overhead, |
| 364 | particularly on x86-32 which is short on registers. |
| 365 | |
Denis Vlasenko | 1da86d2 | 2008-06-04 11:28:24 +0000 | [diff] [blame] | 366 | Most people will leave this set to 'N'. |
| 367 | |
Denis Vlasenko | d2c450c | 2008-01-08 20:32:12 +0000 | [diff] [blame] | 368 | config NOMMU |
| 369 | bool "Force NOMMU build" |
| 370 | default n |
| 371 | help |
| 372 | Busybox tries to detect whether architecture it is being |
| 373 | built against supports MMU or not. If this detection fails, |
| 374 | or if you want to build NOMMU version of busybox for testing, |
| 375 | you may force NOMMU build here. |
| 376 | |
| 377 | Most people will leave this set to 'N'. |
| 378 | |
Denis Vlasenko | cc3f20b | 2008-06-23 22:31:52 +0000 | [diff] [blame] | 379 | # PIE can be made to work with BUILD_LIBBUSYBOX, but currently |
| 380 | # build system does not support that |
Denis Vlasenko | 7d219aa | 2006-10-05 10:17:08 +0000 | [diff] [blame] | 381 | config BUILD_LIBBUSYBOX |
Bernhard Reutner-Fischer | 2aba395 | 2006-01-24 16:14:14 +0000 | [diff] [blame] | 382 | bool "Build shared libbusybox" |
Rob Landley | c7ddefc | 2006-06-14 01:24:33 +0000 | [diff] [blame] | 383 | default n |
Denis Vlasenko | fc5e806 | 2008-07-09 21:24:18 +0000 | [diff] [blame] | 384 | depends on !FEATURE_PREFER_APPLETS && !PIE && !STATIC |
Bernhard Reutner-Fischer | 2aba395 | 2006-01-24 16:14:14 +0000 | [diff] [blame] | 385 | help |
Denis Vlasenko | d62fd84 | 2007-10-07 20:46:34 +0000 | [diff] [blame] | 386 | Build a shared library libbusybox.so.N.N.N which contains all |
| 387 | busybox code. |
Bernhard Reutner-Fischer | 2aba395 | 2006-01-24 16:14:14 +0000 | [diff] [blame] | 388 | |
Denis Vlasenko | d62fd84 | 2007-10-07 20:46:34 +0000 | [diff] [blame] | 389 | This feature allows every applet to be built as a tiny |
Bernhard Reutner-Fischer | 3e8669f | 2008-07-22 18:27:53 +0000 | [diff] [blame] | 390 | separate executable. Enabling it for "one big busybox binary" |
Denis Vlasenko | d62fd84 | 2007-10-07 20:46:34 +0000 | [diff] [blame] | 391 | approach serves no purpose and increases code size. |
| 392 | You should almost certainly say "no" to this. |
Rob Landley | d6e5083 | 2006-06-15 15:04:53 +0000 | [diff] [blame] | 393 | |
Denis Vlasenko | def8898 | 2007-10-07 17:06:01 +0000 | [diff] [blame] | 394 | ### config FEATURE_FULL_LIBBUSYBOX |
| 395 | ### bool "Feature-complete libbusybox" |
| 396 | ### default n if !FEATURE_SHARED_BUSYBOX |
| 397 | ### depends on BUILD_LIBBUSYBOX |
| 398 | ### help |
| 399 | ### Build a libbusybox with the complete feature-set, disregarding |
| 400 | ### the actually selected config. |
| 401 | ### |
| 402 | ### Normally, libbusybox will only contain the features which are |
| 403 | ### used by busybox itself. If you plan to write a separate |
| 404 | ### standalone application which uses libbusybox say 'Y'. |
| 405 | ### |
| 406 | ### Note: libbusybox is GPL, not LGPL, and exports no stable API that |
Bernhard Reutner-Fischer | 3e8669f | 2008-07-22 18:27:53 +0000 | [diff] [blame] | 407 | ### might act as a copyright barrier. We can and will modify the |
Denis Vlasenko | def8898 | 2007-10-07 17:06:01 +0000 | [diff] [blame] | 408 | ### exported function set between releases (even minor version number |
| 409 | ### changes), and happily break out-of-tree features. |
| 410 | ### |
| 411 | ### Say 'N' if in doubt. |
Bernhard Reutner-Fischer | 2aba395 | 2006-01-24 16:14:14 +0000 | [diff] [blame] | 412 | |
Denis Vlasenko | f545be0 | 2007-10-07 17:06:26 +0000 | [diff] [blame] | 413 | config FEATURE_INDIVIDUAL |
| 414 | bool "Produce a binary for each applet, linked against libbusybox" |
| 415 | default y |
Denis Vlasenko | fc5e806 | 2008-07-09 21:24:18 +0000 | [diff] [blame] | 416 | depends on BUILD_LIBBUSYBOX |
Bernhard Reutner-Fischer | 2aba395 | 2006-01-24 16:14:14 +0000 | [diff] [blame] | 417 | help |
Denis Vlasenko | f545be0 | 2007-10-07 17:06:26 +0000 | [diff] [blame] | 418 | If your CPU architecture doesn't allow for sharing text/rodata |
| 419 | sections of running binaries, but allows for runtime dynamic |
| 420 | libraries, this option will allow you to reduce memory footprint |
| 421 | when you have many different applets running at once. |
Bernhard Reutner-Fischer | 2aba395 | 2006-01-24 16:14:14 +0000 | [diff] [blame] | 422 | |
Denis Vlasenko | f545be0 | 2007-10-07 17:06:26 +0000 | [diff] [blame] | 423 | If your CPU architecture allows for sharing text/rodata, |
| 424 | having single binary is more optimal. |
| 425 | |
| 426 | Each applet will be a tiny program, dynamically linked |
| 427 | against libbusybox.so.N.N.N. |
| 428 | |
| 429 | You need to have a working dynamic linker. |
| 430 | |
| 431 | config FEATURE_SHARED_BUSYBOX |
| 432 | bool "Produce additional busybox binary linked against libbusybox" |
| 433 | default y |
Denis Vlasenko | fc5e806 | 2008-07-09 21:24:18 +0000 | [diff] [blame] | 434 | depends on BUILD_LIBBUSYBOX |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 435 | help |
Denis Vlasenko | f545be0 | 2007-10-07 17:06:26 +0000 | [diff] [blame] | 436 | Build busybox, dynamically linked against libbusybox.so.N.N.N. |
| 437 | |
| 438 | You need to have a working dynamic linker. |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 439 | |
Denis Vlasenko | def8898 | 2007-10-07 17:06:01 +0000 | [diff] [blame] | 440 | ### config BUILD_AT_ONCE |
| 441 | ### bool "Compile all sources at once" |
| 442 | ### default n |
| 443 | ### help |
| 444 | ### Normally each source-file is compiled with one invocation of |
| 445 | ### the compiler. |
| 446 | ### If you set this option, all sources are compiled at once. |
| 447 | ### This gives the compiler more opportunities to optimize which can |
| 448 | ### result in smaller and/or faster binaries. |
| 449 | ### |
| 450 | ### Setting this option will consume alot of memory, e.g. if you |
| 451 | ### enable all applets with all features, gcc uses more than 300MB |
| 452 | ### RAM during compilation of busybox. |
| 453 | ### |
| 454 | ### This option is most likely only beneficial for newer compilers |
| 455 | ### such as gcc-4.1 and above. |
| 456 | ### |
| 457 | ### Say 'N' unless you know what you are doing. |
Bernhard Reutner-Fischer | 2aba395 | 2006-01-24 16:14:14 +0000 | [diff] [blame] | 458 | |
Denis Vlasenko | f545be0 | 2007-10-07 17:06:26 +0000 | [diff] [blame] | 459 | config LFS |
| 460 | bool "Build with Large File Support (for accessing files > 2 GB)" |
Denys Vlasenko | 2f32bf8 | 2010-06-06 04:14:28 +0200 | [diff] [blame] | 461 | default y |
Denis Vlasenko | f545be0 | 2007-10-07 17:06:26 +0000 | [diff] [blame] | 462 | help |
| 463 | If you want to build BusyBox with large file support, then enable |
Bernhard Reutner-Fischer | 3e8669f | 2008-07-22 18:27:53 +0000 | [diff] [blame] | 464 | this option. This will have no effect if your kernel or your C |
| 465 | library lacks large file support for large files. Some of the |
Denis Vlasenko | f545be0 | 2007-10-07 17:06:26 +0000 | [diff] [blame] | 466 | programs that can benefit from large file support include dd, gzip, |
Bernhard Reutner-Fischer | 3e8669f | 2008-07-22 18:27:53 +0000 | [diff] [blame] | 467 | cp, mount, tar, and many others. If you want to access files larger |
| 468 | than 2 Gigabytes, enable this option. Otherwise, leave it set to 'N'. |
Denis Vlasenko | f545be0 | 2007-10-07 17:06:26 +0000 | [diff] [blame] | 469 | |
Denis Vlasenko | b8e653b | 2008-06-02 04:51:29 +0000 | [diff] [blame] | 470 | config CROSS_COMPILER_PREFIX |
| 471 | string "Cross Compiler prefix" |
| 472 | default "" |
| 473 | help |
| 474 | If you want to build BusyBox with a cross compiler, then you |
| 475 | will need to set this to the cross-compiler prefix, for example, |
Bernhard Reutner-Fischer | 7d0d3e2 | 2008-08-22 08:25:26 +0000 | [diff] [blame] | 476 | "i386-uclibc-". |
| 477 | |
| 478 | Note that CROSS_COMPILE environment variable or |
| 479 | "make CROSS_COMPILE=xxx ..." will override this selection. |
| 480 | |
| 481 | Native builds leave this empty. |
Denis Vlasenko | b8e653b | 2008-06-02 04:51:29 +0000 | [diff] [blame] | 482 | |
Rob Walker | bf63437 | 2012-03-07 12:25:53 +0100 | [diff] [blame] | 483 | config SYSROOT |
| 484 | string "Path to sysroot" |
| 485 | default "" |
| 486 | help |
| 487 | If you want to build BusyBox with a cross compiler, then you |
| 488 | might also need to specify where /usr/include and /usr/lib |
| 489 | will be found. |
| 490 | |
| 491 | For example, BusyBox can be built against an installed |
| 492 | Android NDK, platform version 9, for ARM ABI with |
| 493 | |
| 494 | CONFIG_SYSROOT=/opt/android-ndk/platforms/android-9/arch-arm |
| 495 | |
| 496 | Native builds leave this empty. |
| 497 | |
Bernhard Reutner-Fischer | f6107c7 | 2009-01-22 13:27:14 +0000 | [diff] [blame] | 498 | config EXTRA_CFLAGS |
| 499 | string "Additional CFLAGS" |
| 500 | default "" |
| 501 | help |
| 502 | Additional CFLAGS to pass to the compiler verbatim. |
| 503 | |
Rob Walker | bf63437 | 2012-03-07 12:25:53 +0100 | [diff] [blame] | 504 | config EXTRA_LDFLAGS |
| 505 | string "Additional LDFLAGS" |
| 506 | default "" |
| 507 | help |
| 508 | Additional LDFLAGS to pass to the linker verbatim. |
| 509 | |
| 510 | config EXTRA_LDLIBS |
| 511 | string "Additional LDLIBS" |
| 512 | default "" |
| 513 | help |
| 514 | Additional LDLIBS to pass to the linker with -l. |
| 515 | |
Denys Vlasenko | 3360226 | 2016-11-24 22:08:12 +0100 | [diff] [blame] | 516 | comment 'Installation Options ("make install" behavior)' |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 517 | |
Denys Vlasenko | 3360226 | 2016-11-24 22:08:12 +0100 | [diff] [blame] | 518 | choice |
| 519 | prompt "What kind of applet links to install" |
| 520 | default INSTALL_APPLET_SYMLINKS |
| 521 | help |
| 522 | Choose what kind of links to applets are created by "make install". |
| 523 | |
| 524 | config INSTALL_APPLET_SYMLINKS |
| 525 | bool "as soft-links" |
| 526 | help |
| 527 | Install applets as soft-links to the busybox binary. This needs some |
| 528 | free inodes on the filesystem, but might help with filesystem |
| 529 | generators that can't cope with hard-links. |
| 530 | |
| 531 | config INSTALL_APPLET_HARDLINKS |
| 532 | bool "as hard-links" |
| 533 | help |
| 534 | Install applets as hard-links to the busybox binary. This might |
| 535 | count on a filesystem with few inodes. |
| 536 | |
| 537 | config INSTALL_APPLET_SCRIPT_WRAPPERS |
| 538 | bool "as script wrappers" |
| 539 | help |
| 540 | Install applets as script wrappers that call the busybox binary. |
| 541 | |
| 542 | config INSTALL_APPLET_DONT |
| 543 | bool "not installed" |
| 544 | help |
| 545 | Do not install applet links. Useful when you plan to use |
| 546 | busybox --install for installing links, or plan to use |
| 547 | a standalone shell and thus don't need applet links. |
| 548 | |
| 549 | endchoice |
| 550 | |
| 551 | choice |
| 552 | prompt "/bin/sh applet link" |
| 553 | default INSTALL_SH_APPLET_SYMLINK |
| 554 | depends on INSTALL_APPLET_SCRIPT_WRAPPERS |
| 555 | help |
| 556 | Choose how you install /bin/sh applet link. |
| 557 | |
| 558 | config INSTALL_SH_APPLET_SYMLINK |
| 559 | bool "as soft-link" |
| 560 | help |
| 561 | Install /bin/sh applet as soft-link to the busybox binary. |
| 562 | |
| 563 | config INSTALL_SH_APPLET_HARDLINK |
| 564 | bool "as hard-link" |
| 565 | help |
| 566 | Install /bin/sh applet as hard-link to the busybox binary. |
| 567 | |
| 568 | config INSTALL_SH_APPLET_SCRIPT_WRAPPER |
| 569 | bool "as script wrapper" |
| 570 | help |
| 571 | Install /bin/sh applet as script wrapper that calls |
| 572 | the busybox binary. |
| 573 | |
| 574 | endchoice |
| 575 | |
| 576 | config PREFIX |
| 577 | string "BusyBox installation prefix" |
| 578 | default "./_install" |
| 579 | help |
| 580 | Define your directory to install BusyBox files/subdirs in. |
| 581 | |
| 582 | comment 'Debugging Options' |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 583 | |
Denis Vlasenko | 7d219aa | 2006-10-05 10:17:08 +0000 | [diff] [blame] | 584 | config DEBUG |
Rob Landley | c503df5 | 2006-05-09 22:08:56 +0000 | [diff] [blame] | 585 | bool "Build BusyBox with extra Debugging symbols" |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 586 | default n |
| 587 | help |
Rob Landley | c503df5 | 2006-05-09 22:08:56 +0000 | [diff] [blame] | 588 | Say Y here if you wish to examine BusyBox internals while applets are |
Bernhard Reutner-Fischer | 3e8669f | 2008-07-22 18:27:53 +0000 | [diff] [blame] | 589 | running. This increases the size of the binary considerably, and |
| 590 | should only be used when doing development. If you are doing |
Rob Landley | c503df5 | 2006-05-09 22:08:56 +0000 | [diff] [blame] | 591 | development and want to debug BusyBox, answer Y. |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 592 | |
Eric Andersen | f086ed8 | 2004-05-25 11:30:22 +0000 | [diff] [blame] | 593 | Most people should answer N. |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 594 | |
Denis Vlasenko | bd8390a | 2008-06-12 20:23:03 +0000 | [diff] [blame] | 595 | config DEBUG_PESSIMIZE |
Denis Vlasenko | c185e29 | 2008-07-16 23:45:11 +0000 | [diff] [blame] | 596 | bool "Disable compiler optimizations" |
Denis Vlasenko | bd8390a | 2008-06-12 20:23:03 +0000 | [diff] [blame] | 597 | default n |
| 598 | depends on DEBUG |
| 599 | help |
| 600 | The compiler's optimization of source code can eliminate and reorder |
| 601 | code, resulting in an executable that's hard to understand when |
Bernhard Reutner-Fischer | 3e8669f | 2008-07-22 18:27:53 +0000 | [diff] [blame] | 602 | stepping through it with a debugger. This switches it off, resulting |
Denis Vlasenko | bd8390a | 2008-06-12 20:23:03 +0000 | [diff] [blame] | 603 | in a much bigger executable that more closely matches the source |
| 604 | code. |
| 605 | |
Mike Frysinger | 43e5663 | 2016-02-12 22:12:47 -0500 | [diff] [blame] | 606 | config DEBUG_SANITIZE |
| 607 | bool "Enable runtime sanitizers (ASAN/LSAN/USAN/etc...)" |
| 608 | default n |
| 609 | help |
| 610 | Say Y here if you want to enable runtime sanitizers. These help |
| 611 | catch bad memory accesses (e.g. buffer overflows), but will make |
| 612 | the executable larger and slow down runtime a bit. |
| 613 | |
Denys Vlasenko | f560422 | 2017-01-10 14:58:54 +0100 | [diff] [blame] | 614 | This adds -fsanitize=foo options to gcc command line. |
| 615 | |
Mike Frysinger | 43e5663 | 2016-02-12 22:12:47 -0500 | [diff] [blame] | 616 | If you aren't developing/testing busybox, say N here. |
| 617 | |
Bartosz Golaszewski | 3ed81cf | 2014-06-22 16:30:41 +0200 | [diff] [blame] | 618 | config UNIT_TEST |
| 619 | bool "Build unit tests" |
| 620 | default n |
| 621 | help |
| 622 | Say Y here if you want to build unit tests (both the framework and |
| 623 | test cases) as a Busybox applet. This results in bigger code, so you |
| 624 | probably don't want this option in production builds. |
| 625 | |
Denis Vlasenko | e0eebc1 | 2007-01-27 13:44:53 +0000 | [diff] [blame] | 626 | config WERROR |
| 627 | bool "Abort compilation on any warning" |
Rob Landley | c503df5 | 2006-05-09 22:08:56 +0000 | [diff] [blame] | 628 | default n |
Rob Landley | c503df5 | 2006-05-09 22:08:56 +0000 | [diff] [blame] | 629 | help |
Denys Vlasenko | f560422 | 2017-01-10 14:58:54 +0100 | [diff] [blame] | 630 | This adds -Werror to gcc command line. |
Denis Vlasenko | e0eebc1 | 2007-01-27 13:44:53 +0000 | [diff] [blame] | 631 | |
| 632 | Most people should answer N. |
| 633 | |
Eric Andersen | f086ed8 | 2004-05-25 11:30:22 +0000 | [diff] [blame] | 634 | choice |
| 635 | prompt "Additional debugging library" |
Denis Vlasenko | 7d219aa | 2006-10-05 10:17:08 +0000 | [diff] [blame] | 636 | default NO_DEBUG_LIB |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 637 | help |
Eric Andersen | f086ed8 | 2004-05-25 11:30:22 +0000 | [diff] [blame] | 638 | Using an additional debugging library will make BusyBox become |
Bernhard Reutner-Fischer | 3e8669f | 2008-07-22 18:27:53 +0000 | [diff] [blame] | 639 | considerable larger and will cause it to run more slowly. You |
Eric Andersen | f086ed8 | 2004-05-25 11:30:22 +0000 | [diff] [blame] | 640 | should always leave this option disabled for production use. |
| 641 | |
| 642 | dmalloc support: |
| 643 | ---------------- |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 644 | This enables compiling with dmalloc ( http://dmalloc.com/ ) |
| 645 | which is an excellent public domain mem leak and malloc problem |
Bernhard Reutner-Fischer | 3e8669f | 2008-07-22 18:27:53 +0000 | [diff] [blame] | 646 | detector. To enable dmalloc, before running busybox you will |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 647 | want to properly set your environment, for example: |
| 648 | export DMALLOC_OPTIONS=debug=0x34f47d83,inter=100,log=logfile |
| 649 | The 'debug=' value is generated using the following command |
Bernhard Reutner-Fischer | 3e8669f | 2008-07-22 18:27:53 +0000 | [diff] [blame] | 650 | dmalloc -p log-stats -p log-non-free -p log-bad-space \ |
| 651 | -p log-elapsed-time -p check-fence -p check-heap \ |
| 652 | -p check-lists -p check-blank -p check-funcs -p realloc-copy \ |
| 653 | -p allow-free-null |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 654 | |
Eric Andersen | f086ed8 | 2004-05-25 11:30:22 +0000 | [diff] [blame] | 655 | Electric-fence support: |
| 656 | ----------------------- |
Bernhard Reutner-Fischer | 3e8669f | 2008-07-22 18:27:53 +0000 | [diff] [blame] | 657 | This enables compiling with Electric-fence support. Electric |
Eric Andersen | 88c916b | 2003-10-22 09:58:56 +0000 | [diff] [blame] | 658 | fence is another very useful malloc debugging library which uses |
Eric Andersen | c7bda1c | 2004-03-15 08:29:22 +0000 | [diff] [blame] | 659 | your computer's virtual memory hardware to detect illegal memory |
Bernhard Reutner-Fischer | 3e8669f | 2008-07-22 18:27:53 +0000 | [diff] [blame] | 660 | accesses. This support will make BusyBox be considerable larger |
Eric Andersen | c7bda1c | 2004-03-15 08:29:22 +0000 | [diff] [blame] | 661 | and run slower, so you should leave this option disabled unless |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 662 | you are hunting a hard to find memory problem. |
| 663 | |
Eric Andersen | f086ed8 | 2004-05-25 11:30:22 +0000 | [diff] [blame] | 664 | |
Denis Vlasenko | 7d219aa | 2006-10-05 10:17:08 +0000 | [diff] [blame] | 665 | config NO_DEBUG_LIB |
Eric Andersen | f086ed8 | 2004-05-25 11:30:22 +0000 | [diff] [blame] | 666 | bool "None" |
| 667 | |
Denis Vlasenko | 7d219aa | 2006-10-05 10:17:08 +0000 | [diff] [blame] | 668 | config DMALLOC |
Eric Andersen | f086ed8 | 2004-05-25 11:30:22 +0000 | [diff] [blame] | 669 | bool "Dmalloc" |
| 670 | |
Denis Vlasenko | 7d219aa | 2006-10-05 10:17:08 +0000 | [diff] [blame] | 671 | config EFENCE |
Eric Andersen | f086ed8 | 2004-05-25 11:30:22 +0000 | [diff] [blame] | 672 | bool "Electric-fence" |
| 673 | |
| 674 | endchoice |
| 675 | |
Eric Andersen | c9f20d9 | 2002-12-05 08:41:41 +0000 | [diff] [blame] | 676 | endmenu |
Mike Frysinger | 72d59db | 2006-03-10 23:17:17 +0000 | [diff] [blame] | 677 | |
Mike Frysinger | 72d59db | 2006-03-10 23:17:17 +0000 | [diff] [blame] | 678 | source libbb/Config.in |
| 679 | |
| 680 | comment "Applets" |
| 681 | |
| 682 | source archival/Config.in |
| 683 | source coreutils/Config.in |
| 684 | source console-tools/Config.in |
| 685 | source debianutils/Config.in |
| 686 | source editors/Config.in |
| 687 | source findutils/Config.in |
| 688 | source init/Config.in |
| 689 | source loginutils/Config.in |
| 690 | source e2fsprogs/Config.in |
| 691 | source modutils/Config.in |
| 692 | source util-linux/Config.in |
| 693 | source miscutils/Config.in |
| 694 | source networking/Config.in |
Bernhard Reutner-Fischer | aa2a1c0 | 2008-10-24 19:48:47 +0000 | [diff] [blame] | 695 | source printutils/Config.in |
Denis Vlasenko | b9d572a | 2008-11-06 23:41:38 +0000 | [diff] [blame] | 696 | source mailutils/Config.in |
Mike Frysinger | 72d59db | 2006-03-10 23:17:17 +0000 | [diff] [blame] | 697 | source procps/Config.in |
Denis Vlasenko | fe54458 | 2006-10-03 15:57:40 +0000 | [diff] [blame] | 698 | source runit/Config.in |
Denis Vlasenko | d46d3c2 | 2007-02-06 19:28:50 +0000 | [diff] [blame] | 699 | source selinux/Config.in |
Bernhard Reutner-Fischer | aa2a1c0 | 2008-10-24 19:48:47 +0000 | [diff] [blame] | 700 | source shell/Config.in |
| 701 | source sysklogd/Config.in |