]> git.notmuchmail.org Git - notmuch/commit
Makefile: Fix dependency generation to make .d files themselves dependent.
authorCarl Worth <cworth@cworth.org>
Tue, 10 Nov 2009 16:04:54 +0000 (08:04 -0800)
committerCarl Worth <cworth@cworth.org>
Tue, 10 Nov 2009 16:04:54 +0000 (08:04 -0800)
commit97c7cffdc6e0047bb49a899b013516bc3022e580
tree5fa7fdc8975877c94410f33cfe5353f000e08788
parentc5dccd851a8b79d8cedbfc8f2d2b8f9be2b7fa5a
Makefile: Fix dependency generation to make .d files themselves dependent.

I saw this recommendation in the implementation notes for "Recursive
Make Considered Harmful" and then the further recommendation for
implementing the idea in the GNU make manual.

The idea is that if any of the files change then we need to regenerate
the dependency file before we regenerate any targets.

The approach from the GNU make manual is simpler in that it just uses
a sed script to fix up the output of an extra invocation of the
compiler, (as opposed to the approach in the implementation notes from
the paper's author which use a wrapper script for the compiler that's
always invoked rather than the compiler itself).
Makefile
lib/Makefile.local