bugmake - Bugs: bug #3078, implicit rules don't match phony...

 
 

bug #3078: implicit rules don't match phony targets

Submitted by:  Invalid User ID <Invalid User ID>
Submitted on:  Wed 02 Apr 2003 11:27:14 PM UTC  
 
Severity: 3 - NormalItem Group: Bug
Status: Not A BugPrivacy: Public
Assigned to: NoneOpen/Closed: Closed
Component Version: NoneOperating System: None
Fixed Release: NoneTriage Status: None

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Fri 18 Apr 2003 02:11:39 AM UTC, comment #2:

I should point out that if you really want this functionality you can get it, using the FORCE method (also described in the GNU make manual, in the next section from the one that describes PHONY targets):

subdirs := a b c

$(addprefix mkdir-,$(subdirs)): FORCE
FORCE:

mkdir-%: ; mkdir -p $*

In short, one of the main advantages of PHONY is that it's more efficient because it doesn't do implicit rule searches. If you want an implicit rule search done, then you should use FORCE instead.

Paul D. Smith <psmith>
Project Administrator
Fri 18 Apr 2003 02:07:49 AM UTC, comment #1:

The documentation is actually quite clear about this; from the GNU make manual section "Phony Targets":

Since it knows that phony targets do not name actual files
that could be remade from other files, `make' skips the
implicit rule search for phony targets (*note Implicit
Rules::). This is why declaring a target phony is good
for performance, even if you are not worried about the
actual file existing.

Paul D. Smith <psmith>
Project Administrator

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

CC list is empty

 

Do you think this task is very important?
If so, you can click here to add your encouragement to it.
This task has 0 encouragements so far.

Only logged-in users can vote.

 

Please enter the title of George Orwell's famous dystopian book (it's a date):

 

 

Follow 2 latest changes.

Date Changed By Updated Field Previous Value => Replaced By
Fri 18 Apr 2003 02:07:49 AM UTCpsmithStatusNone=>(Error - Not Found)
  Open/ClosedOpen=>(Error - Not Found)

Back to the top


Powered by Savane 3.1-cleanup1