|
Boost Users : |
From: David Abrahams (dave_at_[hidden])
Date: 2004-09-02 06:29:17
Vladimir Prus <ghost_at_[hidden]> writes:
> Phillip Seaver wrote:
>
>> I want to switch to jam for building our projects and I was wondering
>> how to handle building boost within those projects. Will "subinclude
>> boost" from the directory above it work? Or will I have to use bjam on
>> the boost tree (like a recursive make)?
>>
>> Thanks in advance,
>
> In Boost.Build V2, using boost from your project is a simple matter of
> saying something like:
>
> use /boost/filesystem : $(BOOST_ROOT)/libs/filesystem/build ;
>
> exe foo : foo.cpp /boost/filesystem//boost_filesystem ;
>
> This will even automatically add boost includes when compiling foo.cpp.
>
> As for V1, I'm not sure.
It's straightforward.
In the top level of your project, put this "Jamrules" file:
---- Begin Jamrules ----
project boost : path/to/boost/root/directory ; # contains libs/, more/, ...
---- End Jamrules ----
To link with a boost library or dll, add something like this to your
target's sources:
<lib>@boost/libs/filesystem/build/boost_filesystem
or
<dll>@boost/libs/date_time/build/boost_date_time
HTH,
-- Dave Abrahams Boost Consulting http://www.boost-consulting.com
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net