Anonymous committed dc1be74

Add automatically dependency tracking for C/C++ files

Every time a header is changed, the user had to cleanup the whole project and
then rebuild it. It is quite easy to fix and should help a lot when working on
the project. The dependency files will be created at the first run (when
dependency tracking isn't useful anyway) and should create nearly no overhead.

  • Participants
  • Parent commits 7af0fc6

Comments (0)

Files changed (1)


 	rm -f "$(DESTDIR)$(SHAREDIR)/Glide64.ini"
-	rm -f ./_obj/*.o  ./_obj/wrapper/*.o $(TARGET)
+	rm -rf ./_obj/* $(TARGET)
 rebuild: clean all
+# build dependency files
+-include $(OBJECTS:.o=.d)
 # build rules
 	$(CXX) $(SHARED) $^ $(LDFLAGS) -o $@