X-Git-Url: https://git.librecmc.org/?a=blobdiff_plain;f=busybox.sh;h=22493bf5913da529abd92e95cf7c6bf179999e5d;hb=70d09ed1cf54ae20d38c5c56c5afb5994cc46f32;hp=e01b8816234800de25bca43ed78e619ad6fdc20d;hpb=caffb6eff0e33a80da630963f21346c21186da39;p=oweals%2Fbusybox.git diff --git a/busybox.sh b/busybox.sh index e01b88162..22493bf59 100755 --- a/busybox.sh +++ b/busybox.sh @@ -1,10 +1,12 @@ #!/bin/sh -# I added in the extra "ls" so only source files that -# actually exist will show up in the compile list. -ls -1 ` \ - gcc -E -dM Config.h | \ +RAW=` \ + gcc -E -dM ${1:-Config.h} | \ sed -n -e '/^.*BB_FEATURE.*$/d;s/^#define.*\/\1.c/gp;' \ | tr '[:upper:]' '[:lower:]' | sort -` 2>/dev/null | sed -e 's/\.c$/\.o/g' +` +cd ${2:-.} +# I added in the extra "ls" so only source files that +# actually exist will show up in the compile list. +ls -1 $RAW 2>/dev/null | sed -e 's/\.c$/\.o/g'