diff options
author | Rob Landley <rob@landley.net> | 2015-02-07 17:20:23 -0600 |
---|---|---|
committer | Rob Landley <rob@landley.net> | 2015-02-07 17:20:23 -0600 |
commit | 912b2be5e53f2656727beb3158c8d97ad6b1f6f2 (patch) | |
tree | 93479fe267f34c0c5ccb97a2ddf43ab1dd1a2494 /scripts/make.sh | |
parent | 5eb4475bab76e81fd0119332d761b185a35944a5 (diff) | |
download | toybox-912b2be5e53f2656727beb3158c8d97ad6b1f6f2.tar.gz |
Build standalone commands where "depends on" config entries need to be switched on.
Diffstat (limited to 'scripts/make.sh')
-rwxr-xr-x | scripts/make.sh | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/scripts/make.sh b/scripts/make.sh index b91576ee..207a0827 100755 --- a/scripts/make.sh +++ b/scripts/make.sh @@ -56,7 +56,10 @@ fi [ ! -z "$V" ] && echo "Which C files to build..." # Extract a list of toys/*/*.c files to compile from the data in $KCONFIG_CONFIG -TOYFILES="$(egrep -l "TOY[(]($(sed -n 's/^CONFIG_\([^=]*\)=.*/\1/p' "$KCONFIG_CONFIG" | xargs | tr ' [A-Z]' '|[a-z]'))[ ,]" toys/*/*.c)" +# (First command names, then filenames with relevant {NEW,OLD}TOY() macro.) + +TOYFILES="$(sed -n 's/^CONFIG_\([^=]*\)=.*/\1/p' "$KCONFIG_CONFIG" | xargs | tr ' [A-Z]' '|[a-z]')" +TOYFILES="$(egrep -l "TOY[(]($TOYFILES)[ ,]" toys/*/*.c)" BUILD="$(echo ${CROSS_COMPILE}${CC} $CFLAGS -I . $OPTIMIZE)" FILES="$(echo lib/*.c main.c $TOYFILES)" |