help-make
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: multiple .PHONY or single .PHONY


From: Paul Smith
Subject: Re: multiple .PHONY or single .PHONY
Date: Thu, 18 Feb 2010 10:23:19 -0500

On Thu, 2010-02-18 at 09:37 -0500, Martin d'Anjou wrote:
> Hello,
> 
> Is it okay to declare .PHONY multiple times, scattered throughout the 
> makefile like this:
> 
> .PHONY: all
> .PHONY: clean
> .PHONY: other
> 
> Or must all .PHONY targets be consolidated into a single .PHONY 
> declaration like this:
> 
> .PHONY:all clean other

You can have as many .PHONY prerequisite definitions as you like;
they're cumulative, just like any other target.

-- 
-------------------------------------------------------------------------------
 Paul D. Smith <address@hidden>          Find some GNU make tips at:
 http://www.gnu.org                      http://make.mad-scientist.net
 "Please remain calm...I may be mad, but I am a professional." --Mad Scientist





reply via email to

[Prev in Thread] Current Thread [Next in Thread]