HomeClusterLabs Projects

Build: Be consistent with marking targets as .PHONY.

Description

Build: Be consistent with marking targets as .PHONY.

A couple notes on the changes in this patch:

  • The prerequisites of a .PHONY target (anything on the right side of the colon) are always interpreted as a literal target name. This means any "%" in the target name will be handled literally.

    Remove those targets from .PHONY and instead have them be prerequisites of the FORCE target. This ensures they will always be built.
  • In some places, I have left targets that ought to be PHONY alone. This is because phony targets should not be the prerequisite of a rule that makes a real file. The most obvious example of this occurs in rpm/Makefile.am.
  • In some other places, I have left targets that should not be PHONY marked as such. This is because we want to force them to happen every time the rule is invoked. The most obvious example of this occurs in devel/Makefile.am for the coverity targets.

See:

https://www.gnu.org/software/make/manual/html_node/Phony-Targets.html
https://www.gnu.org/software/make/manual/html_node/Force-Targets.html

Details

Provenance
clumensAuthored on Aug 10 2023, 3:02 PM
Parents
rPe3c64ca16184: Merge pull request #3198 from twtlpla/main
Branches
Unknown
Tags
Unknown