
Drumheller, Michael wrote:
Hello:
I am trying to write some Jamfiles and I am finding that bjam tends to run my rules twice. Here is a tiny demo (using Boost 1.31.1 on Windows XP, with zsh/cygwin, bjam version "3.1.13. OS=NT".).
% export BOOST_ROOT=c:/boost_1_33_1; cd c:/; rm -rf deleteme; mkdir deleteme; cd deleteme; echo 'Echo Hello Twice ;' > Jamfile; bjam Hello Twice Hello Twice ...found 8 targets...
(Note: If the first statement is "export BOOST_ROOT=;" instead, I get the error "Unable to load Boost.Build: could not find "boost-build.jam...Attempted search from c:\deleteme up to the root...etc.")
Notice the double-execution.
Can anyone reproduce and/or explain this?
Yes, that's per design of the build system (v1 only). It uses the first pass to declare all the targets, and the second pass to define them and hence to possible refer to other declared targets. -- -- Grafik - Don't Assume Anything -- Redshift Software, Inc. - http://redshift-software.com -- rrivera/acm.org - grafik/redshift-software.com -- 102708583/icq - grafikrobot/aim - grafikrobot/yahoo