diff options
author | Kartik K. Agaram <vc@akkartik.com> | 2016-10-16 12:54:07 -0700 |
---|---|---|
committer | Kartik K. Agaram <vc@akkartik.com> | 2016-10-16 12:54:07 -0700 |
commit | 93569d9d32ae0c7a07da45be39a479e3a56e1907 (patch) | |
tree | 268d0b747b54f48d692470c260e4e615b78c2391 | |
parent | 50e24bd43b74b552efc924aa3583a76496700799 (diff) | |
download | mu-93569d9d32ae0c7a07da45be39a479e3a56e1907.tar.gz |
3509
-rwxr-xr-x | build | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/build b/build index 974866a3..e5164a78 100755 --- a/build +++ b/build @@ -18,7 +18,7 @@ export CFLAGS="$CFLAGS -Wall -Wextra -ftrapv -fno-strict-aliasing" # return 1 if $1 is older than _any_ of the remaining args older_than() { - target=$1 + local target=$1 shift if [ ! -e $target ] then @@ -26,6 +26,7 @@ older_than() { echo "updating $target" >&2 return 0 # success fi + local f for f in $* do if [ $f -nt $target ] @@ -99,7 +100,7 @@ older_than mu_bin mu.cc *_list cleave/cleave termbox/* && { } for f in mu_*.cc do - older_than `echo $f |sed 's/\.cc$/.o/'` $f && { + older_than `echo $f |sed 's/\.cc$/.o/'` $f header global_declarations_list && { $CXX $CFLAGS -c $f } done |