bugmake - Bugs: bug #15145, improving automatic generation of...

 
 

bug #15145: improving automatic generation of prerequisites example

Submitter:  None
Submitted:  Mon 05 Dec 2005 04:14:17 AM UTC
   
 
Severity:  3 - Normal Item Group:  Documentation
Status:  Fixed Privacy:  Public
Assigned to:  None Open/Closed:  Closed
Component Version:  3.79.1 Operating System:  POSIX-Based
Fixed Release:  3.80 Triage Status:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Tue 03 Jan 2006 04:07:34 AM UTC, comment #1: 

This has already been fixed in the latest release (GNU make 3.80).

Paul D. Smith <psmith>
Group administrator
Mon 05 Dec 2005 04:14:17 AM UTC, original submission:  

Hi guys!
In the documentation I've met your example of the rule to generate prerequisites automatically (sec. 4.14 of the online manual). I think it's not clean enough because in the case when compiler fails to generate dependancy it keeps a temporary file undeleted, each time. I think it's better to give up using 'set -e' feature of shell and think about other possibilities to check exit status of a command that needs to be followed by another command like in a pipeline. I would suggest to put a following construct
[ -s $@ ] || ( rm -f $@; false )
in the end of the rule. So if you don't have a target file or it is empty you make it sure that return status is non-zero and there is no target file left with updated time stamp.

One more thing. 'set -e' does not work for pipeline commands as assumed in make.info documentation v3.79.1 (the same section about automatic prerequisites).

Cheers,
Sergey

Anonymous

 

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

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

CC list is empty

 

There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

Only logged-in users can vote.

 

Follow 3 latest changes.

Date Changed by Updated Field Previous Value => Replaced by
2006-01-03 psmith StatusNone Fixed
    Open/ClosedOpen Closed
    Fixed ReleaseNone 3.80

Back to the top

Powered by Savane 3.13-02a9.
Corresponding source code