aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatt Corallo <matt@bluematt.me>2012-07-03 17:30:43 +0200
committerLuke Dashjr <luke-jr+git@utopios.org>2012-08-26 20:44:40 +0000
commitb958999af17473300e5b3cd26bd16997e21dd644 (patch)
tree790358603537619215b5ee36674f5da68471e6df
parenta259baa9557af63cca220802ee45be4f4b54ac90 (diff)
downloadbitcoin-b958999af17473300e5b3cd26bd16997e21dd644.tar.xz
Work around a distcc bug where -MMD output isn't copied.
-rw-r--r--src/makefile.osx4
-rw-r--r--src/makefile.unix4
2 files changed, 4 insertions, 4 deletions
diff --git a/src/makefile.osx b/src/makefile.osx
index 5e9236fd73..449ff89748 100644
--- a/src/makefile.osx
+++ b/src/makefile.osx
@@ -111,7 +111,7 @@ all: bitcoind
-include obj-test/*.P
obj/nogui/%.o: %.cpp
- $(CXX) -c $(CFLAGS) -MMD -o $@ $<
+ $(CXX) -c $(CFLAGS) -MMD -MF $(@:%.o=%.d) -o $@ $<
@cp $(@:%.o=%.d) $(@:%.o=%.P); \
sed -e 's/#.*//' -e 's/^[^:]*: *//' -e 's/ *\\$$//' \
-e '/^$$/ d' -e 's/$$/ :/' < $(@:%.o=%.d) >> $(@:%.o=%.P); \
@@ -121,7 +121,7 @@ bitcoind: $(OBJS:obj/%=obj/nogui/%)
$(CXX) $(CFLAGS) -o $@ $(LIBPATHS) $^ $(LIBS)
obj/test/%.o: test/%.cpp
- $(CXX) -c $(TESTDEFS) $(CFLAGS) -MMD -o $@ $<
+ $(CXX) -c $(TESTDEFS) $(CFLAGS) -MMD -MF $(@:%.o=%.d) -o $@ $<
@cp $(@:%.o=%.d) $(@:%.o=%.P); \
sed -e 's/#.*//' -e 's/^[^:]*: *//' -e 's/ *\\$$//' \
-e '/^$$/ d' -e 's/$$/ :/' < $(@:%.o=%.d) >> $(@:%.o=%.P); \
diff --git a/src/makefile.unix b/src/makefile.unix
index e75dda514f..a6492f5361 100644
--- a/src/makefile.unix
+++ b/src/makefile.unix
@@ -132,7 +132,7 @@ all: bitcoind
-include obj-test/*.P
obj/nogui/%.o: %.cpp
- $(CXX) -c $(xCXXFLAGS) -MMD -o $@ $<
+ $(CXX) -c $(xCXXFLAGS) -MMD -MF $(@:%.o=%.d) -o $@ $<
@cp $(@:%.o=%.d) $(@:%.o=%.P); \
sed -e 's/#.*//' -e 's/^[^:]*: *//' -e 's/ *\\$$//' \
-e '/^$$/ d' -e 's/$$/ :/' < $(@:%.o=%.d) >> $(@:%.o=%.P); \
@@ -142,7 +142,7 @@ bitcoind: $(OBJS:obj/%=obj/nogui/%)
$(CXX) $(xCXXFLAGS) -o $@ $^ $(LDFLAGS) $(LIBS)
obj-test/%.o: test/%.cpp
- $(CXX) -c $(TESTDEFS) $(xCXXFLAGS) -MMD -o $@ $<
+ $(CXX) -c $(TESTDEFS) $(xCXXFLAGS) -MMD -MF $(@:%.o=%.d) -o $@ $<
@cp $(@:%.o=%.d) $(@:%.o=%.P); \
sed -e 's/#.*//' -e 's/^[^:]*: *//' -e 's/ *\\$$//' \
-e '/^$$/ d' -e 's/$$/ :/' < $(@:%.o=%.d) >> $(@:%.o=%.P); \