]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
build-sys: fix parallel builds w/setarch links
authorMike Frysinger <vapier@chromium.org>
Mon, 4 May 2015 03:51:04 +0000 (23:51 -0400)
committerKarel Zak <kzak@redhat.com>
Tue, 5 May 2015 10:40:54 +0000 (12:40 +0200)
The symlink generation tries to write to the sys-utils/ subdir but does
not make sure that dir exists.  This can sometimes lead to parallel build
failures when building out-of-tree like:
...
echo ".so man8/setarch.8" > sys-utils/linux64.8
/bin/bash: sys-utils/linux64.8: No such file or directory
Makefile:11503: recipe for target 'sys-utils/linux64.8' failed
make: *** [sys-utils/linux64.8] Error 1

References: https://bugs.gentoo.org/511812
Signed-off-by: Mike Frysinger <vapier@chromium.org>
sys-utils/Makemodule.am

index a1dc042d63105c2784fec710a594f68828fb2f9f..08bb6cea08e302e61a804a525e7885b7ffeef63e 100644 (file)
@@ -152,6 +152,7 @@ man_MANS += $(SETARCH_MAN_LINKS)
 CLEANFILES += $(SETARCH_MAN_LINKS)
 
 $(SETARCH_MAN_LINKS):
+       $(AM_V_at) test -d $(dir $@) || mkdir -p $(dir $@)
        $(AM_V_GEN)echo ".so man8/setarch.8" > $@
 
 install-exec-hook-setarch: