Paul D. Smith wrote:
> You say "[Bruno] also observed that in "force" targets this is usually
> the situation" ... I didn't understand that comment?
My issue is a bit more different than just pure doc: R. Bernstein suggested
that I use .PHONY in a Makefile of mine, because that would speed up
"make"'s execution (avoiding some disk accesses). The problems I have
with .PHONY is
1) The way he suggested it, I should also add .PHONY to the "force"
target. But since sometimes we have a dependency
real-file.c : ... force
this would violate the documented rule that "A phony target should
not be a prerequisite of a real target file".
2) Such a rule is hard to respect over the years, when a Makefile
becomes bigger and bigger. It would be nice to have a GNU make
warning option that would tell me
Makefile:38: warning: target 'real-file.c' exists as a file but
depends on 'force' which is phony
3) With such a warning in place, I would sometimes have to remove
the phonycity of a target, defeating the earlier speedups. So
what is the right compromise between speedup and correct execution
of a Makefile?
Bruno
_______________________________________________
Help-make mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-make