Mercurial > hg > toybox
diff Makefile @ 133:a459c6b39645 0.0.3
Fix makefile to defconfig properly, and leak in a bit of the new test
infrastructure so I don't have to revert it to check this in. :)
author | Rob Landley <rob@landley.net> |
---|---|
date | Mon, 18 Jun 2007 01:09:00 -0400 |
parents | 81a324ef9167 |
children | fb0745eec453 |
line wrap: on
line diff
--- a/Makefile Mon Jun 18 01:00:32 2007 -0400 +++ b/Makefile Mon Jun 18 01:09:00 2007 -0400 @@ -17,8 +17,8 @@ include kconfig/Makefile # defconfig is the "maximum sane config"; allyesconfig minus debugging and such. -defconfig: allyesconfig - @sed -i -r -e "s/^(CONFIG_TOYBOX_(DEBUG|FREE))=.*/# \1 is not set/" .config +#defconfig: allyesconfig +# @sed -i -r -e "s/^(CONFIG_TOYBOX_(DEBUG|FREE))=.*/# \1 is not set/" .config .config: Config.in toys/Config.in @@ -41,13 +41,10 @@ bloatcheck: toybox_old toybox_unstripped @scripts/bloat-o-meter toybox_old toybox_unstripped -# Get list of toys/*.c files from .config - -toysfiles = $(shell sed -nre 's/^CONFIG_(.*)=y/\1/;t skip;b;:skip;s/_.*//;p' .config | sort -u | tr A-Z a-z | grep -v '^toybox$$' | sed 's@\(.*\)@toys/\1.c@') +# Get list of .c files to compile, including toys/*.c files from .config +toyfiles = main.c lib/*.c \ + $(shell scripts/cfg2files.sh < .config | sed 's@\(.*\)@toys/\1.c@') -# Compile toybox from source - -toyfiles = main.c lib/*.c $(toysfiles) toybox_unstripped: gen_config.h $(toyfiles) toys/toylist.h lib/*.h toys.h $(CC) $(CCFLAGS) -I . $(toyfiles) -o toybox_unstripped \ -ffunction-sections -fdata-sections -Wl,--gc-sections @@ -69,6 +66,11 @@ distclean: clean rm -f .config* +test: tests + +tests: + scripts/testall.sh + help:: @echo ' baseline - Create busybox_old for use by bloatcheck.' @echo ' bloatcheck - Report size differences between old and current versions'