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.
This commit is contained in:
@@ -89,11 +89,15 @@ clean:
|
|||||||
|
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
define compile
|
||||||
|
$(CXX) -c $(CXXFLAGS) $< -o $@
|
||||||
|
endef
|
||||||
|
|
||||||
PrecompiledHeader.h.gch: ../../projects/mtg/include/PrecompiledHeader.h
|
PrecompiledHeader.h.gch: ../../projects/mtg/include/PrecompiledHeader.h
|
||||||
$(CXX) -c $(CXXFLAGS) $<
|
$(compile)
|
||||||
|
|
||||||
$(OBJS): objs/%.o: src/%.cpp PrecompiledHeader.h.gch
|
$(OBJS): objs/%.o: src/%.cpp PrecompiledHeader.h.gch
|
||||||
$(CXX) -c $(CXXFLAGS) $< -o $@
|
$(compile)
|
||||||
|
|
||||||
$(DEPS): deps/%.d: src/%.cpp
|
$(DEPS): deps/%.d: src/%.cpp
|
||||||
@$(CXX) -MM $(CXXFLAGS) -MQ $(patsubst deps/%.d, objs/%.o, $(@)) -MQ $@ $< > $@
|
@$(CXX) -MM $(CXXFLAGS) -MQ $(patsubst deps/%.d, objs/%.o, $(@)) -MQ $@ $< > $@
|
||||||
|
|||||||
Reference in New Issue
Block a user