From: Davin McCall Date: Mon, 15 Jan 2018 18:15:33 +0000 (+0000) Subject: tests makefile: auto-generate dependencies (*.d) while building objects. X-Git-Tag: v0.08~37 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=13a43d85542d3e750e47d91e9c923f4a246804bf;p=oweals%2Fdinit.git tests makefile: auto-generate dependencies (*.d) while building objects. --- diff --git a/src/tests/Makefile b/src/tests/Makefile index dd82c0e..9f94055 100644 --- a/src/tests/Makefile +++ b/src/tests/Makefile @@ -23,15 +23,12 @@ proctests: prepare-incdir $(parent_objs) proctests.o test-dinit.o test-bpsys.o $(CXX) $(SANITIZEOPTS) -o proctests $(parent_objs) proctests.o test-dinit.o test-bpsys.o $(EXTRA_LIBS) $(objects): %.o: %.cc - $(CXX) $(CXXOPTS) $(SANITIZEOPTS) -Iincludes -I../dasynq -c $< -o $@ + $(CXX) $(CXXOPTS) $(SANITIZEOPTS) -MMD -MP -Iincludes -I../dasynq -c $< -o $@ $(parent_objs): %.o: ../%.cc - $(CXX) $(CXXOPTS) $(SANITIZEOPTS) -Iincludes -I../dasynq -c $< -o $@ + $(CXX) $(CXXOPTS) $(SANITIZEOPTS) -MMD -MP -Iincludes -I../dasynq -c $< -o $@ clean: rm -f *.o *.d -$(objects:.o=.d): %.d: %.cc - $(CXX) $(CXXOPTS) -Iincludes -I../dasynq -MM -MG -MF $@ $< - -include $(objects:.o=.d) +-include $(objects:.o=.d)