summaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
authortv <tv@krebsco.de>2015-07-19 11:50:54 +0200
committertv <tv@krebsco.de>2015-07-19 11:50:54 +0200
commit1ff89aafaaf948c564d247e358ec42ed70eed5ae (patch)
treee60c02da248e70868d65dd7d8c22fecbc70110e5 /Makefile
parent1f747580290cb71b64d7f714601e9084f52eaf50 (diff)
Makefile: make systems='foo bar...'
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile23
1 files changed, 19 insertions, 4 deletions
diff --git a/Makefile b/Makefile
index b31eddd..7225a5d 100644
--- a/Makefile
+++ b/Makefile
@@ -1,9 +1,22 @@
-ifndef system
-$(error unbound variable: system)
-else
-include 0make/$(LOGNAME)/$(system).makefile
+#
+# usage:
+# make system=foo
+# make systems='foo bar'
+#
+
.ONESHELL:
.SHELLFLAGS := -eufc
+
+ifdef systems
+$(systems):
+ parallel \
+ --line-buffer \
+ -j0 \
+ --no-notice \
+ --tagstring {} \
+ -q make systems= system={} ::: $(systems)
+else ifdef system
+include 0make/$(LOGNAME)/$(system).makefile
.PHONY: deploy
deploy:;@
system_name=$(system)
@@ -69,4 +82,6 @@ deploy:;@
result/bin/switch-to-configuration switch
EOF
+else
+$(error unbound variable: system[s])
endif