about summary refs log tree commit diff stats
path: root/build
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2016-10-06 17:13:04 -0700
committerKartik K. Agaram <vc@akkartik.com>2016-10-06 17:13:04 -0700
commitb4785580be3fd46f18e21ee8c92759d5481432ed (patch)
treee90d8c769e46c6afb204f2378a39ddcfe9ccc89a /build
parentd9ee2076d94a5eb8c502ff065295ac921fae40e2 (diff)
downloadmu-b4785580be3fd46f18e21ee8c92759d5481432ed.tar.gz
3450
Purge remaining `makefile`s, without breaking CI.
Diffstat (limited to 'build')
-rwxr-xr-xbuild8
1 files changed, 6 insertions, 2 deletions
diff --git a/build b/build
index 86f9fa5f..3b12d6eb 100755
--- a/build
+++ b/build
@@ -5,6 +5,10 @@ set -e  # stop immediately on error
 # (layers)   |        |              |             |
 #          tangle  cleave          $CXX          $CXX
 
+# can also be called with a layer to only build until
+#   $ ./build --until 050
+UNTIL_LAYER=${2:-zzz}
+
 test $CXX || export CXX=c++ 
 test $CC || export CC=cc
 test $CFLAGS || export CFLAGS="-g -O3"
@@ -62,7 +66,7 @@ noisy_cd tangle
   }
 noisy_cd ..
 
-LAYERS=$(./enumerate/enumerate --until zzz |grep -v '.mu$')
+LAYERS=$(./enumerate/enumerate --until $UNTIL_LAYER |grep -v '.mu$')
 older_than mu.cc $LAYERS enumerate/enumerate tangle/tangle || {
   ./tangle/tangle $LAYERS > mu.cc
 }
@@ -111,7 +115,7 @@ older_than mu_bin mu.cc *_list cleave/cleave || {
 
 ## [0-9]*.mu -> core.mu
 
-MU_LAYERS=$(./enumerate/enumerate --until zzz |grep '.mu$')
+MU_LAYERS=$(./enumerate/enumerate --until $UNTIL_LAYER |grep '.mu$') || exit 0  # ok if no .mu files
 older_than core.mu $MU_LAYERS || {
   cat $MU_LAYERS > core.mu
 }