From 26ab32ac3b0f8cf99c6561097f5dacbe92d1c972 Mon Sep 17 00:00:00 2001 From: Stephen Williams Date: Fri, 4 Dec 2009 15:20:03 -0800 Subject: [PATCH] Add explicit dependencies on generated header files. These explicit dependencies are not normally needed (because they are covered by automatic dependency generation) but when the "-jN" flag is passed to gmake, they help gmake schedule parallel builds. (cherry picked from commit 5479aaf72132a1565773a496af646b5d57454c6c) --- Makefile.in | 4 +++- libveriuser/Makefile.in | 2 +- tgt-vhdl/Makefile.in | 2 +- tgt-vvp/Makefile.in | 2 +- vpi/Makefile.in | 2 +- vvp/Makefile.in | 4 ++-- 6 files changed, 9 insertions(+), 7 deletions(-) diff --git a/Makefile.in b/Makefile.in index eabfb2e2b..14698cf2f 100644 --- a/Makefile.in +++ b/Makefile.in @@ -197,10 +197,12 @@ version.exe: $(srcdir)/version.c $(srcdir)/version_base.h version_tag.h dep: mkdir dep -%.o: %.cc +%.o: %.cc config.h $(CXX) $(CPPFLAGS) $(CXXFLAGS) -MD -c $< -o $*.o mv $*.d dep/$*.d +# Here are some explicit dependencies needed to get things going. +main.o: main.cc version_tag.h lexor.o: lexor.cc parse.h diff --git a/libveriuser/Makefile.in b/libveriuser/Makefile.in index 12a8484c4..36c067881 100644 --- a/libveriuser/Makefile.in +++ b/libveriuser/Makefile.in @@ -78,7 +78,7 @@ libveriuser.a: libveriuser.o dep: mkdir dep -%.o: %.c +%.o: %.c config.h $(CC) $(CPPFLAGS) $(CFLAGS) -MD -c $< -o $*.o mv $*.d dep diff --git a/tgt-vhdl/Makefile.in b/tgt-vhdl/Makefile.in index 775d58837..686599766 100644 --- a/tgt-vhdl/Makefile.in +++ b/tgt-vhdl/Makefile.in @@ -45,7 +45,7 @@ all: dep vhdl.tgt vhdl.conf vhdl-s.conf dep: mkdir dep -%.o: %.cc +%.o: %.cc vhdl_config.h $(CXX) $(CPPFLAGS) $(CXXFLAGS) -MD -c $< -o $*.o mv $*.d dep diff --git a/tgt-vvp/Makefile.in b/tgt-vvp/Makefile.in index 7ee3d23a6..b0fd57d02 100644 --- a/tgt-vvp/Makefile.in +++ b/tgt-vvp/Makefile.in @@ -47,7 +47,7 @@ all: dep vvp.tgt vvp.conf vvp-s.conf dep: mkdir dep -%.o: %.c +%.o: %.c vvp_config.h $(CC) $(CPPFLAGS) $(CFLAGS) -MD -c $< -o $*.o mv $*.d dep diff --git a/vpi/Makefile.in b/vpi/Makefile.in index 6b2988a78..d3cd4226f 100644 --- a/vpi/Makefile.in +++ b/vpi/Makefile.in @@ -50,7 +50,7 @@ check: all dep: mkdir dep -%.o: %.c +%.o: %.c vpi_config.h $(CC) $(CPPFLAGS) $(CFLAGS) -MD -c $< -o $*.o mv $*.d dep diff --git a/vvp/Makefile.in b/vvp/Makefile.in index e8fa9c2d0..c003dc17e 100644 --- a/vvp/Makefile.in +++ b/vvp/Makefile.in @@ -103,11 +103,11 @@ endif dep: mkdir dep -%.o: %.cc +%.o: %.cc config.h $(CXX) $(CPPFLAGS) $(MDIR1) $(MDIR2) $(CXXFLAGS) -MD -c $< -o $*.o mv $*.d dep/$*.d -%.o: %.c +%.o: %.c config.h $(CC) $(CPPFLAGS) $(MDIR1) $(MDIR2) $(CFLAGS) -MD -c $< -o $*.o mv $*.d dep/$*.d