mirror of
git://projects.qi-hardware.com/openwrt-xburst.git
synced 2024-11-24 00:07:11 +02:00
[package] busybox: update to v1.13.4 (closes: #4279)
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@16063 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
parent
622eabc631
commit
e53ecb012e
@ -1,4 +1,4 @@
|
||||
#
|
||||
#
|
||||
# Copyright (C) 2006-2009 OpenWrt.org
|
||||
#
|
||||
# This is free software, licensed under the GNU General Public License v2.
|
||||
@ -8,13 +8,13 @@
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=busybox
|
||||
PKG_VERSION:=1.12.4
|
||||
PKG_VERSION:=1.13.4
|
||||
PKG_RELEASE:=1
|
||||
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
||||
PKG_SOURCE_URL:=http://www.busybox.net/downloads \
|
||||
http://distfiles.gentoo.org/distfiles/
|
||||
PKG_MD5SUM:=5b8c427bf596732d6b6156672e6e093f
|
||||
PKG_MD5SUM:=8a5eb7f15d4077d18fa97bda7a4e5412
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
|
@ -154,15 +154,17 @@ config BUSYBOX_CONFIG_FEATURE_SUID
|
||||
default y
|
||||
help
|
||||
With this option you can install the busybox binary belonging
|
||||
to root with the suid bit set, and it'll and it'll automatically drop
|
||||
to root with the suid bit set, and it will automatically drop
|
||||
priviledges for applets that don't need root access.
|
||||
|
||||
If you're really paranoid and don't want to do this, build two
|
||||
If you are really paranoid and don't want to do this, build two
|
||||
busybox binaries with different applets in them (and the appropriate
|
||||
symlinks pointing to each binary), and only set the suid bit on the
|
||||
one that needs it. The applets currently marked to need the suid bit
|
||||
are login, passwd, su, ping, traceroute, crontab, dnsd, ipcrm, ipcs,
|
||||
and vlock.
|
||||
are:
|
||||
|
||||
crontab, dnsd, findfs, ipcrm, ipcs, login, passwd, ping, su,
|
||||
traceroute, vlock.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_SUID_CONFIG
|
||||
bool "Runtime SUID/SGID configuration via /etc/busybox.conf"
|
||||
@ -253,18 +255,18 @@ config BUSYBOX_CONFIG_BUSYBOX_EXEC_PATH
|
||||
# These are auto-selected by other options
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_SYSLOG
|
||||
bool "Support for logging to syslog"
|
||||
bool #No description makes it a hidden option
|
||||
default y
|
||||
help
|
||||
This option is auto-selected when you select any applet which may
|
||||
send its output to syslog. You do not need to select it manually.
|
||||
#help
|
||||
# This option is auto-selected when you select any applet which may
|
||||
# send its output to syslog. You do not need to select it manually.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_HAVE_RPC
|
||||
bool "RPC support"
|
||||
bool #No description makes it a hidden option
|
||||
default y
|
||||
help
|
||||
This is automatically selected if any of enabled applets need it.
|
||||
You do not need to select it manually.
|
||||
#help
|
||||
# This is automatically selected if any of enabled applets need it.
|
||||
# You do not need to select it manually.
|
||||
|
||||
endmenu
|
||||
|
||||
@ -401,9 +403,12 @@ config BUSYBOX_CONFIG_CROSS_COMPILER_PREFIX
|
||||
help
|
||||
If you want to build BusyBox with a cross compiler, then you
|
||||
will need to set this to the cross-compiler prefix, for example,
|
||||
"i386-uclibc-". Note that CROSS_COMPILE environment variable
|
||||
or "make CROSS_COMPILE=xxx ..." will override this selection.
|
||||
For native build leave it empty.
|
||||
"i386-uclibc-".
|
||||
|
||||
Note that CROSS_COMPILE environment variable or
|
||||
"make CROSS_COMPILE=xxx ..." will override this selection.
|
||||
|
||||
Native builds leave this empty.
|
||||
|
||||
endmenu
|
||||
|
||||
@ -490,8 +495,8 @@ config BUSYBOX_CONFIG_INCLUDE_SUSv2
|
||||
will be supported in head, tail, and fold. (Note: should
|
||||
affect renice too.)
|
||||
|
||||
config BUSYBOX_CONFIG_PARSE
|
||||
bool "Uniform config file parser debugging applet: parse"
|
||||
### config PARSE
|
||||
### bool "Uniform config file parser debugging applet: parse"
|
||||
|
||||
endmenu
|
||||
|
||||
@ -589,9 +594,10 @@ source package/busybox/config/modutils/Config.in
|
||||
source package/busybox/config/util-linux/Config.in
|
||||
source package/busybox/config/miscutils/Config.in
|
||||
source package/busybox/config/networking/Config.in
|
||||
source package/busybox/config/printutils/Config.in
|
||||
source package/busybox/config/mailutils/Config.in
|
||||
source package/busybox/config/procps/Config.in
|
||||
source package/busybox/config/shell/Config.in
|
||||
source package/busybox/config/sysklogd/Config.in
|
||||
source package/busybox/config/runit/Config.in
|
||||
source package/busybox/config/selinux/Config.in
|
||||
source package/busybox/config/printutils/Config.in
|
||||
source package/busybox/config/shell/Config.in
|
||||
source package/busybox/config/sysklogd/Config.in
|
||||
|
@ -13,7 +13,7 @@ config BUSYBOX_CONFIG_FEATURE_SEAMLESS_LZMA
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_SEAMLESS_BZ2
|
||||
bool "Make tar, rpm, modprobe etc understand .bz2 data"
|
||||
default y
|
||||
default n
|
||||
help
|
||||
Make tar, rpm, modprobe etc understand .bz2 data.
|
||||
|
||||
@ -77,7 +77,7 @@ config BUSYBOX_CONFIG_BUNZIP2
|
||||
|
||||
config BUSYBOX_CONFIG_BZIP2
|
||||
bool "bzip2"
|
||||
default y
|
||||
default n
|
||||
help
|
||||
bzip2 is a compression utility using the Burrows-Wheeler block
|
||||
sorting text compression algorithm, and Huffman coding. Compression
|
||||
@ -113,6 +113,7 @@ config BUSYBOX_CONFIG_FEATURE_CPIO_O
|
||||
config BUSYBOX_CONFIG_DPKG
|
||||
bool "dpkg"
|
||||
default n
|
||||
select BUSYBOX_CONFIG_FEATURE_SEAMLESS_GZ
|
||||
help
|
||||
dpkg is a medium-level tool to install, build, remove and manage
|
||||
Debian packages.
|
||||
@ -123,9 +124,9 @@ config BUSYBOX_CONFIG_DPKG
|
||||
config BUSYBOX_CONFIG_DPKG_DEB
|
||||
bool "dpkg_deb"
|
||||
default n
|
||||
select BUSYBOX_CONFIG_FEATURE_SEAMLESS_GZ
|
||||
help
|
||||
dpkg-deb packs, unpacks and provides information about Debian
|
||||
archives.
|
||||
dpkg-deb unpacks and provides information about Debian archives.
|
||||
|
||||
This implementation of dpkg-deb cannot pack archives.
|
||||
|
||||
@ -177,7 +178,7 @@ config BUSYBOX_CONFIG_TAR
|
||||
create compressed archives. It's probably the most widely used
|
||||
UNIX archive program.
|
||||
|
||||
if TAR
|
||||
if BUSYBOX_CONFIG_TAR
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_TAR_CREATE
|
||||
bool "Enable archive creation"
|
||||
|
@ -101,6 +101,21 @@ config BUSYBOX_CONFIG_SETFONT
|
||||
help
|
||||
Allows to load console screen map. Useful for i18n.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_SETFONT_TEXTUAL_MAP
|
||||
bool "Support reading textual screen maps"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_SETFONT
|
||||
help
|
||||
Support reading textual screen maps.
|
||||
|
||||
config BUSYBOX_CONFIG_DEFAULT_SETFONT_DIR
|
||||
string "Default directory for console-tools files"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_SETFONT
|
||||
help
|
||||
Directory to use if setfont's params are simple filenames
|
||||
(not /path/to/file or ./file). Default is "" (no default directory).
|
||||
|
||||
config BUSYBOX_CONFIG_SETKEYCODES
|
||||
bool "setkeycodes"
|
||||
default n
|
||||
|
@ -136,12 +136,12 @@ config BUSYBOX_CONFIG_DF
|
||||
df reports the amount of disk space used and available
|
||||
on filesystems.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_DF_INODE
|
||||
bool "Enable -i (inode information)"
|
||||
config BUSYBOX_CONFIG_FEATURE_DF_FANCY
|
||||
bool "Enable -a, -i, -B"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_DF
|
||||
help
|
||||
This option enables support for df -i.
|
||||
This option enables -a, -i and -B.
|
||||
|
||||
config BUSYBOX_CONFIG_DIRNAME
|
||||
bool "dirname"
|
||||
@ -189,7 +189,7 @@ config BUSYBOX_CONFIG_ECHO
|
||||
config BUSYBOX_CONFIG_FEATURE_FANCY_ECHO
|
||||
bool "Enable echo options (-n and -e)"
|
||||
default y
|
||||
depends on BUSYBOX_CONFIG_ECHO
|
||||
depends on BUSYBOX_CONFIG_ECHO || BUSYBOX_CONFIG_ASH_BUILTIN_ECHO
|
||||
help
|
||||
This adds options (-n and -e) to echo.
|
||||
|
||||
@ -649,7 +649,7 @@ config BUSYBOX_CONFIG_TEST
|
||||
config BUSYBOX_CONFIG_FEATURE_TEST_64
|
||||
bool "Extend test to 64 bit"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_TEST
|
||||
depends on BUSYBOX_CONFIG_TEST || BUSYBOX_CONFIG_ASH_BUILTIN_TEST
|
||||
help
|
||||
Enable 64-bit support in test.
|
||||
|
||||
|
@ -64,6 +64,7 @@ config BUSYBOX_CONFIG_FEATURE_START_STOP_DAEMON_FANCY
|
||||
Support additional arguments.
|
||||
-o|--oknodo ignored since we exit with 0 anyway
|
||||
-v|--verbose
|
||||
-N|--nicelevel N
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_START_STOP_DAEMON_LONG_OPTIONS
|
||||
bool "Enable long options"
|
||||
|
@ -12,7 +12,7 @@ config BUSYBOX_CONFIG_AWK
|
||||
Awk is used as a pattern scanning and processing language. This is
|
||||
the BusyBox implementation of that programming language.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_AWK_MATH
|
||||
config BUSYBOX_CONFIG_FEATURE_AWK_LIBM
|
||||
bool "Enable math functions (requires libm)"
|
||||
default y
|
||||
depends on BUSYBOX_CONFIG_AWK
|
||||
|
@ -146,7 +146,7 @@ config BUSYBOX_CONFIG_FEATURE_FIND_DELETE
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_FIND && BUSYBOX_CONFIG_FEATURE_FIND_DEPTH
|
||||
help
|
||||
Support the 'find -delete' option for deleting files and direcotries.
|
||||
Support the 'find -delete' option for deleting files and directories.
|
||||
WARNING: This option can do much harm if used wrong. Busybox will not
|
||||
try to protect the user from doing stupid things. Use with care.
|
||||
|
||||
|
@ -12,14 +12,6 @@ config BUSYBOX_CONFIG_INIT
|
||||
help
|
||||
init is the first program run when the system boots.
|
||||
|
||||
config BUSYBOX_CONFIG_DEBUG_INIT
|
||||
bool "Debugging aid"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_INIT
|
||||
help
|
||||
Turn this on to disable all the dangerous
|
||||
rebooting stuff when debugging.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_USE_INITTAB
|
||||
bool "Support reading an inittab file"
|
||||
default y
|
||||
@ -83,8 +75,6 @@ config BUSYBOX_CONFIG_FEATURE_INIT_COREDUMPS
|
||||
core file sizes. If this option is disabled, processes
|
||||
will not generate any core files.
|
||||
|
||||
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_INITRD
|
||||
bool "Support running init from within an initrd (not initramfs)"
|
||||
default n
|
||||
|
@ -1,20 +0,0 @@
|
||||
#
|
||||
# For a description of the syntax of this configuration file,
|
||||
# see scripts/kbuild/config-language.txt.
|
||||
#
|
||||
|
||||
menu "ipsvd utilities"
|
||||
|
||||
config BUSYBOX_CONFIG_TCPSVD
|
||||
bool "tcpsvd"
|
||||
default n
|
||||
help
|
||||
tcpsvd listens on a tcp port and runs a program for each new connection
|
||||
|
||||
config BUSYBOX_CONFIG_UDPSVD
|
||||
bool "udpsvd"
|
||||
default n
|
||||
help
|
||||
udpsvd listens on a udp port and runs a program for each new connection
|
||||
|
||||
endmenu
|
@ -233,12 +233,12 @@ config BUSYBOX_CONFIG_CRYPTPW
|
||||
Applet for crypting a string.
|
||||
|
||||
config BUSYBOX_CONFIG_CHPASSWD
|
||||
bool "chpasswd"
|
||||
default n
|
||||
help
|
||||
chpasswd reads a file of user name and password pairs from
|
||||
standard input and uses this information to update a group of
|
||||
existing users.
|
||||
bool "chpasswd"
|
||||
default n
|
||||
help
|
||||
chpasswd reads a file of user name and password pairs from
|
||||
standard input and uses this information to update a group of
|
||||
existing users.
|
||||
|
||||
config BUSYBOX_CONFIG_SU
|
||||
bool "su"
|
||||
|
69
package/busybox/config/mailutils/Config.in
Normal file
69
package/busybox/config/mailutils/Config.in
Normal file
@ -0,0 +1,69 @@
|
||||
menu "Mail Utilities"
|
||||
|
||||
config BUSYBOX_CONFIG_MAKEMIME
|
||||
bool "makemime"
|
||||
default n
|
||||
help
|
||||
Create MIME-formatted messages.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_MIME_CHARSET
|
||||
string "Default charset"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_MAKEMIME || BUSYBOX_CONFIG_REFORMIME || BUSYBOX_CONFIG_SENDMAIL
|
||||
help
|
||||
Default charset of the message.
|
||||
|
||||
config BUSYBOX_CONFIG_POPMAILDIR
|
||||
bool "popmaildir"
|
||||
default n
|
||||
help
|
||||
Simple yet powerful POP3 mail popper. Delivers content
|
||||
of remote mailboxes to local Maildir.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_POPMAILDIR_DELIVERY
|
||||
bool "Allow message filters and custom delivery program"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_POPMAILDIR
|
||||
help
|
||||
Allow to use a custom program to filter the content
|
||||
of the message before actual delivery (-F "prog [args...]").
|
||||
Allow to use a custom program for message actual delivery
|
||||
(-M "prog [args...]").
|
||||
|
||||
config BUSYBOX_CONFIG_REFORMIME
|
||||
bool "reformime"
|
||||
default n
|
||||
help
|
||||
Parse MIME-formatted messages.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_REFORMIME_COMPAT
|
||||
bool "Accept and ignore options other than -x and -X"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_REFORMIME
|
||||
help
|
||||
Accept (for compatibility only) and ignore options
|
||||
other than -x and -X.
|
||||
|
||||
config BUSYBOX_CONFIG_SENDMAIL
|
||||
bool "sendmail"
|
||||
default n
|
||||
help
|
||||
Barebones sendmail.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_SENDMAIL_MAILX
|
||||
bool "Allow to specify subject, attachments, their charset etc"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_SENDMAIL
|
||||
help
|
||||
Allow to specify subject, attachments and their charset.
|
||||
Allow to use custom connection helper.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_SENDMAIL_MAILXX
|
||||
bool "Allow to specify Cc: addresses and some additional headers"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_FEATURE_SENDMAIL_MAILX
|
||||
help
|
||||
Allow to specify Cc: addresses and some additional headers:
|
||||
Errors-To:
|
||||
|
||||
endmenu
|
@ -107,7 +107,7 @@ config BUSYBOX_CONFIG_CROND
|
||||
# Run daily cron jobs at 4:40 every day:
|
||||
40 4 * * * /etc/cron/daily > /dev/null 2>&1
|
||||
|
||||
config BUSYBOX_CONFIG_DEBUG_CROND_OPTION
|
||||
config BUSYBOX_CONFIG_FEATURE_CROND_D
|
||||
bool "Support option -d to redirect output to stderr"
|
||||
depends on BUSYBOX_CONFIG_CROND
|
||||
default n
|
||||
@ -138,6 +138,14 @@ config BUSYBOX_CONFIG_DC
|
||||
Dc is a reverse-polish desk calculator which supports unlimited
|
||||
precision arithmetic.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_DC_LIBM
|
||||
bool "Enable power and exp functions (requires libm)"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_DC
|
||||
help
|
||||
Enable power and exp functions.
|
||||
NOTE: This will require libm to be present for linking.
|
||||
|
||||
config BUSYBOX_CONFIG_DEVFSD
|
||||
bool "devfsd (obsolete)"
|
||||
default n
|
||||
@ -188,6 +196,13 @@ config BUSYBOX_CONFIG_FEATURE_DEVFS
|
||||
/dev/loop0. If your /dev directory has normal names instead of
|
||||
devfs names, you don't want this.
|
||||
|
||||
config BUSYBOX_CONFIG_DEVMEM
|
||||
bool "devmem"
|
||||
default n
|
||||
help
|
||||
devmem is a small program that reads and writes from physical
|
||||
memory using /dev/mem.
|
||||
|
||||
config BUSYBOX_CONFIG_EJECT
|
||||
bool "eject"
|
||||
default n
|
||||
@ -285,13 +300,13 @@ config BUSYBOX_CONFIG_FEATURE_LESS_FLAGS
|
||||
The -M flag enables a more sophisticated status line.
|
||||
The -m flag enables a simpler status line with a percentage.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_LESS_FLAGCS
|
||||
bool "Enable flag changes"
|
||||
config BUSYBOX_CONFIG_FEATURE_LESS_DASHCMD
|
||||
bool "Enable flag changes ('-' command)"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_LESS
|
||||
help
|
||||
This enables the ability to change command-line flags within
|
||||
less itself.
|
||||
less itself ('-' keyboard command).
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_LESS_MARKS
|
||||
bool "Enable marks"
|
||||
@ -307,6 +322,20 @@ config BUSYBOX_CONFIG_FEATURE_LESS_REGEXP
|
||||
help
|
||||
Enable regular expressions, allowing complex file searches.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_LESS_LINENUMS
|
||||
bool "Enable dynamic switching of line numbers"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_FEATURE_LESS_DASHCMD
|
||||
help
|
||||
Enable "-N" command.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_LESS_WINCH
|
||||
bool "Enable automatic resizing on window size changes"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_LESS
|
||||
help
|
||||
Makes less track window size changes.
|
||||
|
||||
config BUSYBOX_CONFIG_HDPARM
|
||||
bool "hdparm"
|
||||
default n
|
||||
|
@ -5,6 +5,20 @@
|
||||
|
||||
menu "Linux Module Utilities"
|
||||
|
||||
config BUSYBOX_CONFIG_DEFAULT_MODULES_DIR
|
||||
string "Default directory containing modules"
|
||||
default "/lib/modules"
|
||||
help
|
||||
Directory that contains kernel modules.
|
||||
Defaults to "/lib/modules"
|
||||
|
||||
config BUSYBOX_CONFIG_DEFAULT_DEPMOD_FILE
|
||||
string "Default name of modules.dep"
|
||||
default "modules.dep"
|
||||
help
|
||||
Filename that contains kernel modules dependencies.
|
||||
Defaults to "modules.dep"
|
||||
|
||||
config BUSYBOX_CONFIG_MODPROBE_SMALL
|
||||
bool "Simplified modutils"
|
||||
default n
|
||||
@ -54,37 +68,6 @@ config BUSYBOX_CONFIG_FEATURE_MODPROBE_SMALL_CHECK_ALREADY_LOADED
|
||||
Check if the module is already loaded.
|
||||
N.B. It's racy.
|
||||
|
||||
config BUSYBOX_CONFIG_DEPMOD
|
||||
bool "depmod"
|
||||
default n
|
||||
depends on !BUSYBOX_CONFIG_MODPROBE_SMALL
|
||||
help
|
||||
depmod generates modules.dep (FIXME: elaborate)
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_DEPMOD_PRUNE_FANCY
|
||||
bool "Fancy dependency pruning"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_DEPMOD
|
||||
help
|
||||
By default modules.dep contains all dependencies as listed by
|
||||
the modules.
|
||||
If you enable this option then we remove implied modules from
|
||||
the dependencies.
|
||||
This makes depmod somewhat bigger but generates a smaller
|
||||
modules.dep file.
|
||||
|
||||
If unsure, say N.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_DEPMOD_ALIAS
|
||||
bool "Alias support"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_DEPMOD
|
||||
help
|
||||
By default modules.dep does not contain alias information.
|
||||
Enable this to emit aliases of the form:
|
||||
|
||||
alias pcmcia:m*c*f03fn*pfn*pa*pb*pc*pd* parport_cs
|
||||
|
||||
config BUSYBOX_CONFIG_INSMOD
|
||||
bool "insmod"
|
||||
default y
|
||||
@ -92,55 +75,6 @@ config BUSYBOX_CONFIG_INSMOD
|
||||
help
|
||||
insmod is used to load specified modules in the running kernel.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_INSMOD_VERSION_CHECKING
|
||||
bool "Module version checking"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_INSMOD && BUSYBOX_CONFIG_FEATURE_2_4_MODULES
|
||||
help
|
||||
Support checking of versions for modules. This is used to
|
||||
ensure that the kernel and module are made for each other.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_INSMOD_KSYMOOPS_SYMBOLS
|
||||
bool "Add module symbols to kernel symbol table"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_INSMOD && BUSYBOX_CONFIG_FEATURE_2_4_MODULES
|
||||
help
|
||||
By adding module symbols to the kernel symbol table, Oops messages
|
||||
occuring within kernel modules can be properly debugged. By enabling
|
||||
this feature, module symbols will always be added to the kernel symbol
|
||||
table for properly debugging support. If you are not interested in
|
||||
Oops messages from kernel modules, say N.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_INSMOD_LOADINKMEM
|
||||
bool "In kernel memory optimization (uClinux only)"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_INSMOD && BUSYBOX_CONFIG_FEATURE_2_4_MODULES
|
||||
help
|
||||
This is a special uClinux only memory optimization that lets insmod
|
||||
load the specified kernel module directly into kernel space, reducing
|
||||
memory usage by preventing the need for two copies of the module
|
||||
being loaded into memory.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_INSMOD_LOAD_MAP
|
||||
bool "Enable load map (-m) option"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_INSMOD && ( BUSYBOX_CONFIG_FEATURE_2_4_MODULES || BUSYBOX_CONFIG_FEATURE_2_6_MODULES )
|
||||
help
|
||||
Enabling this, one would be able to get a load map
|
||||
output on stdout. This makes kernel module debugging
|
||||
easier.
|
||||
If you don't plan to debug kernel modules, you
|
||||
don't need this option.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_INSMOD_LOAD_MAP_FULL
|
||||
bool "Symbols in load map"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_FEATURE_INSMOD_LOAD_MAP
|
||||
help
|
||||
Without this option, -m will only output section
|
||||
load map. With this option, -m will also output
|
||||
symbols load map.
|
||||
|
||||
config BUSYBOX_CONFIG_RMMOD
|
||||
bool "rmmod"
|
||||
default y
|
||||
@ -156,12 +90,13 @@ config BUSYBOX_CONFIG_LSMOD
|
||||
lsmod is used to display a list of loaded modules.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_LSMOD_PRETTY_2_6_OUTPUT
|
||||
bool "Pretty output for 2.6.x Linux kernels"
|
||||
bool "Pretty output"
|
||||
default y
|
||||
depends on BUSYBOX_CONFIG_LSMOD
|
||||
help
|
||||
This option makes output format of lsmod adjusted to
|
||||
the format of module-init-tools for Linux kernel 2.6.
|
||||
Increases size somewhat.
|
||||
|
||||
config BUSYBOX_CONFIG_MODPROBE
|
||||
bool "modprobe"
|
||||
@ -174,38 +109,11 @@ config BUSYBOX_CONFIG_MODPROBE
|
||||
Note that in the state, modprobe does not understand multiple
|
||||
module options from the configuration file. See option below.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_MODPROBE_MULTIPLE_OPTIONS
|
||||
bool
|
||||
prompt "Multiple options parsing"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_MODPROBE
|
||||
help
|
||||
Allow modprobe to understand more than one option to pass to
|
||||
modules.
|
||||
|
||||
This is a WIP, while waiting for a common argument parsing
|
||||
common amongst all BB applets (shell, modprobe, etc...) and
|
||||
adds around 600 bytes on x86, 700 bytes on ARM. The code is
|
||||
biggish and uggly, but just works.
|
||||
|
||||
Saying Y here is not a bad idea if you're not that short
|
||||
on storage capacity.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_MODPROBE_FANCY_ALIAS
|
||||
bool
|
||||
prompt "Fancy alias parsing"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_MODPROBE && BUSYBOX_CONFIG_FEATURE_2_6_MODULES
|
||||
help
|
||||
Say 'y' here to enable parsing of aliases with underscore/dash
|
||||
mismatch between module name and file name, along with bus-specific
|
||||
aliases (such as pci:... or usb:... aliases).
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_MODPROBE_BLACKLIST
|
||||
bool
|
||||
prompt "Blacklist support"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_MODPROBE && BUSYBOX_CONFIG_FEATURE_2_6_MODULES
|
||||
depends on BUSYBOX_CONFIG_MODPROBE
|
||||
help
|
||||
Say 'y' here to enable support for the 'blacklist' command in
|
||||
modprobe.conf. This prevents the alias resolver to resolve
|
||||
@ -213,60 +121,110 @@ config BUSYBOX_CONFIG_FEATURE_MODPROBE_BLACKLIST
|
||||
hardware autodetection scripts to load modules like evdev, frame
|
||||
buffer drivers etc.
|
||||
|
||||
config BUSYBOX_CONFIG_DEPMOD
|
||||
bool "depmod"
|
||||
default n
|
||||
depends on !BUSYBOX_CONFIG_MODPROBE_SMALL
|
||||
help
|
||||
depmod generates modules.dep (and potentially modules.alias
|
||||
and modules.symbols) that contain dependency information
|
||||
for modprobe.
|
||||
|
||||
comment "Options common to multiple modutils"
|
||||
depends on BUSYBOX_CONFIG_INSMOD || BUSYBOX_CONFIG_RMMOD || BUSYBOX_CONFIG_MODPROBE || BUSYBOX_CONFIG_LSMOD || BUSYBOX_CONFIG_DEPMOD
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_2_4_MODULES
|
||||
bool "Support version 2.2/2.4 Linux kernels"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_INSMOD || BUSYBOX_CONFIG_RMMOD || BUSYBOX_CONFIG_LSMOD
|
||||
help
|
||||
Support module loading for 2.2.x and 2.4.x Linux kernels.
|
||||
This increases size considerably. Say N unless you plan
|
||||
to run ancient kernels.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_INSMOD_VERSION_CHECKING
|
||||
bool "Enable module version checking"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_FEATURE_2_4_MODULES && (BUSYBOX_CONFIG_INSMOD || BUSYBOX_CONFIG_MODPROBE)
|
||||
help
|
||||
Support checking of versions for modules. This is used to
|
||||
ensure that the kernel and module are made for each other.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_INSMOD_KSYMOOPS_SYMBOLS
|
||||
bool "Add module symbols to kernel symbol table"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_FEATURE_2_4_MODULES && (BUSYBOX_CONFIG_INSMOD || BUSYBOX_CONFIG_MODPROBE)
|
||||
help
|
||||
By adding module symbols to the kernel symbol table, Oops messages
|
||||
occuring within kernel modules can be properly debugged. By enabling
|
||||
this feature, module symbols will always be added to the kernel symbol
|
||||
table for properly debugging support. If you are not interested in
|
||||
Oops messages from kernel modules, say N.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_INSMOD_LOADINKMEM
|
||||
bool "In kernel memory optimization (uClinux only)"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_FEATURE_2_4_MODULES && (BUSYBOX_CONFIG_INSMOD || BUSYBOX_CONFIG_MODPROBE)
|
||||
help
|
||||
This is a special uClinux only memory optimization that lets insmod
|
||||
load the specified kernel module directly into kernel space, reducing
|
||||
memory usage by preventing the need for two copies of the module
|
||||
being loaded into memory.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_INSMOD_LOAD_MAP
|
||||
bool "Enable insmod load map (-m) option"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_FEATURE_2_4_MODULES && BUSYBOX_CONFIG_INSMOD
|
||||
help
|
||||
Enabling this, one would be able to get a load map
|
||||
output on stdout. This makes kernel module debugging
|
||||
easier.
|
||||
If you don't plan to debug kernel modules, you
|
||||
don't need this option.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_INSMOD_LOAD_MAP_FULL
|
||||
bool "Symbols in load map"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_FEATURE_INSMOD_LOAD_MAP && !BUSYBOX_CONFIG_MODPROBE_SMALL
|
||||
help
|
||||
Without this option, -m will only output section
|
||||
load map. With this option, -m will also output
|
||||
symbols load map.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_CHECK_TAINTED_MODULE
|
||||
# Simulate indentation
|
||||
bool "Support tainted module checking with new kernels"
|
||||
default y
|
||||
depends on BUSYBOX_CONFIG_INSMOD || BUSYBOX_CONFIG_LSMOD
|
||||
depends on !BUSYBOX_CONFIG_MODPROBE_SMALL
|
||||
help
|
||||
Support checking for tainted modules. These are usually binary
|
||||
only modules that will make the linux-kernel list ignore your
|
||||
support request.
|
||||
This option is required to support GPLONLY modules.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_2_4_MODULES
|
||||
# Simulate indentation
|
||||
bool "Support version 2.2.x to 2.4.x Linux kernels"
|
||||
config BUSYBOX_CONFIG_FEATURE_MODUTILS_ALIAS
|
||||
bool "Support for module.aliases file"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_INSMOD || BUSYBOX_CONFIG_RMMOD || BUSYBOX_CONFIG_MODPROBE
|
||||
depends on BUSYBOX_CONFIG_DEPMOD || BUSYBOX_CONFIG_MODPROBE
|
||||
help
|
||||
Support module loading for 2.2.x and 2.4.x Linux kernels.
|
||||
Generate and parse modules.alias containing aliases for bus
|
||||
identifiers:
|
||||
alias pcmcia:m*c*f03fn*pfn*pa*pb*pc*pd* parport_cs
|
||||
|
||||
Note:
|
||||
This is automatically enabled if 2.6 modules are not enabled.
|
||||
and aliases for logical modules names e.g.:
|
||||
alias padlock_aes aes
|
||||
alias aes_i586 aes
|
||||
alias aes_generic aes
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_2_6_MODULES
|
||||
# Simulate indentation
|
||||
bool "Support version 2.6.x Linux kernels"
|
||||
default y
|
||||
depends on BUSYBOX_CONFIG_INSMOD || BUSYBOX_CONFIG_RMMOD || BUSYBOX_CONFIG_MODPROBE
|
||||
help
|
||||
Support module loading for newer 2.6.x Linux kernels.
|
||||
Say Y if unsure.
|
||||
|
||||
config BUSYBOX_CONFIG_DEFAULT_MODULES_DIR
|
||||
# Simulate indentation
|
||||
string "Default directory containing modules"
|
||||
default "/lib/modules"
|
||||
depends on BUSYBOX_CONFIG_INSMOD || BUSYBOX_CONFIG_RMMOD || BUSYBOX_CONFIG_MODPROBE || BUSYBOX_CONFIG_MODPROBE_SMALL || BUSYBOX_CONFIG_DEPMOD
|
||||
help
|
||||
Directory that contains kernel modules.
|
||||
Defaults to "/lib/modules"
|
||||
|
||||
config BUSYBOX_CONFIG_DEFAULT_DEPMOD_FILE
|
||||
# Simulate indentation
|
||||
string "Default name of modules.dep"
|
||||
default "modules.dep"
|
||||
depends on BUSYBOX_CONFIG_INSMOD || BUSYBOX_CONFIG_RMMOD || BUSYBOX_CONFIG_MODPROBE || BUSYBOX_CONFIG_MODPROBE_SMALL || BUSYBOX_CONFIG_DEPMOD
|
||||
help
|
||||
Filename that contains kernel modules dependencies.
|
||||
Defaults to "modules.dep"
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_QUERY_MODULE_INTERFACE
|
||||
bool
|
||||
config BUSYBOX_CONFIG_FEATURE_MODUTILS_SYMBOLS
|
||||
bool "Support for module.symbols file"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_FEATURE_2_4_MODULES && !BUSYBOX_CONFIG_FEATURE_2_6_MODULES
|
||||
depends on BUSYBOX_CONFIG_DEPMOD || BUSYBOX_CONFIG_MODPROBE
|
||||
help
|
||||
Generate and parse modules.symbols containing aliases for
|
||||
symbol_request() kernel calls, such as:
|
||||
alias symbol:usb_sg_init usbcore
|
||||
|
||||
Say Y if unsure.
|
||||
|
||||
endmenu
|
||||
|
@ -641,7 +641,7 @@ config BUSYBOX_CONFIG_FEATURE_NETSTAT_WIDE
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_NETSTAT_PRG
|
||||
bool "Enable PID/Program name output"
|
||||
default n
|
||||
default y
|
||||
depends on BUSYBOX_CONFIG_NETSTAT
|
||||
help
|
||||
Add support for -p flag to print out PID and program name.
|
||||
@ -687,18 +687,6 @@ config BUSYBOX_CONFIG_ROUTE
|
||||
help
|
||||
Route displays or manipulates the kernel's IP routing tables.
|
||||
|
||||
config BUSYBOX_CONFIG_SENDMAIL
|
||||
bool "sendmail"
|
||||
default n
|
||||
help
|
||||
Barebones sendmail.
|
||||
|
||||
config BUSYBOX_CONFIG_FETCHMAIL
|
||||
bool "fetchmail"
|
||||
default n
|
||||
help
|
||||
Barebones fetchmail.
|
||||
|
||||
config BUSYBOX_CONFIG_SLATTACH
|
||||
bool "slattach"
|
||||
default n
|
||||
@ -706,6 +694,16 @@ config BUSYBOX_CONFIG_SLATTACH
|
||||
slattach is a small utility to attach network interfaces to serial
|
||||
lines.
|
||||
|
||||
#config TC
|
||||
# bool "tc"
|
||||
# default n
|
||||
# help
|
||||
# show / manipulate traffic control settings
|
||||
#
|
||||
#config FEATURE_TC_INGRESS
|
||||
# def_bool n
|
||||
# depends on TC
|
||||
|
||||
config BUSYBOX_CONFIG_TELNET
|
||||
bool "telnet"
|
||||
default y
|
||||
@ -826,7 +824,7 @@ config BUSYBOX_CONFIG_FEATURE_TFTP_BLOCKSIZE
|
||||
Allow tftp to specify block size, and tftpd to understand
|
||||
"blksize" option.
|
||||
|
||||
config BUSYBOX_CONFIG_DEBUG_TFTP
|
||||
config BUSYBOX_CONFIG_TFTP_DEBUG
|
||||
bool "Enable debug"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_TFTP
|
||||
|
@ -74,14 +74,14 @@ config BUSYBOX_CONFIG_FEATURE_UDHCP_PORT
|
||||
At the cost of ~300 bytes, enables -P port option.
|
||||
This feature is typically not needed.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_UDHCP_DEBUG
|
||||
config BUSYBOX_CONFIG_UDHCP_DEBUG
|
||||
bool "Compile udhcp with noisy debugging messages"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_APP_UDHCPD || BUSYBOX_CONFIG_APP_UDHCPC
|
||||
help
|
||||
If selected, udhcpd will output extra debugging output.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_RFC3397
|
||||
config BUSYBOX_CONFIG_FEATURE_UDHCP_RFC3397
|
||||
bool "Support for RFC3397 domain search (experimental)"
|
||||
default y
|
||||
depends on BUSYBOX_CONFIG_APP_UDHCPD || BUSYBOX_CONFIG_APP_UDHCPC
|
||||
@ -89,7 +89,7 @@ config BUSYBOX_CONFIG_FEATURE_RFC3397
|
||||
If selected, both client and server will support passing of domain
|
||||
search lists via option 119, specified in RFC3397.
|
||||
|
||||
config BUSYBOX_CONFIG_DHCPC_DEFAULT_SCRIPT
|
||||
config BUSYBOX_CONFIG_UDHCPC_DEFAULT_SCRIPT
|
||||
string "Absolute path to config script"
|
||||
default "/usr/share/udhcpc/default.script"
|
||||
depends on BUSYBOX_CONFIG_APP_UDHCPC
|
||||
|
@ -1,3 +1,8 @@
|
||||
#
|
||||
# For a description of the syntax of this configuration file,
|
||||
# see scripts/kbuild/config-language.txt.
|
||||
#
|
||||
|
||||
menu "Print Utilities"
|
||||
|
||||
config BUSYBOX_CONFIG_LPD
|
||||
|
@ -135,32 +135,51 @@ config BUSYBOX_CONFIG_TOP
|
||||
system.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_TOP_CPU_USAGE_PERCENTAGE
|
||||
bool "Show CPU per-process usage percentage (adds 2k bytes)"
|
||||
bool "Show CPU per-process usage percentage"
|
||||
default y
|
||||
depends on BUSYBOX_CONFIG_TOP
|
||||
help
|
||||
Make top display CPU usage for each process.
|
||||
This adds about 2k.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_TOP_CPU_GLOBAL_PERCENTS
|
||||
bool "Show CPU global usage percentage (adds 0.5k bytes)"
|
||||
bool "Show CPU global usage percentage"
|
||||
default y
|
||||
depends on BUSYBOX_CONFIG_FEATURE_TOP_CPU_USAGE_PERCENTAGE
|
||||
help
|
||||
Makes top display "CPU: NN% usr NN% sys..." line.
|
||||
This adds about 0.5k.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_TOP_SMP_CPU
|
||||
bool "SMP CPU usage display ('c' key)"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_FEATURE_TOP_CPU_GLOBAL_PERCENTS
|
||||
help
|
||||
Allow 'c' key to switch between individual/cumulative CPU stats
|
||||
This adds about 0.5k.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_TOP_DECIMALS
|
||||
bool "Show 1/10th of a percent in CPU/mem statistics (adds 0.3k bytes)"
|
||||
bool "Show 1/10th of a percent in CPU/mem statistics"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_FEATURE_TOP_CPU_USAGE_PERCENTAGE
|
||||
help
|
||||
Show 1/10th of a percent in CPU/mem statistics.
|
||||
This adds about 0.3k.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_TOPMEM
|
||||
bool "topmem"
|
||||
config BUSYBOX_CONFIG_FEATURE_TOP_SMP_PROCESS
|
||||
bool "Show CPU process runs on ('j' field)"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_TOP
|
||||
help
|
||||
Enable 's' in top (gives lots of memory info)
|
||||
Show CPU where process was last found running on.
|
||||
This is the 'j' field.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_TOPMEM
|
||||
bool "Topmem command ('s' key)"
|
||||
default n
|
||||
depends on BUSYBOX_CONFIG_TOP
|
||||
help
|
||||
Enable 's' in top (gives lots of memory info).
|
||||
|
||||
config BUSYBOX_CONFIG_UPTIME
|
||||
bool "uptime"
|
||||
@ -173,11 +192,9 @@ config BUSYBOX_CONFIG_UPTIME
|
||||
config BUSYBOX_CONFIG_WATCH
|
||||
bool "watch"
|
||||
default n
|
||||
#huh?? select DATE
|
||||
help
|
||||
watch is used to execute a program periodically, showing
|
||||
output to the screen.
|
||||
|
||||
|
||||
endmenu
|
||||
|
||||
|
@ -20,6 +20,15 @@ config BUSYBOX_CONFIG_RUNSVDIR
|
||||
a directory, in the services directory dir, up to a limit of 1000
|
||||
subdirectories, and restarts a runsv process if it terminates.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_RUNSVDIR_LOG
|
||||
bool "Enable scrolling argument log"
|
||||
depends on BUSYBOX_CONFIG_RUNSVDIR
|
||||
default n
|
||||
help
|
||||
Enable feature where second parameter of runsvdir holds last error
|
||||
message (viewable via top/ps). Otherwise (feature is off
|
||||
or no parameter), error messages go to stderr only.
|
||||
|
||||
config BUSYBOX_CONFIG_SV
|
||||
bool "sv"
|
||||
default n
|
||||
@ -27,6 +36,14 @@ config BUSYBOX_CONFIG_SV
|
||||
sv reports the current status and controls the state of services
|
||||
monitored by the runsv supervisor.
|
||||
|
||||
config BUSYBOX_CONFIG_SV_DEFAULT_SERVICE_DIR
|
||||
string "Default directory for services"
|
||||
default "/var/service"
|
||||
depends on BUSYBOX_CONFIG_SV
|
||||
help
|
||||
Default directory for services.
|
||||
Defaults to "/var/service"
|
||||
|
||||
config BUSYBOX_CONFIG_SVLOGD
|
||||
bool "svlogd"
|
||||
default n
|
||||
|
@ -3,7 +3,7 @@
|
||||
# see scripts/kbuild/config-language.txt.
|
||||
#
|
||||
|
||||
menu "Selinux Utilities"
|
||||
menu "SELinux Utilities"
|
||||
depends on BUSYBOX_CONFIG_SELINUX
|
||||
|
||||
config BUSYBOX_CONFIG_CHCON
|
||||
|
@ -5,6 +5,15 @@
|
||||
|
||||
menu "Linux System Utilities"
|
||||
|
||||
config BUSYBOX_CONFIG_BLKID
|
||||
bool "blkid"
|
||||
default n
|
||||
select BUSYBOX_CONFIG_VOLUMEID
|
||||
help
|
||||
Lists labels and UUIDs of all filesystems.
|
||||
WARNING:
|
||||
With all submodules selected, it will add ~8k to busybox.
|
||||
|
||||
config BUSYBOX_CONFIG_DMESG
|
||||
bool "dmesg"
|
||||
default y
|
||||
@ -156,9 +165,7 @@ config BUSYBOX_CONFIG_FINDFS
|
||||
default n
|
||||
select BUSYBOX_CONFIG_VOLUMEID
|
||||
help
|
||||
This is similar to the findfs program that is part of the e2fsprogs
|
||||
package. However, the e2fsprogs version only support ext2/3. This
|
||||
version supports those in addition to FAT, swap, and ReiserFS.
|
||||
Prints the name of a filesystem with given label or UUID.
|
||||
WARNING:
|
||||
With all submodules selected, it will add ~8k to busybox.
|
||||
|
||||
@ -396,10 +403,8 @@ config BUSYBOX_CONFIG_FEATURE_USE_TERMIOS
|
||||
unable to move the cursor.
|
||||
|
||||
config BUSYBOX_CONFIG_VOLUMEID
|
||||
bool "Routines for detecting label and uuid on common filesystems"
|
||||
bool #No description makes it a hidden option
|
||||
default n
|
||||
help
|
||||
TODO
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_VOLUMEID_EXT
|
||||
bool "Ext filesystem"
|
||||
@ -651,7 +656,7 @@ config BUSYBOX_CONFIG_FEATURE_MOUNT_LABEL
|
||||
select BUSYBOX_CONFIG_VOLUMEID
|
||||
help
|
||||
This allows for specifying a device by label or uuid, rather than by
|
||||
name. This feature utilizes the same functionality as findfs.
|
||||
name. This feature utilizes the same functionality as blkid/findfs.
|
||||
|
||||
config BUSYBOX_CONFIG_FEATURE_MOUNT_NFS
|
||||
bool "Support mounting NFS file systems"
|
||||
|
@ -1,6 +1,6 @@
|
||||
--- a/init/init.c
|
||||
+++ b/init/init.c
|
||||
@@ -498,12 +498,11 @@ static void run_actions(int action_type)
|
||||
@@ -497,12 +497,11 @@ static void run_actions(int action_type)
|
||||
for (a = init_action_list; a; a = tmp) {
|
||||
tmp = a->next;
|
||||
if (a->action_type & action_type) {
|
||||
|
@ -1,13 +0,0 @@
|
||||
--- a/include/libbb.h
|
||||
+++ b/include/libbb.h
|
||||
@@ -83,7 +83,10 @@
|
||||
extern char **environ;
|
||||
|
||||
/* Set the group set for the current user to GROUPS (N of them). */
|
||||
+#if !defined(__APPLE__)
|
||||
int setgroups(size_t n, const gid_t *groups);
|
||||
+#endif
|
||||
+
|
||||
#if defined(__GLIBC__) && __GLIBC__ < 2
|
||||
int vdprintf(int d, const char *format, va_list ap);
|
||||
#endif
|
@ -1,9 +1,9 @@
|
||||
--- a/networking/wget.c
|
||||
+++ b/networking/wget.c
|
||||
@@ -437,7 +437,7 @@ int wget_main(int argc UNUSED_PARAM, cha
|
||||
"directory-prefix\0" Required_argument "P"
|
||||
"proxy\0" Required_argument "Y"
|
||||
"user-agent\0" Required_argument "U"
|
||||
@@ -443,7 +443,7 @@ int wget_main(int argc UNUSED_PARAM, cha
|
||||
// "tries\0" Required_argument "t"
|
||||
// "timeout\0" Required_argument "T"
|
||||
/* Ignored (we always use PASV): */
|
||||
- "passive-ftp\0" No_argument "\xff"
|
||||
+ "passive-ftp\0" No_argument "\xfd"
|
||||
"header\0" Required_argument "\xfe"
|
||||
|
@ -9,7 +9,7 @@
|
||||
if (packet_num == 0)
|
||||
xid = random_xid();
|
||||
|
||||
@@ -383,7 +383,7 @@ int udhcpc_main(int argc UNUSED_PARAM, c
|
||||
@@ -384,7 +384,7 @@ int udhcpc_main(int argc UNUSED_PARAM, c
|
||||
continue;
|
||||
case RENEW_REQUESTED:
|
||||
case REQUESTING:
|
||||
|
@ -1,6 +1,6 @@
|
||||
--- a/networking/udhcp/packet.c
|
||||
+++ b/networking/udhcp/packet.c
|
||||
@@ -114,6 +114,10 @@ uint16_t udhcp_checksum(void *addr, int
|
||||
@@ -114,6 +114,10 @@ uint16_t FAST_FUNC udhcp_checksum(void *
|
||||
return ~sum;
|
||||
}
|
||||
|
||||
@ -10,8 +10,8 @@
|
||||
+}
|
||||
|
||||
/* Construct a ip/udp header for a packet, send packet */
|
||||
int udhcp_send_raw_packet(struct dhcpMessage *payload,
|
||||
@@ -125,11 +129,7 @@ int udhcp_send_raw_packet(struct dhcpMes
|
||||
int FAST_FUNC udhcp_send_raw_packet(struct dhcpMessage *payload,
|
||||
@@ -126,11 +130,7 @@ int FAST_FUNC udhcp_send_raw_packet(stru
|
||||
int fd;
|
||||
int result = -1;
|
||||
const char *msg;
|
||||
@ -24,7 +24,7 @@
|
||||
|
||||
fd = socket(PF_PACKET, SOCK_DGRAM, htons(ETH_P_IP));
|
||||
if (fd < 0) {
|
||||
@@ -139,7 +139,7 @@ int udhcp_send_raw_packet(struct dhcpMes
|
||||
@@ -140,7 +140,7 @@ int FAST_FUNC udhcp_send_raw_packet(stru
|
||||
|
||||
memset(&dest, 0, sizeof(dest));
|
||||
memset(&packet, 0, sizeof(packet));
|
||||
@ -33,7 +33,7 @@
|
||||
|
||||
dest.sll_family = AF_PACKET;
|
||||
dest.sll_protocol = htons(ETH_P_IP);
|
||||
@@ -156,23 +156,18 @@ int udhcp_send_raw_packet(struct dhcpMes
|
||||
@@ -157,23 +157,18 @@ int FAST_FUNC udhcp_send_raw_packet(stru
|
||||
packet.ip.daddr = dest_ip;
|
||||
packet.udp.source = htons(source_port);
|
||||
packet.udp.dest = htons(dest_port);
|
||||
@ -63,7 +63,7 @@
|
||||
(struct sockaddr *) &dest, sizeof(dest));
|
||||
msg = "sendto";
|
||||
ret_close:
|
||||
@@ -224,8 +219,7 @@ int udhcp_send_kernel_packet(struct dhcp
|
||||
@@ -225,8 +220,7 @@ int FAST_FUNC udhcp_send_kernel_packet(s
|
||||
goto ret_close;
|
||||
}
|
||||
|
||||
|
@ -1,18 +1,18 @@
|
||||
--- a/networking/udhcp/clientpacket.c
|
||||
+++ b/networking/udhcp/clientpacket.c
|
||||
@@ -101,6 +101,7 @@ int send_decline(uint32_t xid, uint32_t
|
||||
int send_discover(uint32_t xid, uint32_t requested)
|
||||
@@ -126,6 +126,7 @@ int FAST_FUNC send_decline(uint32_t xid,
|
||||
int FAST_FUNC send_discover(uint32_t xid, uint32_t requested)
|
||||
{
|
||||
struct dhcpMessage packet;
|
||||
+ static int msgs = 0;
|
||||
|
||||
init_packet(&packet, DHCPDISCOVER);
|
||||
packet.xid = xid;
|
||||
@@ -113,6 +114,7 @@ int send_discover(uint32_t xid, uint32_t
|
||||
@@ -138,6 +139,7 @@ int FAST_FUNC send_discover(uint32_t xid
|
||||
|
||||
add_param_req_option(&packet);
|
||||
|
||||
+ if (msgs++ < 3)
|
||||
bb_info_msg("Sending discover...");
|
||||
return udhcp_send_raw_packet(&packet, INADDR_ANY, CLIENT_PORT, INADDR_BROADCAST,
|
||||
SERVER_PORT, MAC_BCAST_ADDR, client_config.ifindex);
|
||||
return raw_bcast_from_client_config_ifindex(&packet);
|
||||
}
|
||||
|
@ -8,8 +8,8 @@
|
||||
+ * member interfaces were added/removed or if the status of the
|
||||
+ * bridge changed).
|
||||
+ * Workaround: refresh it here before processing the next packet */
|
||||
+ read_interface(client_config.interface, &client_config.ifindex, NULL, client_config.arp);
|
||||
+ udhcp_read_interface(client_config.interface, &client_config.ifindex, NULL, client_config.arp);
|
||||
+
|
||||
if (listen_mode != LISTEN_NONE && sockfd < 0) {
|
||||
if (listen_mode == LISTEN_KERNEL)
|
||||
sockfd = listen_socket(/*INADDR_ANY,*/ CLIENT_PORT, client_config.interface);
|
||||
sockfd = udhcp_listen_socket(/*INADDR_ANY,*/ CLIENT_PORT, client_config.interface);
|
||||
|
@ -1,6 +1,6 @@
|
||||
--- a/shell/ash.c
|
||||
+++ b/shell/ash.c
|
||||
@@ -12018,8 +12018,17 @@ exportcmd(int argc UNUSED_PARAM, char **
|
||||
@@ -12159,8 +12159,17 @@ exportcmd(int argc UNUSED_PARAM, char **
|
||||
const char *p;
|
||||
char **aptr;
|
||||
int flag = argv[0][0] == 'r' ? VREADONLY : VEXPORT;
|
||||
@ -19,7 +19,7 @@
|
||||
aptr = argptr;
|
||||
name = *aptr;
|
||||
if (name) {
|
||||
@@ -12031,10 +12040,12 @@ exportcmd(int argc UNUSED_PARAM, char **
|
||||
@@ -12172,10 +12181,12 @@ exportcmd(int argc UNUSED_PARAM, char **
|
||||
vp = *findvar(hashvar(name), name);
|
||||
if (vp) {
|
||||
vp->flags |= flag;
|
||||
|
@ -1,6 +1,6 @@
|
||||
--- a/include/applets.h
|
||||
+++ b/include/applets.h
|
||||
@@ -261,6 +261,7 @@ USE_MT(APPLET(mt, _BB_DIR_BIN, _BB_SUID_
|
||||
@@ -263,6 +263,7 @@ USE_MT(APPLET(mt, _BB_DIR_BIN, _BB_SUID_
|
||||
USE_MV(APPLET(mv, _BB_DIR_BIN, _BB_SUID_NEVER))
|
||||
USE_NAMEIF(APPLET(nameif, _BB_DIR_SBIN, _BB_SUID_NEVER))
|
||||
USE_NC(APPLET(nc, _BB_DIR_USR_BIN, _BB_SUID_NEVER))
|
||||
@ -10,7 +10,7 @@
|
||||
USE_NMETER(APPLET(nmeter, _BB_DIR_USR_BIN, _BB_SUID_NEVER))
|
||||
--- a/include/usage.h
|
||||
+++ b/include/usage.h
|
||||
@@ -2816,6 +2816,9 @@
|
||||
@@ -2849,6 +2849,9 @@
|
||||
|
||||
#endif
|
||||
|
||||
@ -37,7 +37,7 @@
|
||||
default n
|
||||
--- a/networking/Kbuild
|
||||
+++ b/networking/Kbuild
|
||||
@@ -24,6 +24,7 @@ lib-$(CONFIG_IP) += ip.o
|
||||
@@ -23,6 +23,7 @@ lib-$(CONFIG_IP) += ip.o
|
||||
lib-$(CONFIG_IPCALC) += ipcalc.o
|
||||
lib-$(CONFIG_NAMEIF) += nameif.o
|
||||
lib-$(CONFIG_NC) += nc.o
|
||||
|
@ -3,7 +3,7 @@
|
||||
|
||||
--- a/networking/httpd.c
|
||||
+++ b/networking/httpd.c
|
||||
@@ -1705,21 +1705,32 @@ static int check_user_passwd(const char
|
||||
@@ -1713,21 +1713,32 @@ static int check_user_passwd(const char
|
||||
|
||||
if (ENABLE_FEATURE_HTTPD_AUTH_MD5) {
|
||||
char *md5_passwd;
|
||||
|
@ -1,6 +1,6 @@
|
||||
--- a/include/applets.h
|
||||
+++ b/include/applets.h
|
||||
@@ -222,6 +222,7 @@ USE_LN(APPLET_NOEXEC(ln, ln, _BB_DIR_BIN
|
||||
@@ -223,6 +223,7 @@ USE_LN(APPLET_NOEXEC(ln, ln, _BB_DIR_BIN
|
||||
USE_LOAD_POLICY(APPLET(load_policy, _BB_DIR_USR_SBIN, _BB_SUID_NEVER))
|
||||
USE_LOADFONT(APPLET(loadfont, _BB_DIR_USR_SBIN, _BB_SUID_NEVER))
|
||||
USE_LOADKMAP(APPLET(loadkmap, _BB_DIR_SBIN, _BB_SUID_NEVER))
|
||||
@ -10,7 +10,7 @@
|
||||
USE_LOGNAME(APPLET_NOFORK(logname, logname, _BB_DIR_USR_BIN, _BB_SUID_NEVER, logname))
|
||||
--- a/include/usage.h
|
||||
+++ b/include/usage.h
|
||||
@@ -2132,6 +2132,9 @@
|
||||
@@ -2150,6 +2150,9 @@
|
||||
#define loadkmap_example_usage \
|
||||
"$ loadkmap < /etc/i18n/lang-keymap\n"
|
||||
|
||||
@ -22,7 +22,7 @@
|
||||
#define logger_full_usage "\n\n" \
|
||||
--- a/miscutils/Config.in
|
||||
+++ b/miscutils/Config.in
|
||||
@@ -366,6 +366,12 @@ config FEATURE_HDPARM_HDIO_GETSET_DMA
|
||||
@@ -395,6 +395,12 @@ config FEATURE_HDPARM_HDIO_GETSET_DMA
|
||||
Enables the 'hdparm -d' option to get/set using_dma flag.
|
||||
This is dangerous stuff, so you should probably say N.
|
||||
|
||||
@ -37,7 +37,7 @@
|
||||
default n
|
||||
--- a/miscutils/Kbuild
|
||||
+++ b/miscutils/Kbuild
|
||||
@@ -20,6 +20,7 @@ lib-$(CONFIG_INOTIFYD) += inotifyd.o
|
||||
@@ -21,6 +21,7 @@ lib-$(CONFIG_INOTIFYD) += inotifyd.o
|
||||
lib-$(CONFIG_FEATURE_LAST_SMALL)+= last.o
|
||||
lib-$(CONFIG_FEATURE_LAST_FANCY)+= last_fancy.o
|
||||
lib-$(CONFIG_LESS) += less.o
|
||||
|
@ -1,6 +1,6 @@
|
||||
--- a/include/usage.h
|
||||
+++ b/include/usage.h
|
||||
@@ -1552,7 +1552,8 @@
|
||||
@@ -1558,7 +1558,8 @@
|
||||
USE_FEATURE_HTTPD_BASIC_AUTH(" [-r realm]") \
|
||||
USE_FEATURE_HTTPD_AUTH_MD5(" [-m pass]") \
|
||||
" [-h home]" \
|
||||
@ -10,7 +10,7 @@
|
||||
#define httpd_full_usage "\n\n" \
|
||||
"Listen for incoming HTTP requests\n" \
|
||||
"\nOptions:" \
|
||||
@@ -1570,6 +1571,8 @@
|
||||
@@ -1576,6 +1577,8 @@
|
||||
"\n -h HOME Home directory (default .)" \
|
||||
"\n -e STRING HTML encode STRING" \
|
||||
"\n -d STRING URL decode STRING" \
|
||||
@ -18,7 +18,7 @@
|
||||
+ "\n -H HOST Redirect target host" \
|
||||
|
||||
#define hwclock_trivial_usage \
|
||||
USE_GETOPT_LONG( \
|
||||
USE_FEATURE_HWCLOCK_LONG_OPTIONS( \
|
||||
--- a/networking/httpd.c
|
||||
+++ b/networking/httpd.c
|
||||
@@ -248,6 +248,8 @@ struct globals {
|
||||
@ -30,7 +30,7 @@
|
||||
Htaccess_IP *ip_a_d; /* config allow/deny lines */
|
||||
|
||||
USE_FEATURE_HTTPD_BASIC_AUTH(const char *g_realm;)
|
||||
@@ -293,6 +295,8 @@ struct globals {
|
||||
@@ -295,6 +297,8 @@ struct globals {
|
||||
#define index_page (G.index_page )
|
||||
#define found_mime_type (G.found_mime_type )
|
||||
#define found_moved_temporarily (G.found_moved_temporarily)
|
||||
@ -39,7 +39,7 @@
|
||||
#define last_mod (G.last_mod )
|
||||
#define ip_a_d (G.ip_a_d )
|
||||
#define g_realm (G.g_realm )
|
||||
@@ -999,8 +1003,11 @@ static void send_headers(int responseNum
|
||||
@@ -1003,8 +1007,11 @@ static void send_headers(int responseNum
|
||||
}
|
||||
#endif
|
||||
if (responseNum == HTTP_MOVED_TEMPORARILY) {
|
||||
@ -52,7 +52,7 @@
|
||||
(g_query ? "?" : ""),
|
||||
(g_query ? g_query : ""));
|
||||
}
|
||||
@@ -1931,8 +1938,12 @@ static void handle_incoming_and_exit(con
|
||||
@@ -1939,8 +1946,12 @@ static void handle_incoming_and_exit(con
|
||||
} while (*++tptr);
|
||||
*++urlp = '\0'; /* terminate after last character */
|
||||
|
||||
@ -66,7 +66,7 @@
|
||||
if (is_directory(urlcopy + 1, 1, &sb)) {
|
||||
found_moved_temporarily = urlcopy;
|
||||
}
|
||||
@@ -2281,7 +2292,9 @@ static void sighup_handler(int sig)
|
||||
@@ -2293,7 +2304,9 @@ static void sighup_handler(int sig)
|
||||
#endif
|
||||
|
||||
enum {
|
||||
@ -77,7 +77,7 @@
|
||||
d_opt_decode_url,
|
||||
h_opt_home_httpd,
|
||||
USE_FEATURE_HTTPD_ENCODE_URL_STR(e_opt_encode_url,)
|
||||
@@ -2330,12 +2343,13 @@ int httpd_main(int argc UNUSED_PARAM, ch
|
||||
@@ -2342,12 +2355,13 @@ int httpd_main(int argc UNUSED_PARAM, ch
|
||||
/* We do not "absolutize" path given by -h (home) opt.
|
||||
* If user gives relative path in -h,
|
||||
* $SCRIPT_FILENAME will not be set. */
|
||||
|
@ -1,6 +1,6 @@
|
||||
--- a/networking/httpd.c
|
||||
+++ b/networking/httpd.c
|
||||
@@ -1255,10 +1255,10 @@ static NOINLINE void cgi_io_loop_and_exi
|
||||
@@ -1259,10 +1259,10 @@ static NOINLINE void cgi_io_loop_and_exi
|
||||
if (full_write(STDOUT_FILENO, HTTP_200, sizeof(HTTP_200)-1) != sizeof(HTTP_200)-1)
|
||||
break;
|
||||
}
|
||||
|
@ -1,6 +1,6 @@
|
||||
--- a/networking/httpd.c
|
||||
+++ b/networking/httpd.c
|
||||
@@ -1816,6 +1816,7 @@ static void handle_incoming_and_exit(con
|
||||
@@ -1824,6 +1824,7 @@ static void handle_incoming_and_exit(con
|
||||
char *header_ptr = header_ptr;
|
||||
Htaccess_Proxy *proxy_entry;
|
||||
#endif
|
||||
|
@ -1,42 +0,0 @@
|
||||
--- a/networking/httpd.c
|
||||
+++ b/networking/httpd.c
|
||||
@@ -256,6 +256,8 @@ struct globals {
|
||||
USE_FEATURE_HTTPD_BASIC_AUTH(char *remoteuser;)
|
||||
USE_FEATURE_HTTPD_CGI(char *referer;)
|
||||
USE_FEATURE_HTTPD_CGI(char *user_agent;)
|
||||
+ USE_FEATURE_HTTPD_CGI(char *http_accept;)
|
||||
+ USE_FEATURE_HTTPD_CGI(char *http_accept_language;)
|
||||
|
||||
off_t file_size; /* -1 - unknown */
|
||||
#if ENABLE_FEATURE_HTTPD_RANGES
|
||||
@@ -303,6 +305,8 @@ struct globals {
|
||||
#define remoteuser (G.remoteuser )
|
||||
#define referer (G.referer )
|
||||
#define user_agent (G.user_agent )
|
||||
+#define http_accept (G.http_accept )
|
||||
+#define http_accept_language (G.http_accept_language)
|
||||
#define file_size (G.file_size )
|
||||
#if ENABLE_FEATURE_HTTPD_RANGES
|
||||
#define range_start (G.range_start )
|
||||
@@ -1391,6 +1395,10 @@ static void send_cgi_and_exit(
|
||||
}
|
||||
}
|
||||
setenv1("HTTP_USER_AGENT", user_agent);
|
||||
+ if (http_accept)
|
||||
+ setenv1("HTTP_ACCEPT", http_accept);
|
||||
+ if (http_accept_language)
|
||||
+ setenv1("HTTP_ACCEPT_LANGUAGE", http_accept_language);
|
||||
if (post_len)
|
||||
putenv(xasprintf("CONTENT_LENGTH=%d", post_len));
|
||||
if (cookie)
|
||||
@@ -2028,6 +2036,10 @@ static void handle_incoming_and_exit(con
|
||||
referer = xstrdup(skip_whitespace(iobuf + sizeof("Referer:")-1));
|
||||
} else if (STRNCASECMP(iobuf, "User-Agent:") == 0) {
|
||||
user_agent = xstrdup(skip_whitespace(iobuf + sizeof("User-Agent:")-1));
|
||||
+ } else if (STRNCASECMP(iobuf, "Accept:") == 0) {
|
||||
+ http_accept = xstrdup(skip_whitespace(iobuf + sizeof("Accept:")-1));
|
||||
+ } else if (STRNCASECMP(iobuf, "Accept-Language:") == 0) {
|
||||
+ http_accept_language = xstrdup(skip_whitespace(iobuf + sizeof("Accept-Language:")-1));
|
||||
}
|
||||
#endif
|
||||
#if ENABLE_FEATURE_HTTPD_BASIC_AUTH
|
@ -1,35 +1,17 @@
|
||||
--- a/modutils/insmod.c
|
||||
+++ b/modutils/insmod.c
|
||||
@@ -61,21 +61,117 @@
|
||||
@@ -9,6 +9,99 @@
|
||||
|
||||
#include "libbb.h"
|
||||
#include <libgen.h>
|
||||
#include <sys/utsname.h>
|
||||
+#if ENABLE_FEATURE_2_6_MODULES
|
||||
#include "modutils.h"
|
||||
+#ifndef CONFIG_FEATURE_2_4_MODULES
|
||||
+#include <sys/mman.h>
|
||||
+#include <asm/unistd.h>
|
||||
+#include <sys/syscall.h>
|
||||
+#include <sys/utsname.h>
|
||||
+#endif
|
||||
|
||||
#if !ENABLE_FEATURE_2_4_MODULES && !ENABLE_FEATURE_2_6_MODULES
|
||||
#undef ENABLE_FEATURE_2_4_MODULES
|
||||
#define ENABLE_FEATURE_2_4_MODULES 1
|
||||
#endif
|
||||
|
||||
-/*
|
||||
- * Big piece of 2.4-specific code
|
||||
- */
|
||||
#if ENABLE_FEATURE_2_4_MODULES
|
||||
-
|
||||
+int insmod_main_24(int argc, char **argv);
|
||||
+#endif
|
||||
#if ENABLE_FEATURE_2_6_MODULES
|
||||
-static int insmod_ng_main(int argc, char **argv);
|
||||
+int insmod_main_26(int argc, char **argv);
|
||||
#endif
|
||||
+int insmod_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE;
|
||||
+
|
||||
+static char *g_filename = NULL;
|
||||
+#define _PATH_MODULES "/lib/modules"
|
||||
+
|
||||
+static int FAST_FUNC check_module_name_match(const char *filename, struct stat *statbuf,
|
||||
+ void *userdata, int depth)
|
||||
@ -92,7 +74,7 @@
|
||||
+ * follow symlinks, but we do want to follow the
|
||||
+ * /lib/modules/`uname -r` dir, So resolve it ourselves
|
||||
+ * if it is a link... */
|
||||
+ module_dir = concat_path_file(_PATH_MODULES, myuname.release);
|
||||
+ module_dir = concat_path_file(CONFIG_DEFAULT_MODULES_DIR, myuname.release);
|
||||
+ if (realpath(module_dir, real_module_dir) != NULL) {
|
||||
+ free(module_dir);
|
||||
+ module_dir = real_module_dir;
|
||||
@ -112,623 +94,26 @@
|
||||
+
|
||||
+done:
|
||||
+ free(filename);
|
||||
|
||||
+
|
||||
+ return ret;
|
||||
+}
|
||||
+
|
||||
+/*
|
||||
+ * Big piece of 2.4-specific code
|
||||
+ */
|
||||
+#if ENABLE_FEATURE_2_4_MODULES
|
||||
#if ENABLE_FEATURE_INSMOD_LOADINKMEM
|
||||
#define LOADBITS 0
|
||||
#else
|
||||
@@ -184,7 +280,6 @@ static int insmod_ng_main(int argc, char
|
||||
/* Microblaze */
|
||||
#if defined(__microblaze__)
|
||||
#define USE_SINGLE
|
||||
-#include <linux/elf-em.h>
|
||||
#define MATCH_MACHINE(x) (x == EM_XILINX_MICROBLAZE)
|
||||
#define SHT_RELM SHT_RELA
|
||||
#define Elf32_RelM Elf32_Rela
|
||||
@@ -452,7 +547,7 @@ enum {
|
||||
/* The system calls unchanged between 2.0 and 2.1. */
|
||||
|
||||
unsigned long create_module(const char *, size_t);
|
||||
-int delete_module(const char *module, unsigned int flags);
|
||||
+int delete_module(const char *);
|
||||
|
||||
|
||||
#endif /* module.h */
|
||||
@@ -652,7 +747,7 @@ static struct obj_symbol *arch_new_symbo
|
||||
|
||||
static enum obj_reloc arch_apply_relocation(struct obj_file *f,
|
||||
struct obj_section *targsec,
|
||||
- /*struct obj_section *symsec,*/
|
||||
+ struct obj_section *symsec,
|
||||
struct obj_symbol *sym,
|
||||
ElfW(RelM) *rel, ElfW(Addr) value);
|
||||
|
||||
@@ -673,6 +768,7 @@ static int obj_gpl_license(struct obj_fi
|
||||
#define SPFX ""
|
||||
#endif
|
||||
|
||||
+
|
||||
enum { STRVERSIONLEN = 64 };
|
||||
|
||||
/*======================================================================*/
|
||||
@@ -788,28 +884,6 @@ static char *m_filename;
|
||||
static char *m_fullName;
|
||||
|
||||
|
||||
-/*======================================================================*/
|
||||
-
|
||||
-
|
||||
-static int FAST_FUNC check_module_name_match(const char *filename,
|
||||
- struct stat *statbuf UNUSED_PARAM,
|
||||
- void *userdata, int depth UNUSED_PARAM)
|
||||
-{
|
||||
- char *fullname = (char *) userdata;
|
||||
- char *tmp;
|
||||
-
|
||||
- if (fullname[0] == '\0')
|
||||
- return FALSE;
|
||||
-
|
||||
- tmp = bb_get_last_path_component_nostrip(filename);
|
||||
- if (strcmp(tmp, fullname) == 0) {
|
||||
- /* Stop searching if we find a match */
|
||||
- m_filename = xstrdup(filename);
|
||||
- return FALSE;
|
||||
- }
|
||||
- return TRUE;
|
||||
-}
|
||||
-
|
||||
|
||||
/*======================================================================*/
|
||||
|
||||
@@ -835,32 +909,20 @@ static struct obj_symbol *arch_new_symbo
|
||||
static enum obj_reloc
|
||||
arch_apply_relocation(struct obj_file *f,
|
||||
struct obj_section *targsec,
|
||||
- /*struct obj_section *symsec,*/
|
||||
+ struct obj_section *symsec,
|
||||
struct obj_symbol *sym,
|
||||
ElfW(RelM) *rel, ElfW(Addr) v)
|
||||
{
|
||||
-#if defined(__arm__) || defined(__i386__) || defined(__mc68000__) \
|
||||
- || defined(__sh__) || defined(__s390__) || defined(__x86_64__) \
|
||||
- || defined(__powerpc__) || defined(__mips__)
|
||||
struct arch_file *ifile = (struct arch_file *) f;
|
||||
-#endif
|
||||
enum obj_reloc ret = obj_reloc_ok;
|
||||
ElfW(Addr) *loc = (ElfW(Addr) *) (targsec->contents + rel->r_offset);
|
||||
-#if defined(__arm__) || defined(__H8300H__) || defined(__H8300S__) \
|
||||
- || defined(__i386__) || defined(__mc68000__) || defined(__microblaze__) \
|
||||
- || defined(__mips__) || defined(__nios2__) || defined(__powerpc__) \
|
||||
- || defined(__s390__) || defined(__sh__) || defined(__x86_64__)
|
||||
ElfW(Addr) dot = targsec->header.sh_addr + rel->r_offset;
|
||||
-#endif
|
||||
#if defined(USE_GOT_ENTRIES) || defined(USE_PLT_ENTRIES)
|
||||
struct arch_symbol *isym = (struct arch_symbol *) sym;
|
||||
#endif
|
||||
-#if defined(__arm__) || defined(__i386__) || defined(__mc68000__) \
|
||||
- || defined(__sh__) || defined(__s390__)
|
||||
#if defined(USE_GOT_ENTRIES)
|
||||
ElfW(Addr) got = ifile->got ? ifile->got->header.sh_addr : 0;
|
||||
#endif
|
||||
-#endif
|
||||
#if defined(USE_PLT_ENTRIES)
|
||||
ElfW(Addr) plt = ifile->plt ? ifile->plt->header.sh_addr : 0;
|
||||
unsigned long *ip;
|
||||
@@ -954,7 +1016,6 @@ arch_apply_relocation(struct obj_file *f
|
||||
|
||||
case R_386_PLT32:
|
||||
case R_386_PC32:
|
||||
- case R_386_GOTOFF:
|
||||
*loc += v - dot;
|
||||
break;
|
||||
|
||||
@@ -973,6 +1034,9 @@ arch_apply_relocation(struct obj_file *f
|
||||
|
||||
case R_386_GOT32:
|
||||
goto bb_use_got;
|
||||
+
|
||||
+ case R_386_GOTOFF:
|
||||
+ *loc += v - got;
|
||||
break;
|
||||
|
||||
#elif defined(__microblaze__)
|
||||
@@ -1764,7 +1828,7 @@ static int arch_list_add(ElfW(RelM) *rel
|
||||
|
||||
#if defined(USE_SINGLE)
|
||||
|
||||
-static int arch_single_init(/*ElfW(RelM) *rel,*/ struct arch_single_entry *single,
|
||||
+static int arch_single_init(ElfW(RelM) *rel, struct arch_single_entry *single,
|
||||
int offset, int size)
|
||||
{
|
||||
if (single->allocated == 0) {
|
||||
@@ -1912,7 +1976,7 @@ static void arch_create_got(struct obj_f
|
||||
#if defined(USE_GOT_ENTRIES)
|
||||
if (got_allocate) {
|
||||
got_offset += arch_single_init(
|
||||
- /*rel,*/ &intsym->gotent,
|
||||
+ rel, &intsym->gotent,
|
||||
got_offset, GOT_ENTRY_SIZE);
|
||||
|
||||
got_needed = 1;
|
||||
@@ -1926,7 +1990,7 @@ static void arch_create_got(struct obj_f
|
||||
plt_offset, PLT_ENTRY_SIZE);
|
||||
#else
|
||||
plt_offset += arch_single_init(
|
||||
- /*rel,*/ &intsym->pltent,
|
||||
+ rel, &intsym->pltent,
|
||||
plt_offset, PLT_ENTRY_SIZE);
|
||||
#endif
|
||||
plt_needed = 1;
|
||||
@@ -1964,8 +2028,7 @@ static unsigned long obj_elf_hash_n(cons
|
||||
while (n > 0) {
|
||||
ch = *name++;
|
||||
h = (h << 4) + ch;
|
||||
- g = (h & 0xf0000000);
|
||||
- if (g != 0) {
|
||||
+ if ((g = (h & 0xf0000000)) != 0) {
|
||||
h ^= g >> 24;
|
||||
h &= ~g;
|
||||
}
|
||||
@@ -2044,7 +2107,7 @@ obj_add_symbol(struct obj_file *f, const
|
||||
int n_type = ELF_ST_TYPE(info);
|
||||
int n_binding = ELF_ST_BIND(info);
|
||||
|
||||
- for (sym = f->symtab[hash]; sym; sym = sym->next) {
|
||||
+ for (sym = f->symtab[hash]; sym; sym = sym->next)
|
||||
if (f->symbol_cmp(sym->name, name) == 0) {
|
||||
int o_secidx = sym->secidx;
|
||||
int o_info = sym->info;
|
||||
@@ -2103,14 +2166,14 @@ obj_add_symbol(struct obj_file *f, const
|
||||
return sym;
|
||||
}
|
||||
}
|
||||
- }
|
||||
|
||||
/* Completely new symbol. */
|
||||
sym = arch_new_symbol();
|
||||
sym->next = f->symtab[hash];
|
||||
f->symtab[hash] = sym;
|
||||
sym->ksymidx = -1;
|
||||
- if (ELF_ST_BIND(info) == STB_LOCAL && symidx != (unsigned long)(-1)) {
|
||||
+
|
||||
+ if (ELF_ST_BIND(info) == STB_LOCAL && symidx != -1) {
|
||||
if (symidx >= f->local_symtab_size)
|
||||
bb_error_msg("local symbol %s with index %ld exceeds local_symtab_size %ld",
|
||||
name, (long) symidx, (long) f->local_symtab_size);
|
||||
@@ -3234,7 +3297,7 @@ static int obj_relocate(struct obj_file
|
||||
|
||||
/* Do it! */
|
||||
switch (arch_apply_relocation
|
||||
- (f, targsec, /*symsec,*/ intsym, rel, value)
|
||||
+ (f, targsec, symsec, intsym, rel, value)
|
||||
) {
|
||||
case obj_reloc_ok:
|
||||
break;
|
||||
@@ -3313,11 +3376,11 @@ static int obj_create_image(struct obj_f
|
||||
|
||||
/*======================================================================*/
|
||||
|
||||
-static struct obj_file *obj_load(FILE *fp, int loadprogbits UNUSED_PARAM)
|
||||
+static struct obj_file *obj_load(FILE *fp, int loadprogbits)
|
||||
{
|
||||
struct obj_file *f;
|
||||
ElfW(Shdr) * section_headers;
|
||||
- size_t shnum, i;
|
||||
+ int shnum, i;
|
||||
char *shstrtab;
|
||||
|
||||
/* Read the file header. */
|
||||
@@ -3591,7 +3654,7 @@ static int obj_gpl_license(struct obj_fi
|
||||
while (ptr < endptr) {
|
||||
value = strchr(ptr, '=');
|
||||
if (value && strncmp(ptr, "license", value-ptr) == 0) {
|
||||
- unsigned i;
|
||||
+ int i;
|
||||
if (license)
|
||||
*license = value+1;
|
||||
for (i = 0; i < ARRAY_SIZE(gpl_licenses); ++i) {
|
||||
@@ -3695,9 +3758,6 @@ static void check_tainted_module(struct
|
||||
* start of some sections. this info is used by ksymoops to do better
|
||||
* debugging.
|
||||
*/
|
||||
-#if !ENABLE_FEATURE_INSMOD_VERSION_CHECKING
|
||||
-#define get_module_version(f, str) get_module_version(str)
|
||||
-#endif
|
||||
static int
|
||||
get_module_version(struct obj_file *f, char str[STRVERSIONLEN])
|
||||
{
|
||||
@@ -3730,8 +3790,7 @@ add_ksymoops_symbols(struct obj_file *f,
|
||||
struct obj_symbol *sym;
|
||||
char *name, *absolute_filename;
|
||||
char str[STRVERSIONLEN];
|
||||
- unsigned i;
|
||||
- int l, lm_name, lfilename, use_ksymtab, version;
|
||||
+ int i, l, lm_name, lfilename, use_ksymtab, version;
|
||||
struct stat statbuf;
|
||||
|
||||
/* WARNING: was using realpath, but replaced by readlink to stop using
|
||||
@@ -3922,145 +3981,57 @@ static void print_load_map(struct obj_fi
|
||||
void print_load_map(struct obj_file *f);
|
||||
#endif
|
||||
|
||||
-int insmod_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE;
|
||||
-int insmod_main(int argc, char **argv)
|
||||
+int insmod_main_24( int argc, char **argv)
|
||||
{
|
||||
char *opt_o, *arg1;
|
||||
- int len;
|
||||
int k_crcs;
|
||||
- char *tmp, *tmp1;
|
||||
unsigned long m_size;
|
||||
ElfW(Addr) m_addr;
|
||||
struct obj_file *f;
|
||||
- struct stat st;
|
||||
- char *m_name = NULL;
|
||||
- int exit_status = EXIT_FAILURE;
|
||||
+ char *tmp = NULL, *m_name = NULL;
|
||||
+ int ret = EINVAL;
|
||||
int m_has_modinfo;
|
||||
#if ENABLE_FEATURE_INSMOD_VERSION_CHECKING
|
||||
struct utsname uts_info;
|
||||
char m_strversion[STRVERSIONLEN];
|
||||
int m_version, m_crcs;
|
||||
#endif
|
||||
-#if ENABLE_FEATURE_CLEAN_UP
|
||||
FILE *fp = NULL;
|
||||
-#else
|
||||
- FILE *fp;
|
||||
-#endif
|
||||
- int k_version = 0;
|
||||
+ int k_version;
|
||||
struct utsname myuname;
|
||||
|
||||
+ /* check the kernel version */
|
||||
+ if ((uname(&myuname) != 0) || (myuname.release[0] != '2'))
|
||||
+ return EINVAL;
|
||||
+
|
||||
+ k_version = myuname.release[2] - '0';
|
||||
+ if (k_version > 4)
|
||||
+ return ENOTSUP;
|
||||
+
|
||||
/* Parse any options */
|
||||
getopt32(argv, OPTION_STR, &opt_o);
|
||||
arg1 = argv[optind];
|
||||
if (option_mask32 & OPT_o) { // -o /* name the output module */
|
||||
- free(m_name);
|
||||
m_name = xstrdup(opt_o);
|
||||
}
|
||||
|
||||
- if (arg1 == NULL) {
|
||||
+ if (arg1 == NULL)
|
||||
bb_show_usage();
|
||||
- }
|
||||
-
|
||||
- /* Grab the module name */
|
||||
- tmp1 = xstrdup(arg1);
|
||||
- tmp = basename(tmp1);
|
||||
- len = strlen(tmp);
|
||||
-
|
||||
- if (uname(&myuname) == 0) {
|
||||
- if (myuname.release[0] == '2') {
|
||||
- k_version = myuname.release[2] - '0';
|
||||
- }
|
||||
- }
|
||||
|
||||
-#if ENABLE_FEATURE_2_6_MODULES
|
||||
- if (k_version > 4 && len > 3 && tmp[len - 3] == '.'
|
||||
- && tmp[len - 2] == 'k' && tmp[len - 1] == 'o'
|
||||
- ) {
|
||||
- len -= 3;
|
||||
- tmp[len] = '\0';
|
||||
- } else
|
||||
-#endif
|
||||
- if (len > 2 && tmp[len - 2] == '.' && tmp[len - 1] == 'o') {
|
||||
- len -= 2;
|
||||
- tmp[len] = '\0';
|
||||
- }
|
||||
-
|
||||
-
|
||||
-#if ENABLE_FEATURE_2_6_MODULES
|
||||
- if (k_version > 4)
|
||||
- m_fullName = xasprintf("%s.ko", tmp);
|
||||
- else
|
||||
-#endif
|
||||
- m_fullName = xasprintf("%s.o", tmp);
|
||||
+ ret = find_module(arg1);
|
||||
+ if (ret)
|
||||
+ goto out;
|
||||
|
||||
if (!m_name) {
|
||||
- m_name = tmp;
|
||||
- } else {
|
||||
- free(tmp1);
|
||||
- tmp1 = NULL; /* flag for free(m_name) before exit() */
|
||||
- }
|
||||
-
|
||||
- /* Get a filedesc for the module. Check that we have a complete path */
|
||||
- if (stat(arg1, &st) < 0 || !S_ISREG(st.st_mode)
|
||||
- || (fp = fopen_for_read(arg1)) == NULL
|
||||
- ) {
|
||||
- /* Hmm. Could not open it. First search under /lib/modules/`uname -r`,
|
||||
- * but do not error out yet if we fail to find it... */
|
||||
- if (k_version) { /* uname succeedd */
|
||||
- char *module_dir;
|
||||
- char *tmdn;
|
||||
-
|
||||
- tmdn = concat_path_file(CONFIG_DEFAULT_MODULES_DIR, myuname.release);
|
||||
- /* Jump through hoops in case /lib/modules/`uname -r`
|
||||
- * is a symlink. We do not want recursive_action to
|
||||
- * follow symlinks, but we do want to follow the
|
||||
- * /lib/modules/`uname -r` dir, So resolve it ourselves
|
||||
- * if it is a link... */
|
||||
- module_dir = xmalloc_readlink(tmdn);
|
||||
- if (!module_dir)
|
||||
- module_dir = xstrdup(tmdn);
|
||||
- recursive_action(module_dir, ACTION_RECURSE,
|
||||
- check_module_name_match, NULL, m_fullName, 0);
|
||||
- free(module_dir);
|
||||
- free(tmdn);
|
||||
- }
|
||||
-
|
||||
- /* Check if we have found anything yet */
|
||||
- if (!m_filename || ((fp = fopen_for_read(m_filename)) == NULL)) {
|
||||
- int r;
|
||||
- char *module_dir;
|
||||
-
|
||||
- free(m_filename);
|
||||
- m_filename = NULL;
|
||||
- module_dir = xmalloc_readlink(CONFIG_DEFAULT_MODULES_DIR);
|
||||
- if (!module_dir)
|
||||
- module_dir = xstrdup(CONFIG_DEFAULT_MODULES_DIR);
|
||||
- /* No module found under /lib/modules/`uname -r`, this
|
||||
- * time cast the net a bit wider. Search /lib/modules/ */
|
||||
- r = recursive_action(module_dir, ACTION_RECURSE,
|
||||
- check_module_name_match, NULL, m_fullName, 0);
|
||||
- if (r)
|
||||
- bb_error_msg_and_die("%s: module not found", m_fullName);
|
||||
- free(module_dir);
|
||||
- if (m_filename == NULL
|
||||
- || ((fp = fopen_for_read(m_filename)) == NULL)
|
||||
- ) {
|
||||
- bb_error_msg_and_die("%s: module not found", m_fullName);
|
||||
- }
|
||||
+ tmp = xstrdup(arg1);
|
||||
+ m_name = basename(tmp);
|
||||
}
|
||||
- } else
|
||||
- m_filename = xstrdup(arg1);
|
||||
-
|
||||
- if (flag_verbose)
|
||||
- printf("Using %s\n", m_filename);
|
||||
|
||||
-#if ENABLE_FEATURE_2_6_MODULES
|
||||
- if (k_version > 4) {
|
||||
- argv[optind] = m_filename;
|
||||
- optind--;
|
||||
- return insmod_ng_main(argc - optind, argv + optind);
|
||||
+ fp = fopen_for_read(g_filename);
|
||||
+ if (!fp) {
|
||||
+ ret = errno;
|
||||
+ goto out;
|
||||
}
|
||||
-#endif
|
||||
|
||||
f = obj_load(fp, LOADBITS);
|
||||
|
||||
@@ -4087,7 +4058,7 @@ int insmod_main(int argc, char **argv)
|
||||
"\t%s was compiled for kernel version %s\n"
|
||||
"\twhile this kernel is version %s",
|
||||
flag_force_load ? "warning: " : "",
|
||||
- m_filename, m_strversion, uts_info.release);
|
||||
+ g_filename, m_strversion, uts_info.release);
|
||||
if (!flag_force_load)
|
||||
goto out;
|
||||
}
|
||||
@@ -4129,7 +4100,7 @@ int insmod_main(int argc, char **argv)
|
||||
hide_special_symbols(f);
|
||||
|
||||
#if ENABLE_FEATURE_INSMOD_KSYMOOPS_SYMBOLS
|
||||
- add_ksymoops_symbols(f, m_filename, m_name);
|
||||
+ add_ksymoops_symbols(f, g_filename, m_name);
|
||||
#endif /* FEATURE_INSMOD_KSYMOOPS_SYMBOLS */
|
||||
|
||||
new_create_module_ksymtab(f);
|
||||
@@ -4138,7 +4109,7 @@ int insmod_main(int argc, char **argv)
|
||||
m_size = obj_load_size(f);
|
||||
|
||||
m_addr = create_module(m_name, m_size);
|
||||
- if (m_addr == (ElfW(Addr))(-1)) switch (errno) {
|
||||
+ if (m_addr == -1) switch (errno) {
|
||||
case EEXIST:
|
||||
bb_error_msg_and_die("a module named %s already exists", m_name);
|
||||
case ENOMEM:
|
||||
@@ -4154,36 +4125,37 @@ int insmod_main(int argc, char **argv)
|
||||
* now we can load them directly into the kernel memory
|
||||
*/
|
||||
if (!obj_load_progbits(fp, f, (char*)m_addr)) {
|
||||
- delete_module(m_name, 0);
|
||||
+ delete_module(m_name);
|
||||
goto out;
|
||||
}
|
||||
#endif
|
||||
|
||||
if (!obj_relocate(f, m_addr)) {
|
||||
- delete_module(m_name, 0);
|
||||
+ delete_module(m_name);
|
||||
goto out;
|
||||
}
|
||||
|
||||
if (!new_init_module(m_name, f, m_size)) {
|
||||
- delete_module(m_name, 0);
|
||||
+ delete_module(m_name);
|
||||
goto out;
|
||||
}
|
||||
|
||||
if (flag_print_load_map)
|
||||
print_load_map(f);
|
||||
|
||||
- exit_status = EXIT_SUCCESS;
|
||||
+ ret = EXIT_SUCCESS;
|
||||
|
||||
out:
|
||||
#if ENABLE_FEATURE_CLEAN_UP
|
||||
if (fp)
|
||||
fclose(fp);
|
||||
- free(tmp1);
|
||||
- if (!tmp1)
|
||||
+ if (tmp)
|
||||
+ free(tmp);
|
||||
+ else if (m_name)
|
||||
free(m_name);
|
||||
- free(m_filename);
|
||||
+ free(g_filename);
|
||||
#endif
|
||||
- return exit_status;
|
||||
+ return ret;
|
||||
}
|
||||
|
||||
#endif /* ENABLE_FEATURE_2_4_MODULES */
|
||||
@@ -4195,15 +4167,8 @@ int insmod_main(int argc, char **argv)
|
||||
#if ENABLE_FEATURE_2_6_MODULES
|
||||
|
||||
#include <sys/mman.h>
|
||||
-
|
||||
-#if defined __UCLIBC__ && !ENABLE_FEATURE_2_4_MODULES
|
||||
-/* big time suckage. The old prototype above renders our nice fwd-decl wrong */
|
||||
-extern int init_module(void *module, unsigned long len, const char *options);
|
||||
-#else
|
||||
#include <asm/unistd.h>
|
||||
#include <sys/syscall.h>
|
||||
-#define init_module(mod, len, opts) syscall(__NR_init_module, mod, len, opts)
|
||||
-#endif
|
||||
|
||||
/* We use error numbers in a loose translation... */
|
||||
static const char *moderror(int err)
|
||||
@@ -4222,22 +4187,32 @@ static const char *moderror(int err)
|
||||
}
|
||||
}
|
||||
|
||||
-#if !ENABLE_FEATURE_2_4_MODULES
|
||||
-int insmod_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE;
|
||||
-int insmod_main(int argc UNUSED_PARAM, char **argv)
|
||||
-#else
|
||||
-static int insmod_ng_main(int argc UNUSED_PARAM, char **argv)
|
||||
-#endif
|
||||
+int insmod_main_26(int argc, char **argv)
|
||||
{
|
||||
- size_t len;
|
||||
+ char *filename, *options;
|
||||
+ struct utsname myuname;
|
||||
+ int k_version;
|
||||
int optlen;
|
||||
+ size_t len;
|
||||
void *map;
|
||||
- char *filename, *options;
|
||||
+ long ret = 0;
|
||||
+
|
||||
+ /* check the kernel version */
|
||||
+ if ((uname(&myuname) != 0) || (myuname.release[0] != '2'))
|
||||
+ return EINVAL;
|
||||
+
|
||||
+ k_version = myuname.release[2] - '0';
|
||||
+ if (k_version <= 4)
|
||||
+ return ENOTSUP;
|
||||
|
||||
filename = *++argv;
|
||||
int insmod_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE;
|
||||
int insmod_main(int argc UNUSED_PARAM, char **argv)
|
||||
@@ -25,9 +118,14 @@ int insmod_main(int argc UNUSED_PARAM, c
|
||||
if (!filename)
|
||||
bb_show_usage();
|
||||
|
||||
+ ret = find_module(filename);
|
||||
+ if (ret || (g_filename == NULL))
|
||||
+ goto done;
|
||||
- rc = bb_init_module(filename, parse_cmdline_module_options(argv));
|
||||
+ rc = find_module(filename);
|
||||
+ if (rc || (g_filename == NULL))
|
||||
+ goto done;
|
||||
+
|
||||
/* Rest is options */
|
||||
options = xzalloc(1);
|
||||
optlen = 0;
|
||||
@@ -4247,41 +4222,47 @@ static int insmod_ng_main(int argc UNUSE
|
||||
optlen += sprintf(options + optlen, (strchr(*argv,' ') ? "\"%s\" " : "%s "), *argv);
|
||||
}
|
||||
|
||||
-#if 0
|
||||
- /* Any special reason why mmap? It isn't performance critical. -vda */
|
||||
- /* Yes, xmalloc'ing can use *alot* of RAM. Don't forget that there are
|
||||
- * modules out there that are half a megabyte! mmap()ing is way nicer
|
||||
- * for small mem boxes, i guess. */
|
||||
- /* But after load, these modules will take up that 0.5mb in kernel
|
||||
- * anyway. Using malloc here causes only a transient spike to 1mb,
|
||||
- * after module is loaded, we go back to normal 0.5mb usage
|
||||
- * (in kernel). Also, mmap isn't magic - when we touch mapped data,
|
||||
- * we use memory. -vda */
|
||||
- int fd;
|
||||
- struct stat st;
|
||||
- unsigned long len;
|
||||
- fd = xopen(filename, O_RDONLY);
|
||||
- fstat(fd, &st);
|
||||
- len = st.st_size;
|
||||
- map = mmap(NULL, len, PROT_READ, MAP_PRIVATE, fd, 0);
|
||||
- if (map == MAP_FAILED) {
|
||||
- bb_perror_msg_and_die("cannot mmap '%s'", filename);
|
||||
- }
|
||||
+ rc = bb_init_module(g_filename, parse_cmdline_module_options(argv));
|
||||
if (rc)
|
||||
bb_error_msg("cannot insert '%s': %s", filename, moderror(rc));
|
||||
-
|
||||
- /* map == NULL on Blackfin, probably on other MMU-less systems too. Workaround. */
|
||||
- if (map == NULL) {
|
||||
- map = xmalloc(len);
|
||||
- xread(fd, map, len);
|
||||
- }
|
||||
-#else
|
||||
len = MAXINT(ssize_t);
|
||||
- map = xmalloc_xopen_read_close(filename, &len);
|
||||
-#endif
|
||||
+ map = xmalloc_open_read_close(g_filename, &len);
|
||||
+ ret = syscall(__NR_init_module, map, len, options);
|
||||
+ if (ret != 0) {
|
||||
+ bb_perror_msg_and_die("cannot insert '%s': %s (%li)",
|
||||
+ g_filename, moderror(errno), ret);
|
||||
+ }
|
||||
+ free (g_filename);
|
||||
+done:
|
||||
+ if (g_filename && (g_filename != filename))
|
||||
+ free(g_filename);
|
||||
|
||||
- if (init_module(map, len, options) != 0)
|
||||
- bb_error_msg_and_die("cannot insert '%s': %s",
|
||||
- filename, moderror(errno));
|
||||
- return 0;
|
||||
+ return ret;
|
||||
return rc;
|
||||
}
|
||||
|
||||
#endif
|
||||
+
|
||||
+int insmod_main(int argc, char **argv)
|
||||
+{
|
||||
+ int ret;
|
||||
+
|
||||
+ g_filename = NULL;
|
||||
+#if ENABLE_FEATURE_2_6_MODULES
|
||||
+ ret = insmod_main_26(argc, argv);
|
||||
+ if (ret != ENOTSUP)
|
||||
+ goto done;
|
||||
+#endif
|
||||
+
|
||||
+#if ENABLE_FEATURE_2_4_MODULES
|
||||
+ ret = insmod_main_24(argc, argv);
|
||||
+ if (ret != ENOTSUP)
|
||||
+ goto done;
|
||||
+#endif
|
||||
+
|
||||
+ fprintf(stderr, "Error: Kernel version not supported\n");
|
||||
+ return 1;
|
||||
+
|
||||
+done:
|
||||
+ if (ret) {
|
||||
+ errno = ret;
|
||||
+ bb_perror_msg("Loading module failed");
|
||||
+ return ret;
|
||||
+ } else
|
||||
+ return 0;
|
||||
+}
|
||||
|
@ -1,22 +0,0 @@
|
||||
--- a/editors/vi.c
|
||||
+++ b/editors/vi.c
|
||||
@@ -3317,7 +3317,7 @@ static void do_cmd(char c)
|
||||
buf[1] = '\0';
|
||||
q = get_input_line(buf); // get input line- use "status line"
|
||||
if (q[0] && !q[1]) {
|
||||
- if (last_search_pattern[0])
|
||||
+ if (last_search_pattern)
|
||||
last_search_pattern[0] = c;
|
||||
goto dc3; // if no pat re-use old pat
|
||||
}
|
||||
@@ -3333,6 +3333,10 @@ static void do_cmd(char c)
|
||||
if (cmdcnt-- > 1) {
|
||||
do_cmd(c);
|
||||
} // repeat cnt
|
||||
+ if (last_search_pattern == 0) {
|
||||
+ msg = "No previous regular expression";
|
||||
+ goto dc2;
|
||||
+ }
|
||||
dir = BACK; // assume BACKWARD search
|
||||
p = dot - 1;
|
||||
if (last_search_pattern[0] == '?') {
|
@ -15,7 +15,7 @@
|
||||
} func;
|
||||
|
||||
/* I/O stream */
|
||||
@@ -1400,7 +1405,8 @@ static void parse_program(char *p)
|
||||
@@ -1423,7 +1428,8 @@ static void parse_program(char *p)
|
||||
next_token(TC_FUNCTION);
|
||||
g_pos++;
|
||||
f = newfunc(t_string);
|
||||
@ -25,7 +25,7 @@
|
||||
f->nargs = 0;
|
||||
while (next_token(TC_VARIABLE | TC_SEQTERM) & TC_VARIABLE) {
|
||||
v = findvar(ahash, t_string);
|
||||
@@ -1409,7 +1415,7 @@ static void parse_program(char *p)
|
||||
@@ -1432,7 +1438,7 @@ static void parse_program(char *p)
|
||||
if (next_token(TC_COMMA | TC_SEQTERM) & TC_SEQTERM)
|
||||
break;
|
||||
}
|
||||
@ -34,7 +34,7 @@
|
||||
chain_group();
|
||||
clear_array(ahash);
|
||||
|
||||
@@ -2374,7 +2380,8 @@ static var *evaluate(node *op, var *res)
|
||||
@@ -2397,7 +2403,8 @@ static var *evaluate(node *op, var *res)
|
||||
break;
|
||||
|
||||
case XC( OC_FUNC ):
|
||||
@ -44,7 +44,7 @@
|
||||
syntax_error(EMSG_UNDEF_FUNC);
|
||||
|
||||
X.v = R.v = nvalloc(op->r.f->nargs+1);
|
||||
@@ -2391,7 +2398,10 @@ static var *evaluate(node *op, var *res)
|
||||
@@ -2414,7 +2421,10 @@ static var *evaluate(node *op, var *res)
|
||||
fnargs = X.v;
|
||||
|
||||
L.s = g_progname;
|
||||
@ -56,7 +56,7 @@
|
||||
g_progname = L.s;
|
||||
|
||||
nvfree(fnargs);
|
||||
@@ -2754,6 +2764,143 @@ static rstream *next_input_file(void)
|
||||
@@ -2777,6 +2787,143 @@ static rstream *next_input_file(void)
|
||||
#undef files_happen
|
||||
}
|
||||
|
||||
@ -200,7 +200,7 @@
|
||||
int awk_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE;
|
||||
int awk_main(int argc, char **argv)
|
||||
{
|
||||
@@ -2819,6 +2966,9 @@ int awk_main(int argc, char **argv)
|
||||
@@ -2842,6 +2989,9 @@ int awk_main(int argc, char **argv)
|
||||
*s1 = '=';
|
||||
}
|
||||
}
|
||||
|
49
package/busybox/patches/803-id_getgrouplist.patch
Normal file
49
package/busybox/patches/803-id_getgrouplist.patch
Normal file
@ -0,0 +1,49 @@
|
||||
This patch disable supplementary groups handling in id with uClibc versions
|
||||
prior to v0.9.30, which are lacking the 'getgrouplist' function.
|
||||
|
||||
Signed-off-by: Nicolas Thill <nico@openwrt.org>
|
||||
|
||||
--- a/coreutils/id.c
|
||||
+++ b/coreutils/id.c
|
||||
@@ -17,10 +17,12 @@
|
||||
|
||||
#include "libbb.h"
|
||||
|
||||
+#define HAVE_GETGROUPLIST 1
|
||||
+
|
||||
#if !ENABLE_USE_BB_PWD_GRP
|
||||
#if defined(__UCLIBC_MAJOR__) && (__UCLIBC_MAJOR__ == 0)
|
||||
#if (__UCLIBC_MINOR__ < 9) || (__UCLIBC_MINOR__ == 9 && __UCLIBC_SUBLEVEL__ < 30)
|
||||
-#error "Sorry, you need at least uClibc version 0.9.30 for id applet to build"
|
||||
+#undef HAVE_GETGROUPLIST
|
||||
#endif
|
||||
#endif
|
||||
#endif
|
||||
@@ -86,7 +88,11 @@ static int get_groups(const char *userna
|
||||
/* If the user is a member of more than
|
||||
* *n groups, then -1 is returned. Otherwise >= 0.
|
||||
* (and no defined way of detecting errors?!) */
|
||||
+#if HAVE_GETGROUPLIST
|
||||
m = getgrouplist(username, rgid, groups, n);
|
||||
+#else
|
||||
+ *n = -1;
|
||||
+#endif
|
||||
/* I guess *n < 0 might indicate error. Anyway,
|
||||
* malloc'ing -1 bytes won't be good, so: */
|
||||
//if (*n < 0)
|
||||
@@ -160,6 +166,7 @@ int id_main(int argc UNUSED_PARAM, char
|
||||
if (egid != rgid)
|
||||
status |= print_group(egid, " ");
|
||||
}
|
||||
+#if HAVE_GETGROUPLIST
|
||||
/* We are supplying largish buffer, trying
|
||||
* to not run get_groups() twice. That might be slow
|
||||
* ("user database in remote SQL server" case) */
|
||||
@@ -187,6 +194,7 @@ int id_main(int argc UNUSED_PARAM, char
|
||||
}
|
||||
if (ENABLE_FEATURE_CLEAN_UP)
|
||||
free(groups);
|
||||
+#endif
|
||||
#if ENABLE_SELINUX
|
||||
if (is_selinux_enabled()) {
|
||||
if (getcon(&scontext) == 0)
|
@ -1,11 +0,0 @@
|
||||
--- a/modutils/lsmod.c
|
||||
+++ b/modutils/lsmod.c
|
||||
@@ -107,7 +107,7 @@
|
||||
continue;
|
||||
} else if (errno != ENOSPC)
|
||||
bb_perror_msg_and_die("module %s: QM_REFS", mn);
|
||||
- deps = xrealloc(deps, count);
|
||||
+ deps = xrealloc(deps, depsize = count);
|
||||
}
|
||||
printf("%-20s%8lu%4ld", mn, info.size, info.usecount);
|
||||
if (info.flags & NEW_MOD_DELETED)
|
Loading…
Reference in New Issue
Block a user