This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Defer running makedepend in x2p/ until it's needed.
authorNicholas Clark <nick@ccl4.org>
Wed, 15 May 2013 11:01:22 +0000 (13:01 +0200)
committerNicholas Clark <nick@ccl4.org>
Mon, 20 May 2013 19:50:45 +0000 (21:50 +0200)
We can run makedepend in x2p/ as part of the regular build process, which
means that it can run as part of a parallel make. This gets a slight
speedup (0.2s on this system), and increases flexibility on how x2p/Makefile
is generated.

Makefile.SH

index be624e3..720075e 100755 (executable)
@@ -601,6 +601,9 @@ definedefine)
 esac
 
 $spitshell >>$Makefile <<!GROK!THIS!
+x2p/$firstmakefile:    makedepend
+       cd x2p; \$(MAKE) depend
+
 translators:   $x2p_deps
        @echo " "; echo "       Making x2p stuff"; cd x2p; \$(LDLIBPTH) \$(MAKE) all
 
@@ -1396,7 +1399,6 @@ config.h: config_h.SH config.sh
 .PHONY: depend
 depend: makedepend
        sh ./makedepend MAKE=$(MAKE)
-       cd x2p; $(MAKE) depend
 
 # Cannot postpone this until $firstmakefile is ready ;-)
 makedepend: makedepend.SH config.sh