Subject: Shepherd parallel make help2man issue

From: Simon Josefsson <[email-masked]>
Date: Tue, 04 Mar 2025 08:22:14 +0100

Hi

I got the build error below.  Presumably it happens because the jobs to
create the tools has not finished before the help2man jobs has started.

I will patch around this in the Debian packaging to serialize the build:

override_dh_auto_build:
	# build tools that help2man needs first
	dh_auto_build $(DH_BUILD_OPTS) -- shepherd herd halt reboot
	dh_auto_build $(DH_BUILD_OPTS)

But it seems like a upstream problem.  I know how annoying these kind of
bugs are, sorry for another report of this type :)

/Simon

   dh_auto_build
	make -j42
make[1]: Entering directory '/build/reproducible-path/shepherd-1.0.2'
/usr/bin/mkdir -p "`dirname modules/shepherd/config.scm`"
make  all-recursive
make[2]: Entering directory '/build/reproducible-path/shepherd-1.0.2'
Making all in po
make[3]: Entering directory '/build/reproducible-path/shepherd-1.0.2/po'
make[3]: Nothing to be done for 'all'.
make[3]: Leaving directory '/build/reproducible-path/shepherd-1.0.2/po'
make[3]: Entering directory '/build/reproducible-path/shepherd-1.0.2'
/usr/bin/mkdir -p "`dirname shepherd`" ;		\
 chmod +x shepherd
/usr/bin/mkdir -p "`dirname herd`" ;		\
 chmod +x herd
/usr/bin/mkdir -p "`dirname halt`" ;		\
 chmod +x halt
/usr/bin/mkdir -p "`dirname reboot`" ;		\
 chmod +x reboot
LANGUAGE= /bin/bash '/build/reproducible-path/shepherd-1.0.2/build-aux/missing' help2man --source=GNU --info-page=shepherd --output="doc/shepherd.1" "./`basename "doc/shepherd.1" .1`"
LANGUAGE= /bin/bash '/build/reproducible-path/shepherd-1.0.2/build-aux/missing' help2man --source=GNU --info-page=shepherd --output="doc/herd.1" "./`basename "doc/herd.1" .1`"
make[4]: Entering directory '/build/reproducible-path/shepherd-1.0.2'
help2man: can't get `--help' info from ./herd
Try `--no-discard-stderr' if option outputs to stderr
help2man: can't get `--help' info from ./shepherd
Try `--no-discard-stderr' if option outputs to stderr
WARNING: 'help2man' is missing on your system.
         You should only need it if you modified a dependency of a man page.
         You may want to install the GNU Help2man package:
         <https://www.gnu.org/software/help2man/>
WARNING: 'help2man' is missing on your system.
         You should only need it if you modified a dependency of a man page.
         You may want to install the GNU Help2man package:
         <https://www.gnu.org/software/help2man/>
make[3]: *** [Makefile:2252: doc/shepherd.1] Error 127
make[3]: *** Waiting for unfinished jobs....
make[3]: *** [Makefile:2255: doc/herd.1] Error 127
make[4]: Leaving directory '/build/reproducible-path/shepherd-1.0.2'
Updating ./doc/version.texi
make[3]: Leaving directory '/build/reproducible-path/shepherd-1.0.2'
make[2]: *** [Makefile:1470: all-recursive] Error 1
make[2]: Leaving directory '/build/reproducible-path/shepherd-1.0.2'
make[1]: *** [Makefile:871: all] Error 2
make[1]: Leaving directory '/build/reproducible-path/shepherd-1.0.2'
dh_auto_build: error: make -j42 returned exit code 2