aboutsummaryrefslogtreecommitdiff
path: root/scripts/make.sh
AgeCommit message (Collapse)Author
2014-09-11Create a generated/build.sh with a single compiler command line to rebuild ↵Rob Landley
the toybox_unstripped binary using the existing generated/*.h files. This way we can snapshot the generated/*.{h,sh} from a defconfig build into a "shipped" directory or something, and then people can maybe build on crazy crippled environments like pcbsd that haven't got gmake and put bash under /usr/local so none of the #!/scripts can find it. This solves at least part of the "toybox can build with itself but you need to build toybox first to have the tools to run the build scripts" problem. Next up: work out the minimal config to provide the build tools needed to run an actual build. (This should, eventually, include a "make" command if freebsd's kernel is going to refuse to build with netbsd's "make" and we don't just write off the whole thing as crazy. But it probably shouldn't include commands that #include <linux/*.h> if we are trying to make that work.)
2014-09-11Oops, unbreak make.sh.Rob Landley
Clearing out old .o files needs -r now that generated/obj has its own subdirectory. (Works if you make clean between, but shouldn't need it.)
2014-09-09Make tweaks: collate generated/*.o files into their own subdirectory, add ↵Rob Landley
PIPEFAIL for better error reporting, and simpler regex to select toys/*/*.c list based on NEWTOY/OLDTOY macros.
2014-09-04Don't hang for $CPUS=1.Rob Landley
echo prints a newline if it has nothing to print, so wc -l always returns at least 1. Fix: echo -n
2014-08-31More parallel build tweaks.Rob Landley
echo "$PENDING" needs the quotes to avoid gluing the lines together, which prevents wc -l or head -n +2 from working right.
2014-08-30Old compilers complain about linker options passed with -c, so split out ↵Rob Landley
$LDOPTIMIZE.
2014-08-30Another fix from Johan Bergstr?m, using the gnu/dammit version of sort on ↵Rob Landley
the host can be screwed up by more than one environment variable.
2014-08-24Fix parallel make not always catching errors before link time.Rob Landley
jobs -p removes finished jobs from the list after reporting them once, so we need to record the output and remove duplicates ourselves.
2014-08-09Parallelize the build. (set CPUS=1 to force single processor build, or ↵Rob Landley
another number to override processor count autodetect.)
2014-06-09host needs -lresolvRob Landley
2014-05-24Pass the same $CFLAGS to the library probe as the final build, to work with ↵Rob Landley
broken build environments that provide different libraries for --static and dynamic builds.
2014-02-28Fix header file generation to not be confused by empty (but non-NULL) option ↵Rob Landley
string. You shouldn't use "" as an option string because a NULL allows toy_init() to avoid calling the option parsing logic entirely, which lets it drop out when nothing's using it (ala scripts/single.sh builds). That said, init.c is currently using a "" option string and a USE_ macro taking advantage of string concatenation may require a "" option config, so...
2014-02-23CLEANUP transitions require all the generated/flags.h stanzas always be ↵Rob Landley
present (even for commands disabled in the config) to avoid undefined symbol errors referencing FLAG_ macros.
2014-02-04Use right config for single builds.Rob Landley
2014-01-03Replace python help converter with C implementation.Rob Landley
2013-12-28Cosmetic tweak.Rob Landley
2013-12-19Older python spit --version to stdout, 2.7 does it to stderr. Of course.Rob Landley
2013-12-19Regression test against Ancient Build Environment (Ubuntu 8.04), fixup bit-rot.Rob Landley
2013-10-23Don't use $CC without $CROSS_COMPILE because $HOSTCC could be something else ↵Rob Landley
entirely.
2013-10-03Switch flag generation from shell to C.Rob Landley
This should actually generate FLAG_longopt 0 #defines for disabled bare longopts (ala ls without --color). Put temporary executables under "generated" (including instlist for install).
2013-09-22Fix generated/oldtoys.h to contain option strings with USE() macros in them.Rob Landley
2013-09-05Allow shipped generated/help.h to still be used, until I rewrite the ↵Rob Landley
generator in C.
2013-08-30make.sh: Fix probing for python2.x and be verbose in error reportingElie De Brauwer
2013-09-01Implement ls --color=auto, suggested by Rich Felker.Rob Landley
2013-08-30Add scripts/single.sh to build individual non-multiplexed standalone commands.Rob Landley
Alas, you can't quite do this yet: make defconfig make for i in $(./toybox) do echo $i PREFIX=singles/ scripts/single.sh $i || break done Because the OLDTOY() aliases for commands won't build without the base command. And I can't just skip them because chown/chmod or mv/cp aren't the same thing.
2013-08-12More grep cleanup, and make OPTSTR_command macros for use with OLDTOY()Rob Landley
2013-07-25Juhani Haverinen pointed out that python 3 doesn't work with config2help.py, ↵Rob Landley
so you python2 binary until finishing the C rewrite.
2013-07-25Don't make a FLAG_ macro for " ", it's a control character, doing so throws ↵Rob Landley
the indexes off. Reported by Ashwini Sharma.
2013-06-22Generate FLAG_longopt macros for --longopts with no corresponding short option.Rob Landley
2013-04-30generated/help.h depends on CONFIG_TOYBOX_HELPFelix Janda
2013-04-29The host sort on many distros behaves stupidly, and sorts stuff in non-ascii ↵Rob Landley
order by default. Make it stop.
2012-11-28Use the specified compiler for preprocessing.Rob Landley
2012-11-26Cleanup i18n support (#ifdefectomy, move global init to process launch). ↵Rob Landley
Teach make.sh to emit "#define FLAG_x 0" for options inside disabled USE macros so we can unconditionally refer to them.
2012-11-19Teach option parsing about [groups] of related options.Rob Landley
2012-10-08New build infrastructure to generate FLAG_ macros and TT alias, #define ↵Rob Landley
FOR_commandname before #including toys.h to trigger it. Rename DEFINE_GLOBALS() to just GLOBALS() (because I could never remember if it was DECLARE_GLOBALS). Convert existing commands to use new infrastructure, and replace optflag constants with FLAG_ macros where appropriate.
2012-09-08Add switch_root and fix infrastructure to understand name "switch_root".Rob Landley
2012-08-25Teach build to compare toys/*/*.c against .config symbol names instead of ↵Rob Landley
stopping at first _ when assembling list of files to build, and convert - to _. This lets us have commands like switch_root or nbd-client.
2012-08-25Move commands into "posix", "lsb", and "other" menus/directories.Rob Landley
2012-06-11Multiplexer needs stayroot flag for suid handling.0.3.0Rob Landley
2012-05-23Probe available libraries to link --as-needed, avoiding "unknown libarary" ↵Rob Landley
errors.
2012-04-24Adding initial version of login.cElie De Brauwer
2012-04-14Teach make.sh to create flag macros, but with the wrong names. Dunno how to ↵Rob Landley
make a translation macro or #ifdef guard to get the names right so they actually be _used_ yet...
2012-03-06Comment and whitespace tweaks.Rob Landley
2012-03-03Fix from Georgi Chorbadzhiyski to make cross compiling more robust.0.2.1Rob Landley
2012-02-17Add V=1 support to make.Rob Landley
2009-12-13The "strip" in gcc 4.4 doesn't set the executable bit on its output, despite ↵Rob Landley
what SUSv4 says it should do, so cope with buggy FSF tools.
2009-01-30Convert non-bool config values (such as int) into config.h entries.Rob Landley
2009-01-30Re-wordwrap and reorder the .config->config.h sed script. (No real changes, ↵Rob Landley
just one command/line in a clearer order.)
2008-11-15Add netcat server mode, -l, -L, and -t.Rob Landley
2008-05-12Sort was including the trailing comma and getting the order wrong.Rob Landley
(Specifically, it was comparing "sh," with "sha1sum," and putting sha1sum first in generated/newtoys.h so the binary search wasn't finding sha1sum. Alas, you can't feed separate beginning and ending delimiters to "sort -t". The fix is to copy the appropriate field out with sed, duplicate it at the start of the string where it's easy to compare, and then remove it again with a second sed after the sort.