From: Adam Heath Date: Sat, 2 Mar 2002 05:54:33 +0000 (+0000) Subject: Allow for make -j to work thru the top-level targets. There are problems, X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a8413dd5caf49de05c3db37bec87b551f1f61603;p=dpkg Allow for make -j to work thru the top-level targets. There are problems, however, as the system will try to compile the programs before libdpkg is done. --- diff --git a/ChangeLog b/ChangeLog index 66167a04..cda2adbf 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +Fri Mar 1 23:51:06 CST 2002 Adam Heath + + * Makefile.in: Allow for make -j to work thru the top-level targets. + There are problems, however, as the system will try to compile the + programs before libdpkg is done. + Fri Mar 1 23:27:16 CST 2002 Adam Heath * main/help.c, debian/changelog: Fix segfault with getenv("PATH") returns diff --git a/Makefile.in b/Makefile.in index cb312c2b..dd4fb5da 100644 --- a/Makefile.in +++ b/Makefile.in @@ -27,11 +27,11 @@ distclean: clean distclean-recursive version.h: version-nr echo "#define DPKG_VERSION \"$(VERSION)\" /* This line modified by Makefile */" > version.h -all-recursive install-recursive clean-recursive distclean-recursive: - set -e ; target=`echo $@ | sed s/-recursive//`; \ - for d in $(SUBDIRS) ; do \ - $(MAKE) $(MFLAGS) -C $$d $$target ; \ - done; +all-recursive install-recursive clean-recursive distclean-recursive: %-recursive: + $(MAKE) $(MFLAGS) $(patsubst %,$*-%,$(SUBDIRS)) + +$(foreach target,all install clean distclean,$(patsubst %,$(target)-%,$(SUBDIRS))): + $(MAKE) $(MFLAGS) -C `echo $@ | sed s/[^-]*-//` `echo $@ | sed s/-.*//` .PHONY: all install clean distclean .PHONY: all-recursive install-recursive clean-recursive distclean-recursive