help-make
[Top][All Lists]
Advanced

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

order in Makefile


From: Yossi . Itzkovich
Subject: order in Makefile
Date: Tue, 30 Jul 2002 08:20:30 +0300

Hi,

Is the order of definitions  and actions in makefile important ?  I'll
explain.  For example:


VAR1= ...
VAR2=...

clean:  ...
      ...

VAR3= $(shell ....)

make_dep: ....
      .....


Will VAR3 be calculated (= executing the shell command) ONLY for make_dep ?
or does the make parser first calculates all definition and then starts
checking for actions ?

(I guess that:

make_dep: VAR3 =$(shell ....)
make_dep:  ...
      ....

will do it ONLY when make_dep is checked.)

This may be a matter of efficiency.

Yossi




reply via email to

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