help-make
[Top][All Lists]
Advanced

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

RE: include files with :=


From: Dill, John
Subject: RE: include files with :=
Date: Wed, 15 Dec 2004 11:13:40 -0600

>I am still trying to track down where exactly my lag time is coming from, and 
>it doesn't >appear to be from using the include directive by itself.  My 
>question is how makefile
>evaluates variables that are defined using ':=' with respect to include files.
>
>If I have a file include_me.mk which contains:
>
>my_var:=$(shell script)
>
>and I have included this file several times (indirectly through my file's 
>dependent
>include files).  Does make re-evaluate this variable assignment each time 
>'include
>include_me.mk' appears?
>
>If that's the case, then I think that's where my problem is.

I did some more investigation and found that this is where my performance 
problem is.  It appears that time increases linearly with the number of times 
the include file with ':=' variables are included, which means make is 
evaluating it each time it is seen like it should.  Adding inclusion guards to 
my include files should fix my performance problem.

John




reply via email to

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