Commit Graph

288 Commits

Author SHA1 Message Date
Bernhard Reutner-Fischer
c96d37050f - update defconfig 2008-01-29 09:28:02 +00:00
Paul Fox
518d8dd979 eliminated CONFIG_FEATURE_EDITING_FANCY_KEYS. the size savings
was small, compared to the total size of the command-line editing
features, and it removed key bindings that most wouldn't consider
"fancy", like ^U, and 'l' and 'h' in vi mode, ^F and ^B in emacs
mode.
2008-01-18 20:41:24 +00:00
Bernhard Reutner-Fischer
ce34cccf28 - update defconfig 2008-01-13 15:33:13 +00:00
Bernhard Reutner-Fischer
481ce92bdf - add ipsvd 2008-01-11 20:52:45 +00:00
Denis Vlasenko
3f9c848576 trylink: instead of build error, disable --gc-sections if GLIBC && STATIC
nameif: glibc build fixlet
2007-12-28 17:04:42 +00:00
Denis Vlasenko
fcfb5c04bb defconfig: update
appletli.c: add vda's (C)
top: fixlet for incorrect display of "0"
Makefile: reduce stack size from 20k to 16k
2007-12-24 12:16:24 +00:00
Denis Vlasenko
94e3365b8f perror_nomsg: don't print extra colon
losetup: print name of loop device in error messages
2007-12-22 15:44:23 +00:00
Denis Vlasenko
ab801874f8 attack the biggest stack users:
-mkfs_minix_main [busybox_unstripped]:                  4288
-mkfs_minix_main [busybox_unstripped]:                  4276
-grave [busybox_unstripped]:                            4260
(bzip2 users too - not listed)

price we pay in code size increase:
mainSort                                            2458    2515     +57
grave                                               1005    1058     +53
sendMTFValues                                       2177    2195     +18
BZ2_blockSort                                        122     125      +3
mkfs_minix_main                                     3070    3022     -48
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 4/1 up/down: 131/-48)            Total: 83 bytes
2007-12-02 08:35:37 +00:00
Denis Vlasenko
1da0ad13fb update defconfig 2007-11-23 23:37:19 +00:00
Mike Frysinger
49d15890e0 make output a little more friendly 2007-11-18 06:42:56 +00:00
Mike Frysinger
e13bd362e3 merge from upstream for systems that dont integrate libintl into their C library:
commit aa1e5ef5c1d95e7ebf0821d9ba27debe43a87a22
Author: Sam Ravnborg <sam@ravnborg.org>
Date:   Sun Aug 12 23:15:44 2007 +0200

    kbuild: check if we can link gettext not just compile

    cygwin provides the header file but the lib file needs
    to be added manually. A generic fix is to check if
    we can compile and link a program that uses gettext()
    and if it fails fall back to NO_NLS.

    International users of cygwin may have to specify
    HOST_LOADLIBES := "-lintl" on the make command line.

    Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
2007-11-18 06:17:52 +00:00
Denis Vlasenko
130f559f4d trylink: accomodate older versions of ld 2007-11-13 17:36:12 +00:00
Denis Vlasenko
15cb4a4272 fix a problem with two different applet_name's 2007-10-11 10:06:26 +00:00
Denis Vlasenko
9b49a5ed85 add -fvisibility=hidden to CC flags, mark XXX_main functions
EXTERNALLY_VISIBLE. 5% size reduction of libbusybox.so
2007-10-11 10:05:36 +00:00
Denis Vlasenko
724d196c75 Move applets/applet.c into libbb, allows to get rid of --whole-archive
(smaller code). Tested in static and shared mode.
2007-10-10 14:41:07 +00:00
Denis Vlasenko
141750e388 trylink: s/strip/$STRIP/g 2007-10-10 10:05:35 +00:00
Denis Vlasenko
42e418292d trylink: trivial cleanup 2007-10-09 18:01:13 +00:00
Denis Vlasenko
01f3b2c91a trylink: reformat link flags for readability
trylink: add --sort-section alignment:
    text           data     bss     dec     hex filename
-   6557            428    3260   10245    2805 busybox
+   6555            428    3260   10243    2803 busybox
- 909621           1076   12108  922805   e14b5 libbusybox.so.1.8.0.svn
+ 908868           1050   12016  921934   e114e libbusybox.so.1.8.0.svn
2007-10-09 13:49:26 +00:00
Denis Vlasenko
d19b87ece4 trylink: remove useless redirects, add missing error checks 2007-10-09 13:08:02 +00:00
Denis Vlasenko
8d755adc1a trylink: trivial fixes 2007-10-09 10:15:41 +00:00
Denis Vlasenko
e9fd69c8e8 make "individual applets" build less noisy.
add *.tmp to list of files deleted by make mrproper.
2007-10-08 22:16:14 +00:00
Denis Vlasenko
642a52d65e make --help work for "individual applets" too. 2007-10-07 21:00:41 +00:00
Denis Vlasenko
d62fd84d4b libbusybox: move (possibly compressed) help stuff into libbusybox.
Makes individual binaries much smaller.
2007-10-07 20:46:34 +00:00
Denis Vlasenko
f545be083d reviving libbusybox, adding CONFIG_INDIVIDUAL part 4 2007-10-07 17:06:26 +00:00
Denis Vlasenko
def8898596 reviving libbusybox, adding CONFIG_INDIVIDUAL part 3 2007-10-07 17:06:01 +00:00
Denis Vlasenko
76a6b236a9 reviving libbusybox, adding CONFIG_INDIVIDUAL part 2 2007-10-07 17:05:42 +00:00
Denis Vlasenko
3240474c23 reviving libbusybox, adding CONFIG_INDIVIDUAL part 1 2007-10-07 17:05:22 +00:00
Denis Vlasenko
c9dc2ac578 make variables static 2007-09-27 10:08:02 +00:00
Denis Vlasenko
a619b85ef5 check-lxdialog.sh: no point in giving up, maybe -lcurses will work? 2007-09-26 18:18:59 +00:00
Bernhard Reutner-Fischer
3a252b8c12 - add microcom to defconfig 2007-09-22 21:13:17 +00:00
Denis Vlasenko
9862e6b056 trylink: reinstate accidentally deleted --verbose
trylink: remove commented-out parts
2007-09-03 11:28:14 +00:00
Bernhard Reutner-Fischer
d2bb2d3918 - Generally strip off -l that does not pull in a lib.
If l_list is non-empty then add the group flags.
2007-09-02 15:28:30 +00:00
Bernhard Reutner-Fischer
8d91c13df5 - fix bug where we linked again -lm even though it is not needed.
For BBOX_LIB_LIST="crypt m" trylink ... with just applet true, we pulled in
  libm because in this case we tried to use invalid flags (plain "-l" without
  a lib) which of course failed, thus the script thought that -lm was needed.

  The fix is not to pass "-l" without a lib if we are about to check if any
  or the last remaining lib is really needed.
2007-09-02 14:51:54 +00:00
Denis Vlasenko
f87f495e65 Update defconfig; fix comments 2007-08-24 10:27:41 +00:00
Denis Vlasenko
028f2d651c build system: stop moaning about unset integer CONFIGs. 2007-08-23 14:11:30 +00:00
Denis Vlasenko
18f2a6bc5e s/communal/common/ part 2 2007-08-21 10:54:59 +00:00
Denis Vlasenko
f7d9e84bc5 s/communal/common/ 2007-08-21 10:54:34 +00:00
Denis Vlasenko
0372f0f199 httpd: extend -p PORT to -p [IP[v6]:]PORT
httpd: comment out strange code which "closes connection properly"
(isnt exit(0) good enough?)

handle_incoming_and_exit                               -    2246   +2246
httpd_main                                          1116    1141     +25
getLine                                               75      77      +2
packed_usage                                       22827   22811     -16
parse_conf                                          1303    1284     -19
shutdown                                              32       -     -32
handleIncoming                                      2578       -   -2578
------------------------------------------------------------------------------
(add/remove: 1/2 grow/shrink: 2/2 up/down: 2273/-2645)       Total: -372 bytes
   text    data     bss     dec     hex filename
 774704    1058   11092  786854   c01a6 busybox_old
 774335    1058   11092  786485   c0035 busybox_unstripped
2007-08-14 16:50:01 +00:00
Denis Vlasenko
dbe6e66d6a trylink: automatically use custom link script if user provides one
vinfo_msg: one user (info_msg), incorporate in it
*: style fixes
2007-08-14 16:43:01 +00:00
Denis Vlasenko
3952f20c24 expand, unexpand: new applets from Tito <farmatito@tiscali.it> 2007-08-13 14:10:24 +00:00
Denis Vlasenko
6ca409e0e4 trylink: produce even more info about final link stage
trylink: explain how to modify link and drastically decrease amount
  of padding (unfortunately, needs hand editing ATM).
*: add ALIGN1 / ALIGN2 to global strings and arrays of bytes and shorts

size saving: 0.5k
2007-08-12 20:58:27 +00:00
Denis Vlasenko
eea72123a3 patch: fix -p -1 handling
checkstack.pl: add blackfin (by Alex Landau <landau_alex@yahoo.com>)
2007-08-06 13:34:10 +00:00
Denis Vlasenko
73f21e9cb3 trylink: s/&& exit 1/|| exit 1/ (spotted by Alex Landau <landau_alex@yahoo.com>) 2007-08-06 12:18:01 +00:00
Denis Vlasenko
8274e06677 sed: fix 'q' command handling ("Nguyen Thai Ngoc Duy" <pclouds@gmail.com>)
add testsuite entry for it. Fix applet order checker. Fix cmp yelling.
trylink: fix error file and map file generation
applets: fix applet order
2007-08-06 03:41:08 +00:00
Denis Vlasenko
557fb713e0 chpasswd: fixes and code shrink
update_passwd                                        732     734      +2
chpasswd_main                                        318     292     -26
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 1/1 up/down: 2/-26)             Total: -24 bytes
   text    data     bss     dec     hex filename
 781564    1168   11900  794632   c2008 busybox_old
 781548    1168   11900  794616   c1ff8 busybox_unstripped
2007-07-21 13:25:28 +00:00
Denis Vlasenko
21d1014b5b chpasswd: new applet by Alexander Shishkin <virtuoso@slind.org> 2007-07-20 21:28:41 +00:00
Denis Vlasenko
2a86a61c27 ifup/ifdown: make location of ifstate configurable 2007-07-19 21:49:30 +00:00
Denis Vlasenko
150d2fa114 Modify method of linking against libs. Now we fisrt try all
specified libs, and if it succeeds, we try to remove them
one-by-one. If link succeeds, then library is thrown out.
Should solve the problem with SELinux linking in libsepol
even when not needed.
2007-07-17 20:39:27 +00:00
Denis Vlasenko
fb79a2e2cf xioctl and friends by Tito <farmatito@tiscali.it>
function                                             old     new   delta
do_iptunnel                                          203     977    +774
process_dev                                         5328    5494    +166
ioctl_or_perror                                        -      54     +54
ioctl_or_perror_and_die                                -      51     +51
ioctl_alt_func                                         -      49     +49
bb_ioctl_or_warn                                       -      47     +47
do_add_ioctl                                         102     145     +43
bb_xioctl                                              -      39     +39
print_value_on_off                                     -      31     +31
get_lcm                                              105     123     +18
arp_main                                            2155    2167     +12
..................
zcip_main                                           1576    1566     -10
setlogcons_main                                       92      82     -10
dumpkmap_main                                        263     253     -10
do_get_ioctl                                          85      75     -10
setkeycodes_main                                     165     154     -11
write_table                                          244     232     -12
vconfig_main                                         318     306     -12
do_del_ioctl                                          93      81     -12
set_address                                           75      62     -13
maybe_set_utc                                         30      16     -14
loadfont_main                                        495     479     -16
slattach_main                                        712     695     -17
do_loadfont                                          191     174     -17
do_iplink                                           1155    1136     -19
getty_main                                          2583    2562     -21
fbset_main                                          2058    2035     -23
do_time                                              588     565     -23
xioctl                                                25       -     -25
read_rtc                                             186     160     -26
parse_conf                                          1299    1270     -29
udhcp_read_interface                                 269     239     -30
bb_ioctl                                              45       -     -45
bb_ioctl_alt                                          70       -     -70
bb_ioctl_on_off                                       78       -     -78
.rodata                                           129370  129018    -352
do_show                                              799       -    -799
------------------------------------------------------------------------------
(add/remove: 6/5 grow/shrink: 13/49 up/down: 1316/-1864)     Total: -548 bytes
   text	   data	    bss	    dec	    hex	filename
 675352	   2740	  13968	 692060	  a8f5c	busybox_old
 674804	   2740	  13968	 691512	  a8d38	busybox_unstripped
2007-07-14 22:07:14 +00:00
Bernhard Reutner-Fischer
1399282b47 - need to pass the PATH down to the gcc-version check to be able to find the correct cc.
Fixes make PATH="$CROSS_BIN:$PATH" CROSS_COMPILE=foo- like invocations that previously failed to resolve since the information about the path set by the user was lost.
2007-06-25 10:41:01 +00:00
Bernhard Reutner-Fischer
118b81df76 - handy to have the cross_compile block here, too 2007-06-22 17:39:21 +00:00
Denis Vlasenko
d67a606489 build system: remove kernel .config locations (spotted by walter harms <wharms@bfs.de>) 2007-06-21 12:57:29 +00:00
Denis Vlasenko
2d25491ed0 defconfig: update 2007-06-19 11:33:48 +00:00
Denis Vlasenko
d4fea900bd add script which measures stack consumption.
Current top users:

0x08052f52 uncompress []:                               393312
0x080c8a58 input_tab []:                                82104
0x08092d5b ifaddrlist []:                               32828
0x08056163 loadfont_main []:                            32796
0x0806e508 colon []:                                    16532
0x08056095 do_loadfont []:                              16400
0x0806da70 place_cursor []:                             16388
0x080792e8 login_main []:                               9176

393 kb of stack??? OMG...
2007-06-10 00:54:27 +00:00
Bernhard Reutner-Fischer
4b49512881 - update defconfig 2007-06-07 13:12:51 +00:00
Denis Vlasenko
74324c8666 Audit bb_common_bufsiz usage, add script which looks for misuse.
tr: stop using globals needlessly.
code: -103 bytes
2007-06-04 10:16:52 +00:00
Denis Vlasenko
4e5f82c76f find_stray_communal_vars: script which finds communal variables
resize: remove globals var
mdev: remove globals var
2007-06-03 22:30:22 +00:00
Denis Vlasenko
4b924f3a5c whitespace fixes 2007-05-30 00:29:55 +00:00
Bernhard Reutner-Fischer
64332bf857 - busybox.c was removed a while ago 2007-05-15 09:07:06 +00:00
Denis Vlasenko
be1a9d4237 deluser: add optional support for removing users from groups
(by Tito <farmatito@tiscali.it>)
2007-04-15 08:43:23 +00:00
Denis Vlasenko
87468857f6 style fixes 2007-04-13 23:22:00 +00:00
Denis Vlasenko
51742f4bb0 style fixes. No code changes 2007-04-12 00:32:05 +00:00
Denis Vlasenko
e4f2d064b0 rename: run_applet_by_name -> run_applet_and_exit 2007-04-11 17:03:19 +00:00
Denis Vlasenko
80d14beae9 Rename two config options:
FEATURE_SH_STANDALONE_SHELL => FEATURE_SH_STANDALONE
FEATURE_EXEC_PREFER_APPLETS => FEATURE_PREFER_APPLETS
Make SH_STANDALONE depend on PREFER_APPLETS.
getopt.c: more randomconfig-induced fixes
2007-04-10 23:03:30 +00:00
Denis Vlasenko
5694d5f8d2 adding small script, mostly for documentational purposes 2007-04-08 15:12:21 +00:00
Bernhard Reutner-Fischer
00c2c4868a - clean up addgroup, fix adding users to existing groups and make it optional (Tito) 2007-04-05 13:16:39 +00:00
Bernhard Reutner-Fischer
45aebfd32d - bail out if either file does not exist
Avoids filling my scrollback-buffer with superfluous information ;)
2007-04-05 12:27:12 +00:00
Bernhard Reutner-Fischer
febe3c4211 - sed -e "s/char[[:space:]]*\*[[:space:]]*argv\[\]/char **argv/g" 2007-04-04 20:52:03 +00:00
Bernhard Reutner-Fischer
3d43edb28c - update defconfig 2007-03-28 22:19:46 +00:00
Bernhard Reutner-Fischer
0a537a0c57 - move additional fancy options not mandated by SUSv3 into a FANCY option 2007-03-28 16:48:40 +00:00
Bernhard Reutner-Fischer
10f8f5f443 - rough prototype for split(1). TODO: Still needs some love since it's way too big..
text	   data	    bss	    dec	    hex	filename
    602	      4	      0	    606	    25e	coreutils/split.o
2007-03-25 21:50:18 +00:00
Denis Vlasenko
41e1dc3f8b make clean deletes .kernelrelease now
trylink deleted empty linker stderr on success
2007-03-18 21:45:21 +00:00
Mike Frysinger
7a96504d30 dont use obsolete function index() as pointed out by src.obsolete.funcs 2007-03-17 06:29:05 +00:00
Denis Vlasenko
84a9b8750e build system: produce link map. Rather useful when you
are wondering why your busybox is much bigger that you hoped for.
2007-03-15 23:44:10 +00:00
Denis Vlasenko
5df955fce2 Do not fail password check if shadow password does not exist -
fall back to ordinary one

Reduced usage of functions returning datain static buffers.
(mostly passwd/group/shadow related):

function                                             old     new   delta
correct_password                                     143     193     +50
sulogin_main                                         490     533     +43
adduser_main                                         732     774     +42
passwd_main                                         1875    1915     +40
addgroup_main                                        330     365     +35
bb_internal_getspnam                                  38       -     -38
bb_internal_fgetpwent                                 38       -     -38
bb_internal_fgetgrent                                 38       -     -38
static.resultbuf                                     168      88     -80
static.buffer                                       1872    1104    -768
------------------------------------------------------------------------------
(add/remove: 0/3 grow/shrink: 5/2 up/down: 210/-962)         Total: -752 bytes
2007-03-13 13:01:14 +00:00
Denis Vlasenko
ecea8f201e update defconfig 2007-03-11 12:29:25 +00:00
Bernhard Reutner-Fischer
71bc71a7dc - add chrt applet.
text    data     bss     dec     hex filename
    769       0       0     769     301 miscutils/chrt.o
and could use some further shrinkage
2007-03-09 16:56:38 +00:00
Bernhard Reutner-Fischer
e11b4a4705 - add selinux applets to the IMA workaround 2007-03-09 08:46:31 +00:00
Denis Vlasenko
018e085d44 stop using bash'isms ('function')
runtest: do not depend on busybox.links
2007-02-25 00:40:37 +00:00
Bernhard Reutner-Fischer
9a1c71a0f2 - check if the compiler supports -fwhole-program -- 4.0 does not 2007-02-12 12:57:38 +00:00
Denis Vlasenko
45854b5e3f mkconfigs: remove echo "..." contortion 2007-02-04 02:38:21 +00:00
Denis Vlasenko
a5c5ae03eb add TODO 2007-02-03 12:50:41 +00:00
Bernhard Reutner-Fischer
493691a4f5 - minor tweak 2007-02-02 16:11:24 +00:00
Denis Vlasenko
c562bb7487 disable -Wold-style-definition for gcc 3.x 2007-01-29 17:08:51 +00:00
Denis Vlasenko
e0eebc1ef3 Make -Werror configurable 2007-01-27 13:44:53 +00:00
Denis Vlasenko
b9a279ba94 Unify ping and ping6. ping has -4 and -6 which force
name resolution into IP or IPv6 only, otherwise
we take address family returned by host2sockaddr()
in lsa->sa.sa_family. IOW: "ping ::1" with do IPv6 ping,
"ping 127.0.0.1" will do IPv4 ping.
ping6 is aliased to "ping -6".
2007-01-24 23:53:22 +00:00
Bernhard Reutner-Fischer
1c747b32c7 - add hostcc-option checker 2007-01-23 11:44:14 +00:00
Bernhard Reutner-Fischer
b5bb40f088 - add an unsupported makefile for IMA compiles
Nice for catching eventual breakage early on..
2007-01-23 01:29:04 +00:00
Denis Vlasenko
5de9e9ce0b clean up commented out old code 2007-01-22 22:46:04 +00:00
Denis Vlasenko
3c99a59915 remove obsolete FEATURE_WGET_IP6_LITERAL 2007-01-22 09:14:02 +00:00
Denis Vlasenko
d8760a705c defconfig: refresh 2007-01-22 09:12:15 +00:00
Denis Vlasenko
38f6319421 cmdedit is not a 'command' editing anymore, it's just editing (generic),
so rename stuff accordingly.
2007-01-22 09:03:07 +00:00
Denis Vlasenko
00cdbd8fc2 Introduce FEATURE_EDITING_FANCY_KEYS, so that user can disable
less-known keys (e.g. Ctrl-B/E/F)
2007-01-21 19:21:21 +00:00
Denis Vlasenko
2f0c0d0b88 Introduce FEATURE_EXEC_PREFER_APPLETS = "re-execute our own
executable if we asked to exec someting with argv[0] == known_applet"
Use it in init. Also respect PATH in init, remove explicit "/sbin" etc
from exec. Patch by Gabriel L. Somlo <somlo@cmu.edu>
2007-01-21 00:41:04 +00:00
Denis Vlasenko
91f20ab510 fixes for amd64 compilation 2007-01-20 01:47:44 +00:00
Bernhard Reutner-Fischer
9e8df9354a - replace some occurances of "kernel" with busybox 2007-01-17 19:36:01 +00:00
Denis Vlasenko
150f402b36 whitespace fixes (leading spaces to tab) 2007-01-13 21:06:21 +00:00
Denis Vlasenko
6536a9b583 next part of ipv6-ization is here: wget & httpd 2007-01-12 10:35:23 +00:00
Denis Vlasenko
f7996f3b70 Trailing whitespace removal over entire tree 2007-01-11 17:20:00 +00:00
Bernhard Reutner-Fischer
f0b71c19ae - add arp to defconfig 2007-01-07 12:18:59 +00:00