bugmake - Bugs: bug #31248, .SECONDEXPANSION: Inconsistent...

 
 

bug #31248: .SECONDEXPANSION: Inconsistent expansion of glob patterns in pattern rule dependency lines

Submitted by:  None
Submitted on:  Mon 04 Oct 2010 10:43:47 PM UTC  
 
Severity: 3 - NormalItem Group: Bug
Status: NonePrivacy: Public
Assigned to: NoneOpen/Closed: Open
Component Version: 3.82Operating System: Any
Fixed Release: NoneTriage Status: None

Add a New Comment (Rich MarkupRich Markup):
   

You are not logged in

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

 

Mon 04 Oct 2010 10:43:47 PM UTC, original submission:

(The test case is at the end.)

In GNU Make 3.80, glob wildcards were not expanded in pattern dependency lines. In 3.81 they were expanded, but sometimes in the wrong directory. In 3.82, we get the 3.81 behavior when second expansion is triggered, and otherwise the 3.80 behavior.

Should glob expansion be suppressed for pattern dependency lines, as was historically the case, even after second expansion? If not, then it may be best to prefix the stem directory before globbing, instead of after globbing.

Consider this makefile:

(The "TRIGGER" stuff can be necessary to ensure that the second expansion code path is followed.) Consider also this directory tree:

Linux GNU Make 3.82 and 3.80 with no command line arguments (the historical behavior):

Linux GNU Make 3.82 with "SEC=yes" on the command line, and also 3.81 regardless of command line arguments:

Note that globbing matches "foo.y" to "foo.ytop" in the top-level directory, even though GNU Make then prefixes "dir/". If globbing is desired, then I think it would make more sense to match "dir/foo.y" against "dir/foo.ybot".

(Thanks for reading this lengthy discussion.)

-- John Carey

Anonymous

 

(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):

 

 

No Changes Have Been Made to This Item

Back to the top


Powered by Savane 3.1-cleanup