commit f66ea739a938bb3b4eec0bf53006e05420487b79 Author: Jacob Welsh AuthorDate: Thu Sep 28 15:29:51 2023 +0000 Commit: Jacob Welsh CommitDate: Thu Sep 28 15:29:51 2023 +0000 fix parallel build from top-level Makefile When $(MAKE) is expanded from another variable, it breaks some required magic and make complains with "warning: jobserver unavailable: using -j1. Add '+' to parent make rule." Rather than adding even more obscure magic and prefixing the recipes with +, just expand them out since there's not that many subdirs. Still suboptimal, in that the sub-makes are still forced to complete sequentially (one subdir before the other). I'm not as yet seeing a tidy solution here, without exploding even more phony targets. diff --git a/Makefile b/Makefile index 314edad444..c4a9040c53 100644 --- a/Makefile +++ b/Makefile @@ -1,13 +1,15 @@ -MAKE_SUBDIRS = $(MAKE) -C src $@ && $(MAKE) -C doc $@ - all: - $(MAKE_SUBDIRS) + $(MAKE) -C src all + $(MAKE) -C doc all check: - $(MAKE_SUBDIRS) + $(MAKE) -C src check + $(MAKE) -C doc check install: - $(MAKE_SUBDIRS) + $(MAKE) -C src install + $(MAKE) -C doc install clean: - $(MAKE_SUBDIRS) + $(MAKE) -C src clean + $(MAKE) -C doc clean