Hello, I read and implemented the guidelines in the section of the GNU Make manual "4.14 Generating Prerequisities Automatically". It works great, for each C source file, I have a corresponding .d file, which is also a makefile, generated, and all those makefiles are included in the main makefile with the "include" directive. In the .d file are header file dependencies for that particular C file.
There seems to be a problem however with this approach. I write "seems" because it must be that I don't understand something, as I am sure the GNU Make manual recommends the "right thing". Please help me understand what I am missing. The problem I have is: when I do >make foobar.o make then tries to generate all these *.d files, all of them - not just the one that is needed foobar.d ! That is not good -takes a lot of time if I just want one foobar.o. Also, what is worse, if I do >make clean Then again, all the *.d files are generated first, takes a very long time, before everything is deleted. How to do it so that only the *.d files that are really needed are generated, and none are generated on make clean? Thank you for any insight, Mark
_______________________________________________ Help-make mailing list [email protected] http://lists.gnu.org/mailman/listinfo/help-make
