Commit Graph

68 Commits

Author SHA1 Message Date
Denis Vlasenko
06af216528 suppress warnings about easch <applet>_main() having
no preceding prototype
2007-02-03 17:28:39 +00:00
Denis Vlasenko
a597aaddfa s/extern inline/static ATTRIBUTE_ALWAYS_INLINE/g
xstrtou: disallow leading '+'
2006-12-16 23:48:13 +00:00
Denis Vlasenko
e1a0d486e4 message string changes, mostly for consistency, also -32 bytes in .rodata 2006-10-20 13:28:22 +00:00
Denis Vlasenko
67b23e6043 getopt_ulflags -> getopt32.
It is impossible to formulate sane ABI based on
size of ulong because it can be 32-bit or 64-bit.
Basically it means that you cannot portably use
more that 32 option chars in one call anyway...
Make it explicit.
2006-10-03 21:00:06 +00:00
Denis Vlasenko
ce97960a6e usage.h: remove ugly tricks. We have USE_FEATURE_xxx now.
Few bugs are now exposed...
2006-09-27 23:31:08 +00:00
Rob Landley
d921b2ecc0 Remove bb_ prefixes from xfuncs.c (and a few other places), consolidate
things like xasprintf() into xfuncs.c, remove xprint_file_by_name() (it only
had one user), clean up lots of #includes...  General cleanup pass.  What I've
been doing for the last couple days.

And it conflicts!  I've removed httpd.c from this checkin due to somebody else
touching that file.  It builds for me.  I have to catch a bus.  (Now you know
why I'm looking forward to Mercurial.)
2006-08-03 15:41:12 +00:00
Rob Landley
534374755d Cleaup read() and write() variants, plus a couple of new functions like
xlseek and fdlength() for the new mkswap.
2006-07-16 08:14:35 +00:00
"Robert P. J. Day"
801ab14013 Add one-line GPL boilerplate to numerous (but not all yet) source files. 2006-07-12 07:56:04 +00:00
Rob Landley
8bb50782a5 Change llist_add_* to take the address of the list rather than returning the new
head, and change all the callers.
2006-05-26 23:44:51 +00:00
Rob Landley
dfba741457 Robert P. Day removed 8 gazillion occurrences of "extern" on function
definitions.  (That should only be on prototypes.)
2006-03-06 20:47:33 +00:00
Tim Riker
c1ef7bdd8d just whitespace 2006-01-25 00:08:53 +00:00
"Vladimir N. Oleynik"
f704b27b5b - new bb_opt_complementally syntax, use [-:?] only - 'free' chars
- new bb_getopt_ulflags features: check max and min args, convert first argv to options special for ar and tar applets
- use bb_default_error_retval for env applet
2005-10-14 09:56:52 +00:00
"Vladimir N. Oleynik"
f1ab127077 Prepend '-' to the first argument if required, more const, indent 2005-10-12 08:34:27 +00:00
"Vladimir N. Oleynik"
064f04e7e2 - use complementally '!' to '?' - 'ask' is best 'free' char for this.
- more long opt compatibility, can set flag for long opt struct now
- more logic: check opt-depend requires and global requires, special for 'id' and 'start-stop-daemon' applets.
2005-10-11 14:38:01 +00:00
Rob Landley
b7128c6236 Cleanup patch by Bernhard Fischer, removing unnecessary includes of
getopt.h, whitespace changes, typos, etc.
2005-09-11 01:05:30 +00:00
"Vladimir N. Oleynik"
27421a1878 1) bb_opt_complementaly -> bb_opt_complementally
2) better support long options
3) new flag '!' for bb_opt_complementally: produce bb_show_usage() if BB_GETOPT_ERROR internally
2005-09-05 14:46:07 +00:00
Mike Frysinger
348e84c202 change the hardcoded error constant (0x80000000UL) to a nice flexible define (BB_GETOPT_ERROR) 2005-05-11 00:39:03 +00:00
Mike Frysinger
ae38d65e95 abort if user passes -r or if they dont pass anything 2005-05-09 21:51:41 +00:00
Eric Andersen
d952ee2e9e Make it more apparent that archive creation is not supported 2004-10-07 00:35:59 +00:00
Glenn L McGrath
c6992feee3 Update my email address, document some of my tasks in the AUTHORS file 2004-04-25 05:11:19 +00:00
Eric Andersen
c7bda1ce65 Remove trailing whitespace. Update copyright to include 2004. 2004-03-15 08:29:22 +00:00
Glenn L McGrath
930453bdcf Use bb_getopt_ulflags, saves some space, better argument checking.
Remove ar specific extraction code, always use common extraction code.
2004-01-04 10:28:22 +00:00
Glenn L McGrath
142abc18ce Fix a compile error when only using ar, patch by Paul van Gool 2003-12-05 02:51:21 +00:00
Glenn L McGrath
7ffe133864 As we no longer use function pointers for read in common archiving code
archive_xread can be replaced with bb_full_read, and archive_copy_file
with bb_copyfd*
bb_copyfd is split into two functions bb_copyfd_size and bb_copyfd_eof,
they share a common backend.
2003-11-21 22:24:57 +00:00
Manuel Novoa III
cad5364599 Major coreutils update. 2003-03-19 09:13:01 +00:00
Glenn L McGrath
66125c8065 Move add_to_list from libunarchive to libbb so it can be of more general use (eg ifupdown). Changed the name to llist_add_to as i plan on adding more llist_ functions as needed (e.g. llist_free). 2002-12-08 00:54:33 +00:00
Glenn L McGrath
237ae42fc9 Abstract read and seek in unarchiving code, convert bunzip to file descriptors, support tar -j 2002-11-03 14:05:15 +00:00
Glenn L McGrath
a47a3eada6 Fix simple define problem 2002-09-26 16:01:21 +00:00
Glenn L McGrath
7ca04f328e New common unarchive code. 2002-09-25 02:47:48 +00:00
Glenn L McGrath
ef0eab514d Recovering from my previous commit 2001-10-25 14:49:48 +00:00
Glenn L McGrath
4bef7b4186 unarchive function changed to support both exclude and include lists, applets that use unarchive changed to match. 2001-10-13 19:43:46 +00:00
Glenn L McGrath
a868ec89e8 Allow the unarchive() extract_list variable to be NULL, meaning extract all 2001-07-14 08:49:53 +00:00
Glenn L McGrath
c127008840 Allow unarchive to redirect stdout (tobe used by dpkg applet) 2001-07-11 17:32:14 +00:00
Glenn L McGrath
8f5b63edea cpio applet, and changes to associated code 2001-06-22 09:22:06 +00:00
Glenn L McGrath
eb1c94078f Reorganise unarchiving functions, more code re-use, only does single pass(no more linked lists), basis for supporting a cpio (and cheaper untar) applet, but cpio applet isnt included in this.
It effects ar, dpkg-deb applets only
2001-06-20 07:48:00 +00:00
Glenn L McGrath
9aff903603 Reorganise archive extraction code 2001-06-13 07:26:39 +00:00
Matt Kraai
59df6f7398 Change 'printf("%s\n", ...)' into 'puts(...)'. Noted and patched in hostname.c
by Larry Doolittle.
2001-05-16 14:21:09 +00:00
Glenn L McGrath
47fd219c95 Rename variable that shadows global 2001-04-12 16:37:13 +00:00
Glenn L McGrath
4949faf4b2 copy_file_chunk uses streams now. 2001-04-11 16:23:35 +00:00
Glenn L McGrath
9d53c8ab74 Move get_ar_headers to libbb, make dpkg_deb.c independent of ar.c 2001-04-11 01:37:03 +00:00
Glenn L McGrath
e5f3957665 Fix warning 2001-04-07 02:17:36 +00:00
Eric Andersen
83f173b61e A first pass at making D_FILE_OFFSET_BITS=64 work, from
Jari Ruusu <jari.ruusu@pp.inet.fi>
2001-04-05 23:07:25 +00:00
Eric Andersen
67991cf824 This patch, put together by Manuel Novoa III, is a merge of work
done by Evin Robertson (bug#1105) and work from Manuel to make
usage messages occupy less space and simplify how usage messages
are displayed.
2001-02-14 21:23:06 +00:00
Glenn L McGrath
728875f340 Consmetic changes 2001-02-11 03:15:57 +00:00
Matt Kraai
dd19c69904 Removed trailing \n from error_msg{,_and_die} messages. 2001-01-31 19:00:21 +00:00
Eric Andersen
ed3ef50c23 Fix header file usage -- there were many unnecessary header files included in
busybox.h which slowed compiles.  I left only what was needed and then fixed up
all the apps to include their own header files.  I also fixed naming for pwd.h
and grp.h functions.  Tested to compile and run with libc5, glibc, and uClibc.
 -Erik
2001-01-27 08:24:39 +00:00
Glenn L McGrath
7541e3a812 add dpkg-deb command 2001-01-02 23:41:50 +00:00
Glenn L McGrath
4f1b0124c7 Rewrite, fix a bug with multiple long filenames, simplify structure, remove cruft, make code conform closer to style guide, saves 350 Bytes. 2000-12-15 06:50:09 +00:00
Mark Whitley
f57c944e09 Changed names of functions in utility.c and all affected files, to make
compliant with the style guide. Everybody rebuild your tags file!
2000-12-07 19:56:48 +00:00
Mark Whitley
4758368505 Fixed the comments to match the code and renamed the function to a (hopefully)
more descriptive name, and as per the style guide.
2000-12-05 20:03:17 +00:00