bug-make
[Top][All Lists]
Advanced

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

Gnu Make Dependency Bug? -- SORRY


From: jess
Subject: Gnu Make Dependency Bug? -- SORRY
Date: Tue, 23 Apr 2002 15:08:16 -0700

I have just discovered your discussion of ${MAKECMDGOALS} and its use to
avoid creating the dependency files for a "make clean".  I am sorry to have
bothered you.

Jess Barmatz

----- Forwarded by Jess Barmatz/Orincon on 04/23/2002 03:06 PM -----
                                                                                
                              
                    Jess Barmatz                                                
                              
                                         To:     address@hidden                 
                            
                    04/23/2002           cc:                                    
                              
                    02:58 PM             Subject:     Gnu Make Dependency Bug?  
                              
                                                                                
                              
                                                                                
                              



I believe that the enclosed makefile illustrates an unfortunate feature of
gnu make.

Note first that the makefile constructs (header) file dependencies just as
documented in http://www.gnu.org/manual/make/html_chapter/make_4.html.

The problem is that gnu make examines all dependencies and tries to satisfy
them before executing the selected target. If the target is clean, which
deletes the dependency files, gnu make first tries to create them.  Not
only does this waste time, but it may be impossible if,  for example, a
local *.h file has been removed or renamed.  That causes the "make" to
abort without completing the "make clean".

What also seems particularly unfortunate is that "make clean" first creates
all the dependency files and then deletes them!

So far as I can determine from the documentation, there is no way to work
around this, e.g., to determine the target and suppress the "-include" line
that includes the dependency files.

Do you know of another solution?

Thank you,
Jess Barmatz
ORINCON CORP.







reply via email to

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