|
Boost-Build : |
From: Phillip Seaver (phil_at_[hidden])
Date: 2007-08-08 08:41:47
Preston A. Elder wrote:
> Actually, this is NOT working for me. Boost.Build seems to add the -l
> arguments, but not the -L arguments when I use <search>.
>
> Here is my Jamfile:
>
> lib uuid ;
> lib tinyxml : : <name>tinyxml <search>$(TINYXML_ROOT) ;
> lib boost_filesystem : : <name>boost_filesystem-gcc41-mt <search>
> $(BOOST_ROOT)/stage/lib ;
> lib boost_system : : <name>boost_system-gcc41-mt <search>$(BOOST_ROOT)/
> stage/lib ;
> lib boost_thread : : <name>boost_thread-gcc41-mt <search>$(BOOST_ROOT)/
> stage/lib ;
> exe hard_coded
> : hard_coded.cpp /mantra/core/log//log
> uuid tinyxml boost_filesystem boost_system boost_thread
> : <include>$(TINYXML_ROOT) ;
>
>
> For completeness, here is my Jamroot:
>
> import os ;
>
> path-constant MANTRA_ROOT : . ;
> local BOOST_ROOT = [ os.environ BOOST_ROOT ] ;
> local TINYXML_ROOT = [ os.environ TINYXML_ROOT ] ;
>
> project
> : requirements <include>. <include>$(BOOST_ROOT)
> ;
>
> use-project /mantra/core/log : libs/core/log ;
> use-project /mantra/utils/throttler : libs/utils/throttler ;
>
>
> By rights it SHOULD generate -L arguments, but the g++ link argument has
> no -L flags in it at all. The -l arguments are all there, but no -L
> arguments. I set BOOST_ROOT to $HOME/src/boost and TINYXML_ROOT to $HOME/
> src/tinyxml, which gets imported above, and since the compiles work I
> know that is fine.
>
> PreZ
As Volodya pointed out, you set BOOST_ROOT and TINYXML_ROOT as local (to
Jamroot) variables. In Jamfile, they're undefined, and
"<search>$(TINYXML_ROOT)" expands to "", so your lib is effectively "lib
tinyxml : : <name>tinyxml ;". See
http://boost.org/doc/html/jam/language.html#jam.language.variables.expansion
Phillip
Boost-Build list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk