| 1 | # $FreeWRT$
|
|---|
| 2 |
|
|---|
| 3 | comment "Shell selection --"
|
|---|
| 4 | comment "Building shell packages and configuring their features"
|
|---|
| 5 | source "package/busybox/config/shell/Config.in"
|
|---|
| 6 | source "package/mksh/Config.in"
|
|---|
| 7 | comment "Selecting appropriate shells from these enabled above"
|
|---|
| 8 | choice
|
|---|
| 9 | prompt "Choose the default bourne shell (/bin/sh)"
|
|---|
| 10 | default BUSYBOX_CONFIG_FEATURE_SH_IS_ASH if BUSYBOX_CONFIG_ASH
|
|---|
| 11 | default FWRT_PACKAGE_MKSH_AS_BINSH if FWRT_PACKAGE_MKSH
|
|---|
| 12 | help
|
|---|
| 13 | Choose a shell which is to be used for /bin/sh.
|
|---|
| 14 | The ash shell is the most bash-compatible shell
|
|---|
| 15 | and full-featured one in busybox; mksh is a bit
|
|---|
| 16 | more heavy-weight but feature-complete. The other
|
|---|
| 17 | shells probably do not work as /bin/sh in FreeWRT.
|
|---|
| 18 |
|
|---|
| 19 | config BUSYBOX_CONFIG_FEATURE_SH_IS_ASH
|
|---|
| 20 | depends BUSYBOX_CONFIG_ASH
|
|---|
| 21 | bool "ash (busybox)"
|
|---|
| 22 | help
|
|---|
| 23 | Tha 'ash' shell adds about 60k in the default configuration and is
|
|---|
| 24 | the most complete and most pedantically correct shell included with
|
|---|
| 25 | busybox. This shell is actually a derivative of the Debian 'dash'
|
|---|
| 26 | shell (by Herbert Xu), which was created by porting the 'ash' shell
|
|---|
| 27 | (written by Kenneth Almquist) from NetBSD.
|
|---|
| 28 |
|
|---|
| 29 | config FWRT_PACKAGE_MKSH_AS_BINSH
|
|---|
| 30 | depends FWRT_PACKAGE_MKSH
|
|---|
| 31 | select BUSYBOX_CONFIG_FEATURE_SH_IS_NONE
|
|---|
| 32 | bool "mksh"
|
|---|
| 33 | help
|
|---|
| 34 | mksh is the MirBSD enhanced version of the Public Domain Korn
|
|---|
| 35 | shell (pdksh), a bourne-compatible shell which is largely similar
|
|---|
| 36 | to the original AT&T Korn shell. It includes bug fixes and
|
|---|
| 37 | feature improvements in order to produce a modern, robust shell
|
|---|
| 38 | good for interactive and especially script use. Some sh/ksh/pdksh
|
|---|
| 39 | compatibility kludges have been removed.
|
|---|
| 40 |
|
|---|
| 41 | config BUSYBOX_CONFIG_FEATURE_SH_IS_HUSH
|
|---|
| 42 | depends BUSYBOX_CONFIG_HUSH
|
|---|
| 43 | bool "hush (busybox)"
|
|---|
| 44 | help
|
|---|
| 45 | hush is a very small shell (just 18k) and it has fairly complete
|
|---|
| 46 | Bourne shell grammar. It even handles all the normal flow control
|
|---|
| 47 | options such as if/then/elif/else/fi, for/in/do/done, while loops,
|
|---|
| 48 | etc.
|
|---|
| 49 |
|
|---|
| 50 | It does not handle case/esac, select, function, here documents ( <<
|
|---|
| 51 | word ), arithmetic expansion, aliases, brace expansion, tilde
|
|---|
| 52 | expansion, &> and >& redirection of stdout+stderr, etc.
|
|---|
| 53 |
|
|---|
| 54 | config BUSYBOX_CONFIG_FEATURE_SH_IS_LASH
|
|---|
| 55 | depends BUSYBOX_CONFIG_LASH
|
|---|
| 56 | bool "lash (busybox)"
|
|---|
| 57 | help
|
|---|
| 58 | lash is the very smallest shell (adds just 10k) and it is quite
|
|---|
| 59 | usable as a command prompt, but it is not suitable for any but the
|
|---|
| 60 | most trivial scripting (such as an initrd that calls insmod a few
|
|---|
| 61 | times) since it does not understand any Bourne shell grammar. It
|
|---|
| 62 | does handle pipes, redirects, and job control though. Adding in
|
|---|
| 63 | command editing makes it a very nice lightweight command prompt.
|
|---|
| 64 |
|
|---|
| 65 | config BUSYBOX_CONFIG_FEATURE_SH_IS_MSH
|
|---|
| 66 | depends BUSYBOX_CONFIG_MSH
|
|---|
| 67 | bool "msh (busybox)"
|
|---|
| 68 | help
|
|---|
| 69 | The minix shell (adds just 30k) is quite complete and handles things
|
|---|
| 70 | like for/do/done, case/esac and all the things you expect a Bourne
|
|---|
| 71 | shell to do. It is not always pedantically correct about Bourne
|
|---|
| 72 | shell grammar (try running the shell testscript "tests/sh.testcases"
|
|---|
| 73 | on it and compare vs bash) but for most things it works quite well.
|
|---|
| 74 | It also uses only vfork, so it can be used on uClinux systems.
|
|---|
| 75 |
|
|---|
| 76 | endchoice
|
|---|
| 77 |
|
|---|
| 78 | choice
|
|---|
| 79 | prompt "Choose the login shell for the admin user"
|
|---|
| 80 | default FWRT_BASEFILES_ADMIN_ASH if BUSYBOX_CONFIG_ASH
|
|---|
| 81 | default FWRT_BASEFILES_ADMIN_MKSH if FWRT_PACKAGE_MKSH
|
|---|
| 82 | default FWRT_BASEFILES_ADMIN_SH if (!BUSYBOX_CONFIG_ASH && !FWRT_PACKAGE_MKSH)
|
|---|
| 83 | help
|
|---|
| 84 | Choose a shell which is to be used as the default login
|
|---|
| 85 | shell for the "admin" user. Only shells selected above
|
|---|
| 86 | can be chosen.
|
|---|
| 87 |
|
|---|
| 88 | config FWRT_BASEFILES_ADMIN_ASH
|
|---|
| 89 | depends BUSYBOX_CONFIG_ASH
|
|---|
| 90 | bool "ash (busybox)"
|
|---|
| 91 | help
|
|---|
| 92 | Tha 'ash' shell adds about 60k in the default configuration and is
|
|---|
| 93 | the most complete and most pedantically correct shell included with
|
|---|
| 94 | busybox. This shell is actually a derivative of the Debian 'dash'
|
|---|
| 95 | shell (by Herbert Xu), which was created by porting the 'ash' shell
|
|---|
| 96 | (written by Kenneth Almquist) from NetBSD.
|
|---|
| 97 |
|
|---|
| 98 | config FWRT_BASEFILES_ADMIN_MKSH
|
|---|
| 99 | depends FWRT_PACKAGE_MKSH
|
|---|
| 100 | bool "mksh"
|
|---|
| 101 | help
|
|---|
| 102 | mksh is the MirBSD enhanced version of the Public Domain Korn
|
|---|
| 103 | shell (pdksh), a bourne-compatible shell which is largely similar
|
|---|
| 104 | to the original AT&T Korn shell. It includes bug fixes and
|
|---|
| 105 | feature improvements in order to produce a modern, robust shell
|
|---|
| 106 | good for interactive and especially script use. Some sh/ksh/pdksh
|
|---|
| 107 | compatibility kludges have been removed.
|
|---|
| 108 |
|
|---|
| 109 | config FWRT_BASEFILES_ADMIN_HUSH
|
|---|
| 110 | depends BUSYBOX_CONFIG_HUSH
|
|---|
| 111 | bool "hush (busybox)"
|
|---|
| 112 | help
|
|---|
| 113 | hush is a very small shell (just 18k) and it has fairly complete
|
|---|
| 114 | Bourne shell grammar. It even handles all the normal flow control
|
|---|
| 115 | options such as if/then/elif/else/fi, for/in/do/done, while loops,
|
|---|
| 116 | etc.
|
|---|
| 117 |
|
|---|
| 118 | It does not handle case/esac, select, function, here documents ( <<
|
|---|
| 119 | word ), arithmetic expansion, aliases, brace expansion, tilde
|
|---|
| 120 | expansion, &> and >& redirection of stdout+stderr, etc.
|
|---|
| 121 |
|
|---|
| 122 | config FWRT_BASEFILES_ADMIN_LASH
|
|---|
| 123 | depends BUSYBOX_CONFIG_LASH
|
|---|
| 124 | bool "lash (busybox)"
|
|---|
| 125 | help
|
|---|
| 126 | lash is the very smallest shell (adds just 10k) and it is quite
|
|---|
| 127 | usable as a command prompt, but it is not suitable for any but the
|
|---|
| 128 | most trivial scripting (such as an initrd that calls insmod a few
|
|---|
| 129 | times) since it does not understand any Bourne shell grammar. It
|
|---|
| 130 | does handle pipes, redirects, and job control though. Adding in
|
|---|
| 131 | command editing makes it a very nice lightweight command prompt.
|
|---|
| 132 |
|
|---|
| 133 | config FWRT_BASEFILES_ADMIN_MSH
|
|---|
| 134 | depends BUSYBOX_CONFIG_MSH
|
|---|
| 135 | bool "msh (busybox)"
|
|---|
| 136 | help
|
|---|
| 137 | The minix shell (adds just 30k) is quite complete and handles things
|
|---|
| 138 | like for/do/done, case/esac and all the things you expect a Bourne
|
|---|
| 139 | shell to do. It is not always pedantically correct about Bourne
|
|---|
| 140 | shell grammar (try running the shell testscript "tests/sh.testcases"
|
|---|
| 141 | on it and compare vs bash) but for most things it works quite well.
|
|---|
| 142 | It also uses only vfork, so it can be used on uClinux systems.
|
|---|
| 143 |
|
|---|
| 144 | config FWRT_BASEFILES_ADMIN_SH
|
|---|
| 145 | bool "/bin/sh"
|
|---|
| 146 | help
|
|---|
| 147 | Fall-back: use /bin/sh, whatever it is.
|
|---|
| 148 |
|
|---|
| 149 | endchoice
|
|---|