On Wed, 2010-09-22 at 15:39 +0330, ali hagigat wrote:
> 'the path to the file found during directory search is used for any
> prerequisite lists which contain this target.'
> So the path of target is used for all its prerequisites, it is used to
> do what? The processing of all of prerequisites have been finished at
> the beginning of Step 4!!

Make is recursive.  Every prerequisite is itself considered as a target.

Consider this example:

        a: b
        b: c
        c: d

In "b: c", c is a prerequisite.  But in "c: d", c is a target.  These
are the same files, of course.

What the manual says is that when "c" is considered a target (when make
is evaluating the "c: d" rule), if it is found via vpath and not
rebuilt, then that vpath name will be used anywhere that "c" is
considered a prerequisite (that is, in "b: c").

So, if you had:

        vpath c somedir
        a: b
        b: c
        c: d

and ./c did not exist and ./somedir/c existed and did not need to be
rebuilt, then it would be as if you'd written "b: somedir/c".

-- 
-------------------------------------------------------------------------------
 Paul D. Smith <[email protected]>          Find some GNU make tips at:
 http://www.gnu.org                      http://make.mad-scientist.net
 "Please remain calm...I may be mad, but I am a professional." --Mad Scientist


_______________________________________________
Help-make mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-make

Reply via email to