busybox/archival
Denys Vlasenko 4f2ef4a836 ash: allow shell scripts to be embedded in the binary
To assist in the deployment of shell scripts it may be convenient
to embed them in the BusyBox binary.

'Embed scripts in the binary' takes any files in the directory
'embed', concatenates them with null separators, compresses them
and embeds them in the binary.

When scripts are embedded in the binary, scripts can be run as
'busybox SCRIPT [ARGS]' or by usual (sym)link mechanism.

embed/nologin is provided as an example.

function                                             old     new   delta
packed_scripts                                         -     123    +123
unpack_scripts                                         -      87     +87
ash_main                                            1103    1171     +68
run_applet_and_exit                                   78     128     +50
get_script_content                                     -      32     +32
script_names                                           -      10     +10
expmeta                                              663     659      -4
------------------------------------------------------------------------------
(add/remove: 4/0 grow/shrink: 2/1 up/down: 370/-4)            Total: 366 bytes

Signed-off-by: Ron Yorston <rmy@pobox.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2018-11-01 10:15:13 +01:00
..
libarchive ash: allow shell scripts to be embedded in the binary 2018-11-01 10:15:13 +01:00
ar.c regularize format of source file headers, no code changes 2017-09-18 16:28:43 +02:00
bbunzip_test2.sh add tests for gunzip 2007-10-05 15:27:03 +00:00
bbunzip_test3.sh add tests for gunzip 2007-10-05 15:27:03 +00:00
bbunzip_test.sh add tests for gunzip 2007-10-05 15:27:03 +00:00
bbunzip.c libarchive: move bbunpack constants to bb_archive.h 2018-02-01 09:13:14 +01:00
bzip2.c bzip2: expose tuning knob for faster/smaller code 2018-02-07 01:33:25 +01:00
Config.src restore documentation on the build config language 2018-06-06 15:16:48 +02:00
cpio.c cpio: if longopts are enabled, accept --null (synonym for -0) 2018-07-06 20:50:30 +02:00
dpkg_deb.c regularize format of source file headers, no code changes 2017-09-18 16:28:43 +02:00
dpkg.c regularize format of source file headers, no code changes 2017-09-18 16:28:43 +02:00
gzip.c gzip: unbreak FEATURE_GZIP_LEVELS, closes 11171 2018-07-24 21:12:58 +02:00
Kbuild.src cpio: implement -R/--owner 2015-10-16 17:24:46 +02:00
lzop.c lzop: remove method checks which are always true/false 2018-04-08 16:44:45 +02:00
rpm.c rpm,rpm2cpio: do not compile not-configurred parts of rpm.c 2017-08-22 15:33:04 +02:00
rpm.h *: make GNU licensing statement forms more regular 2010-08-16 20:14:46 +02:00
tar_symlink_attack tar: postpone creation of symlinks with "suspicious" targets. Closes 8411 2017-07-24 17:20:13 +02:00
tar.c tar: fix a thinko in prev commit - we need to copy to _unused_ fd 2018-08-04 21:06:02 +02:00
unzip.c unzip: use printable_string() for printing filenames 2018-09-30 16:56:56 +02:00