Boost logo

Boost :

Subject: Re: [boost] how to specify options for Boost-building?
From: Steven Watanabe (watanabesj_at_[hidden])
Date: 2009-02-12 13:03:05


AMDG

Oliver Kullmann wrote:
> I want to build version 1_38_0, but I can't progress
> due to missing build-documentation.
> I need to use bjam (due to special demands on the build),
> and my platform is Linux.
>
> Apparently besides this little bit of information at
> http://www.boost.org/doc/libs/1_38_0/more/getting_started/unix-variants.html
> there is nothing available? (Even to get there is not obvious --- you need
> to click on "microsoft install" first, in order to find a further link
> to Linux/Unix install?)
>

There are links to both the windows and unix versions at the bottom of
http://www.boost.org/doc/libs/1_38_0/more/getting_started/index.html

> So well, I invoke "bjam --help":
>
> Usage says
>
> bjam [options] [properties] [install|stage]
>
> where under "properties" we find
>
> Properties:
>
> toolset=toolset Indicates the toolset to build with.
>
> variant=debug|release Select the build variant
>
> link=static|shared Whether to build static or shared libraries
>
> threading=single|multi Whether to build single or multithreaded binaries
>
> runtime-link=static|shared
> Whether to link to static or shared C and C++ runtime.
>
>
> What's the syntax here??
>
> "--toolset=gcc", as one finds it on that webpage above, or "toolset=gcc", as that
> information seems to suggest (since for the options the "--" is mentioned)??
>

The syntax is toolset=gcc. For toolset (only) --toolset=gcc will also
work for backwards compatibility.

> Unfortunately, it seems that, different from all other build systems I'm aware of,
> bjam doesn't print out a summary of what it will be doing. I tried many variations of
> syntax, but apparently it never worked out.
>
> There is an option which is potentially relevant, "--build-type", but again I don't
> know what are the possible parameters for that --- since there are no examples, I don't
> know how to read the cryptic listing (syntax-wise).
>

The options are
--build-type=minimal or --build-type=complete
If you need specific libraries this is probably not helpful.

> What I need to achieve is simple:
>
> 1) I need to specify a locally installed gcc toolset:
> Past installations suggested to use the options
>
> --toolset=gcc-4.1.2
> --toolset-root=PATH-TO-LOCAL-INSTALLATION
> --"-sGCC_ROOT_DIRECTORY=PATH-TO-LOCAL-INSTALLATION"
>
> I can't find any information on that topic.
>

http://www.boost.org/boost-build2/doc/html/bbv2/advanced/configuration.html

> 2) I need a local installation of boost; that works out:
>
> --prefix=XXX
> --build-dir=YYY
>
> no problem here.
>
> 3) No python; this seems also unproblematic
> (but apparently it vanished from the documentation?)
>
> --without-python
>

--without-<library> is listed in the --help output.

> 4) Only simple names for the built libraries; this seems
> also to work with
>
> --layout=system
>

Yep.

> 5) No multi-threading:
> Don't know how to achieve this:
> Somehow "threading=single" seems to be needed here, but I don't know
> how to specify it (whatever I do, I always end up with libraries with
> the "mt"-ending).
>

threading=single should work.

In Christ,
Steven Watanabe


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk