help-make
[Top][All Lists]
Advanced

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

RE: Recompile files for different parameters


From: Mark Galeck (CW)
Subject: RE: Recompile files for different parameters
Date: Mon, 7 Mar 2011 06:18:17 -0800

IMHO, everything should depend on the makefile(s) itself.  That would in 
particular solve this problem.  


Put this in the makefile, before including other makefiles, if any

MAKEFILE := $(lastword $(MAKEFILE_LIST))

Then make everything depend on $(MAKEFILE).  If you have more than one 
makefile, you may or may not, depending on the situation, make everything 
depend on $(MAKEFILE_LIST) )(but I would still include the line as above in 
each makefile).  

Also, if you want to be a real neatnick, you may want to do

$(MAKEFILE_LIST): ;

if you want to prevent make trying to remake makefiles or look for implicit 
rules for them.  

Mark  

>Is there a possibility to put the flags into the dependencies so that 
make consider them?
Or should be another solution used for this case?



reply via email to

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