chiark
/
gitweb
/
~mdw
/
distorted-chroot
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
fe87403
)
Makefile: Add a new thing for running arbitrary commands.
author
Mark Wooding
<mdw@distorted.org.uk>
Tue, 5 May 2020 19:48:32 +0000
(20:48 +0100)
committer
Mark Wooding
<mdw@distorted.org.uk>
Tue, 5 May 2020 19:50:02 +0000
(20:50 +0100)
Makefile
patch
|
blob
|
blame
|
history
diff --git
a/Makefile
b/Makefile
index a3a1eccb29e42e7ae2f0c82cac84680bc6ef0b5f..c9befaf25749639ef8e1028ac8bbefcb08f2b5a6 100644
(file)
--- a/
Makefile
+++ b/
Makefile
@@
-647,6
+647,19
@@
maint: all check
$(MAINT) -f$(FRESH) $(JOBS)
.PHONY: maint
$(MAINT) -f$(FRESH) $(JOBS)
.PHONY: maint
+###--------------------------------------------------------------------------
+### Running random commands.
+
+CMD = echo %d %a
+subst-command = $(subst %d,$(call chroot-dist,$1), \
+ $(subst %a,$(call chroot-arch,$1), \
+ $(subst %r,$1, $(CMD))))
+
+run: $(foreach c,$(ALL_CHROOTS),run/$c)
+$(foreach c,$(ALL_CHROOTS),run/$c): run/%:
+ $(V_AT)$(call v_print,RUN,$(call subst-command,$*))\
+ $(call subst-command,$*)
+
###--------------------------------------------------------------------------
### Other maintenance targets.
###--------------------------------------------------------------------------
### Other maintenance targets.