aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTianhao Wang <wth@riseup.net>2023-11-02 01:18:12 +0100
committerTianhao Wang <wth@riseup.net>2023-11-02 01:18:12 +0100
commit984e94449457749e53bea0e209be98cba4b08c27 (patch)
treec2ca821200049cb67772e3fa85562e95a823631e
parentf3ba79298a26169d6563c42bbd437b903623c599 (diff)
optimize makefile
-rw-r--r--Makefile19
-rw-r--r--testall.sh1
2 files changed, 3 insertions, 17 deletions
diff --git a/Makefile b/Makefile
index 7a077b5..e95795b 100644
--- a/Makefile
+++ b/Makefile
@@ -1,20 +1,5 @@
-targets = test_0
-targets += test_1
-targets += test_2
-targets += test_3
-targets += test_4
-targets += test_5
-targets += test_6
-targets += test_7
-targets += test_8
-targets += test_9
-targets += test_10
-targets += test_11
-targets += test_12
-targets += test_13
-targets += test_14
-targets += test_15
-targets += test_16
+offs = $(shell seq 0 1 16)
+targets = $(addprefix test_,$(offs))
all: $(targets)
diff --git a/testall.sh b/testall.sh
index 922e1bd..74d7bf9 100644
--- a/testall.sh
+++ b/testall.sh
@@ -6,6 +6,7 @@ do
./test_0 > /dev/null
done
+# run the first one with offset=0 as reference
sum=0
for i in $(seq 0 1 $runs)
do