chiark
/
gitweb
/
~ian
/
subdirmk.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0bf1cda
)
fix stub Makefile to use MAKECMDGOALS
author
Ian Jackson
<ijackson@chiark.greenend.org.uk>
Wed, 13 Nov 2019 17:20:22 +0000
(17:20 +0000)
committer
Ian Jackson
<ijackson@chiark.greenend.org.uk>
Wed, 13 Nov 2019 17:20:22 +0000
(17:20 +0000)
otherwise if you give multiple goals it would reenter main.mk
subdirmk/generate
patch
|
blob
|
history
diff --git
a/subdirmk/generate
b/subdirmk/generate
index 8a2c9869526c3dd80b66814b2913dc387556c9ee..aae2e481e5992fb0068ef1ff2b71a10af75c17e7 100755
(executable)
--- a/
subdirmk/generate
+++ b/
subdirmk/generate
@@
-95,11
+95,10
@@
sub write_makefile ($$) {
my $cd = $depth ? join('/', ('..',) x $depth) : '.';
o <<END;
default: all
- \@: \$@
%: FORCE-ALWAYS-RUN
- \
$(MAKE) -C $cd -f main.mk ${dir_prefix}\$@
+ \
@:
Makefile FORCE-ALWAYS-RUN:
- \
@: \$@
+ \
$(MAKE) -C $cd -f main.mk \$(addprefix ${dir_prefix},\$(MAKECMDGOALS))
.SUFFIXES:
END
}