diff options
| author | Eric Andersen <andersen@codepoet.org> | 2003-08-08 23:40:12 +0000 |
|---|---|---|
| committer | Eric Andersen <andersen@codepoet.org> | 2003-08-08 23:40:12 +0000 |
| commit | b287e2e27a388deecd9d9580f2a846b2b2efff42 (patch) | |
| tree | c5745cb1766bfb17731879c0a77be16aa8ba8056 /shell | |
| parent | c601ff149a91fbadc06a8b0cd86d4dbbd73f84a2 (diff) | |
| download | busybox-w32-b287e2e27a388deecd9d9580f2a846b2b2efff42.tar.gz busybox-w32-b287e2e27a388deecd9d9580f2a846b2b2efff42.tar.bz2 busybox-w32-b287e2e27a388deecd9d9580f2a846b2b2efff42.zip | |
Use the new 'select' option to make the shell config
much less evil and far more obvious.
-Erik
Diffstat (limited to 'shell')
| -rw-r--r-- | shell/Config.in | 65 |
1 files changed, 27 insertions, 38 deletions
diff --git a/shell/Config.in b/shell/Config.in index 6103ccfda..bd6f39f7d 100644 --- a/shell/Config.in +++ b/shell/Config.in | |||
| @@ -13,15 +13,19 @@ choice | |||
| 13 | and full featured. | 13 | and full featured. |
| 14 | 14 | ||
| 15 | config CONFIG_FEATURE_SH_IS_ASH | 15 | config CONFIG_FEATURE_SH_IS_ASH |
| 16 | select CONFIG_ASH | ||
| 16 | bool "ash" | 17 | bool "ash" |
| 17 | 18 | ||
| 18 | config CONFIG_FEATURE_SH_IS_HUSH | 19 | config CONFIG_FEATURE_SH_IS_HUSH |
| 20 | select CONFIG_HUSH | ||
| 19 | bool "hush" | 21 | bool "hush" |
| 20 | 22 | ||
| 21 | config CONFIG_FEATURE_SH_IS_LASH | 23 | config CONFIG_FEATURE_SH_IS_LASH |
| 24 | select CONFIG_LASH | ||
| 22 | bool "lash" | 25 | bool "lash" |
| 23 | 26 | ||
| 24 | config CONFIG_FEATURE_SH_IS_MSH | 27 | config CONFIG_FEATURE_SH_IS_MSH |
| 28 | select CONFIG_MSH | ||
| 25 | bool "msh" | 29 | bool "msh" |
| 26 | 30 | ||
| 27 | config CONFIG_FEATURE_SH_IS_NONE | 31 | config CONFIG_FEATURE_SH_IS_NONE |
| @@ -29,20 +33,15 @@ config CONFIG_FEATURE_SH_IS_NONE | |||
| 29 | 33 | ||
| 30 | endchoice | 34 | endchoice |
| 31 | 35 | ||
| 32 | if CONFIG_FEATURE_SH_IS_ASH | ||
| 33 | config CONFIG_ASH | ||
| 34 | default y | ||
| 35 | |||
| 36 | comment "ash (forced enabled as default shell)" | ||
| 37 | endif | ||
| 38 | |||
| 39 | if !CONFIG_FEATURE_SH_IS_ASH | ||
| 40 | config CONFIG_ASH | 36 | config CONFIG_ASH |
| 41 | bool "ash" | 37 | bool "ash" |
| 42 | default y | 38 | default y |
| 43 | help | 39 | help |
| 44 | Make sh a link to ash. | 40 | Tha 'ash' shell adds about 60k in the default configuration and is |
| 45 | endif | 41 | the most complete and most pedantically correct shell included with |
| 42 | busybox. This shell is actually a derivitive the Debian 'dash' shell | ||
| 43 | (by Herbert Xu), which was created by porting the 'ash' shell | ||
| 44 | (written by Kenneth Almquist) from NetBSD. | ||
| 46 | 45 | ||
| 47 | comment "Ash Shell Options" | 46 | comment "Ash Shell Options" |
| 48 | depends on CONFIG_ASH | 47 | depends on CONFIG_ASH |
| @@ -98,51 +97,41 @@ config CONFIG_ASH_OPTIMIZE_FOR_SIZE | |||
| 98 | help | 97 | help |
| 99 | Compile ash for reduced size at price of speed. | 98 | Compile ash for reduced size at price of speed. |
| 100 | 99 | ||
| 101 | if CONFIG_FEATURE_SH_IS_HUSH | ||
| 102 | config CONFIG_HUSH | ||
| 103 | default y | ||
| 104 | |||
| 105 | comment "hush (forced enabled as default shell)" | ||
| 106 | endif | ||
| 107 | |||
| 108 | if !CONFIG_FEATURE_SH_IS_HUSH | ||
| 109 | config CONFIG_HUSH | 100 | config CONFIG_HUSH |
| 110 | bool "hush" | 101 | bool "hush" |
| 111 | default n | 102 | default n |
| 112 | help | 103 | help |
| 113 | Make sh a link to hush. | 104 | hush is very small shell (just 18k) and it has fairly complete Bourne |
| 114 | endif | 105 | shell grammer. It even handles all the normal flow control options |
| 106 | such as if/then/elif/else/fi, for/in/do/done, while loops, etc. | ||
| 115 | 107 | ||
| 116 | if CONFIG_FEATURE_SH_IS_LASH | 108 | It does not handle case/esac, select, function, here documents ( << |
| 117 | config CONFIG_LASH | 109 | word ), arithmetic expansion, aliases, brace expansion, tilde |
| 118 | default y | 110 | expansion, &> and >& redirection of stdout+stderr, etc. |
| 119 | 111 | ||
| 120 | comment "lash (forced enabled as default shell)" | ||
| 121 | endif | ||
| 122 | 112 | ||
| 123 | if !CONFIG_FEATURE_SH_IS_LASH | ||
| 124 | config CONFIG_LASH | 113 | config CONFIG_LASH |
| 125 | bool "lash" | 114 | bool "lash" |
| 126 | default n | 115 | default n |
| 127 | help | 116 | help |
| 128 | Make sh a link to lash. | 117 | lash is the very smallest shell (adds just 10k) and it is quite |
| 129 | endif | 118 | usable as a command prompt, but it is not suitable for any but the |
| 130 | 119 | most trivial scripting (such as an initrd that calls insmod a few | |
| 131 | if CONFIG_FEATURE_SH_IS_MSH | 120 | times) since it does not understand any Bourne shell grammer. It |
| 132 | config CONFIG_MSH | 121 | does handle pipes, redirects, and job control though. Adding in |
| 133 | default y | 122 | command editing makes it a very nice lightweight command prompt. |
| 134 | 123 | ||
| 135 | comment "msh (forced enabled as default shell)" | ||
| 136 | endif | ||
| 137 | 124 | ||
| 138 | if !CONFIG_FEATURE_SH_IS_MSH | ||
| 139 | config CONFIG_MSH | 125 | config CONFIG_MSH |
| 140 | bool "msh" | 126 | bool "msh" |
| 141 | default n | 127 | default n |
| 142 | help | 128 | help |
| 143 | Make sh a link to msh. | 129 | The minix shell (adds just 30k) is quite complete and handles things |
| 144 | endif | 130 | like for/do/done, case/esac and all the things you expect a Bourne |
| 145 | 131 | shell to do. It is not always pedantically correct about Bourne | |
| 132 | shell grammer (try running the shell testscript "tests/sh.testcases" | ||
| 133 | on it and compare vs bash) but for most things it works quite well. | ||
| 134 | It also uses only vfork, so it can be used on uClinux systems. | ||
| 146 | 135 | ||
| 147 | comment "Bourne Shell Options" | 136 | comment "Bourne Shell Options" |
| 148 | depends on CONFIG_MSH || CONFIG_LASH || CONFIG_HUSH || CONFIG_ASH | 137 | depends on CONFIG_MSH || CONFIG_LASH || CONFIG_HUSH || CONFIG_ASH |
