chiark / gitweb /
subdirmk: stub Makefiles: filter out `all'
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Tue, 3 Dec 2019 23:07:00 +0000 (23:07 +0000)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Wed, 4 Dec 2019 01:26:12 +0000 (01:26 +0000)
Otherwise `make all' generates this:
  Makefile:3: target 'all' given more than once in the same rule
which is harmless but mildly irritating.

Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
subdirmk/generate

index dd22146339b130fc6ffbb7efdd9ab3ce0ccc8515..87e2214965846f2ed5d81905f8197844b6fe6bd6 100755 (executable)
@@ -99,7 +99,7 @@ sub write_makefile ($$) {
     my $cd = $depth ? join('/', ('..',) x $depth) : '.';
     o <<END;
 default: all
-\$(MAKECMDGOALS) all: run-main.mk
+\$(filter-out all,\$(MAKECMDGOALS)) all: run-main.mk
        \@:
 Makefile run-main.mk:
        \$(MAKE) -C $cd -f main.mk \$(addprefix ${dir_prefix},\$(or \$(MAKECMDGOALS),all))