[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Sequencing targets during a build.
From: |
Paul D. Smith |
Subject: |
Re: Sequencing targets during a build. |
Date: |
Wed, 26 Jan 2005 11:25:00 -0500 |
%% "Stranc, Christopher [BRAM:LSBA:EXCH]"<address@hidden> writes:
sc> I would dearly love a way to "hint" to make to run 2-1-slow as
sc> soon as it's dependencies are met, with priority over other
sc> targets.
There is no way to do this. Make will run targets in the order they
appear on the prerequisite line, as fast as possible. So, if 2-1-slow
is the first prerequisite to be considered, then it will be run first.
If it isn't, it won't be.
sc> 1.Sequencing the targets in the COMPONENTS list 2-1-slow first so
sc> it might be at the beginning of the list for "what to run next".
sc> Unfortunately the way the build is structured I cannot actually
sc> change when the target is first identified.
This is your only option.
Maybe you could run the build like this:
make -j5 2-1-slow all
either directly, or even through a recursive invocation; something like
adding this to the top of your makefile:
.PHONY: recurse
recurse:
$(MAKE) 2-1-slow all
That will force make to build the 2-1-slow target first. You don't need
to change "all" to avoid 2-1-slow; make is smart enough to handle the
same prerequisite being referenced by multiple targets and will only
build it once.
--
-------------------------------------------------------------------------------
Paul D. Smith <address@hidden> Find some GNU make tips at:
http://www.gnu.org http://make.paulandlesley.org
"Please remain calm...I may be mad, but I am a professional." --Mad Scientist