From fe9c43bc8129a25c3369831aab0dfbd344590d4b Mon Sep 17 00:00:00 2001 From: "wrenczes@gmail.com" Date: Sat, 13 Nov 2010 08:53:22 +0000 Subject: [PATCH] Fixed the makefile - the precompiled header additions I previously made wasn't quite syntactically correct, causing unnecessary rebuilds of untouched object files. Now only touched cpps will be rebuilt as expected. --- projects/mtg/Makefile | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/projects/mtg/Makefile b/projects/mtg/Makefile index 98a423371..c9d7c8721 100644 --- a/projects/mtg/Makefile +++ b/projects/mtg/Makefile @@ -89,11 +89,15 @@ clean: endif +define compile +$(CXX) -c $(CXXFLAGS) $< -o $@ +endef + PrecompiledHeader.h.gch: ../../projects/mtg/include/PrecompiledHeader.h - $(CXX) -c $(CXXFLAGS) $< + $(compile) $(OBJS): objs/%.o: src/%.cpp PrecompiledHeader.h.gch - $(CXX) -c $(CXXFLAGS) $< -o $@ + $(compile) $(DEPS): deps/%.d: src/%.cpp @$(CXX) -MM $(CXXFLAGS) -MQ $(patsubst deps/%.d, objs/%.o, $(@)) -MQ $@ $< > $@