From 6b3043359519e1716a3d6a57d43c153b8e1d2cf0 Mon Sep 17 00:00:00 2001 From: Ben Pfaff Date: Mon, 8 Feb 2016 20:18:34 -0800 Subject: [PATCH] dist-docs: Make GNU make aware of sub-make. When GNU make sees that a command to be executed contains the string $(MAKE), it makes the jobserver that limits parallelism available to the command. Otherwise, any sub-make that executes sees that parallelism is enabled but does not have access to the jobserver, so it prints a warning and turns off parallel job execution. This also makes the dist-docs process run the same "make" that is executed at the top level, in case that's different from the default "make" found in $PATH. Signed-off-by: Ben Pfaff Acked-by: Russell Bryant --- Makefile.am | 2 +- build-aux/dist-docs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile.am b/Makefile.am index 4ca5e9c29..75ccadfb0 100644 --- a/Makefile.am +++ b/Makefile.am @@ -408,7 +408,7 @@ if LINUX_ENABLED endif dist-docs: - VERSION=$(VERSION) $(srcdir)/build-aux/dist-docs $(srcdir) $(docs) + VERSION=$(VERSION) MAKE='$(MAKE)' $(srcdir)/build-aux/dist-docs $(srcdir) $(docs) .PHONY: dist-docs include Documentation/automake.mk diff --git a/build-aux/dist-docs b/build-aux/dist-docs index 3792fa59c..1aeefa7a9 100755 --- a/build-aux/dist-docs +++ b/build-aux/dist-docs @@ -44,7 +44,7 @@ rm -rf $distdir mkdir $distdir # Install manpages. -make install-man mandir="$abs_distdir"/man +${MAKE-make} install-man mandir="$abs_distdir"/man (cd $distdir && mv `find man -type f` . && rm -rf man) manpages=`cd $distdir && echo *` -- 2.20.1