make-alpha
[Top][All Lists]
Advanced

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

Re: Help about implementing requested features.


From: Paul Smith
Subject: Re: Help about implementing requested features.
Date: Sun, 14 Oct 2007 12:42:13 -0400

On Sun, 2007-10-14 at 16:50 +0200, Ramón García wrote:
> But I don't know to implement the reference of automatic
> variables in such a way that it does work only after the Makefile has
> been parsed.
> 
> How can I detect if the parsing of the Makefile (and all referenced
> makefiles) has finished?

You can check the global variable snapped_deps.

GNU make reads in all the makefiles then invokes snap_deps() to set up
all the various data structures for prerequisites, etc.  When that's
done it sets the value snapped_deps to true (this is currently used
during some types of variable initialization etc.) then proceeds to run
the makefile.

So, if snapped_deps is true then make has completed reading all the
makefiles.

-- 
-------------------------------------------------------------------------------
 Paul D. Smith <address@hidden>          Find some GNU make tips at:
 http://www.gnu.org                      http://make.mad-scientist.us
 "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]