...one of the most highly
regarded and expertly designed C++ library projects in the
world.
— Herb Sutter and Andrei
Alexandrescu, C++
Coding Standards
Copyright © 2003-2007 Rene Rivera, David Abrahams, Vladimir Prus
Distributed under the Boost Software License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
Table of Contents
Installing BJam
after building it is simply a matter of
copying the generated executables someplace in your PATH
.
For building the executables there are a set of build
bootstrap
scripts to accomodate particular environments. The scripts take one optional
argument, the name of the toolset to build with. When the toolset is not given
an attempt is made to detect an available toolset and use that. The build scripts
accept these arguments:
build [toolset]
Running the scripts without arguments will give you the best chance of success. On Windows platforms from a command console do:
cd jam source location
.\build.bat
On Unix type platforms do:
cd jam source location
sh ./build.sh
For the Boost.Jam source included with the Boost distribution the jam
source location is BOOST_ROOT/tools/jam/src
.
If the scripts fail to detect an appropriate toolset to build with your particular
toolset may not be auto-detectable. In that case, you can specify the toolset
as the first argument, this assumes that the toolset is readily available in
the PATH
.
Note | |
---|---|
The toolset used to build Boost.Jam is independent of the toolsets used for Boost.Build. Only one version of Boost.Jam is needed to use Boost.Build. |
The supported toolsets, and whether they are auto-detected, are:
Table 40.1. Supported Toolsets
Script |
Platform |
Toolset |
Detection and Notes |
||
---|---|---|---|---|---|
|
Windows NT, 2000, and XP |
|
|
||
|
|||||
|
|||||
|
|||||
|
|
||||
|
|
||||
|
|
||||
|
|
||||
|
|
||||
|
Detection:
Notes:
|
||||
|
Unix, Linux, Cygwin, etc. |
|
|
||
|
|
||||
|
|
||||
|
|
||||
|
|
||||
|
|
||||
|
|
||||
|
|
||||
|
|
||||
|
|
||||
|
|
||||
MacOS X |
|
|
|||
Windows NT, 2000, and XP |
|
|
The built executables are placed in a subdirectory specific to your platform.
For example, in Linux running on an Intel x86 compatible chip, the executables
are placed in: "bin.linuxx86
". The =bjam[.exe]=
executable can be used to invoke Boost.Build.
The build scripts support additional invocation arguments for use by developers of Boost.Jam and for additional setup of the toolset. The extra arguments come after the toolset:
--option
", which are
passed to the build.jam
build script.
build.jam
script.
build [toolset] [setup*] [--option+ target*]
The arguments immediately after the toolset are passed directly to the setup
script of the toolset, if available and if it needs to be invoked. This allows
one to configure the toolset ass needed to do non-default builds of bjam
.
For example to build a Win64 version with vc8
. See the toolset
descriptiona above for when particular toolsets support this.
The arguments starting with the "--option
" forms
are passed to the build.jam
script and are used to further
customize what gets built. Options and targets supported by the build.jam
script:
---
Empty option when one wants to only specify a target.
--release
The default, builds the optimized executable.
--debug
Builds debugging versions of the executable. When built they are placed
in their own directory "bin./platform/.debug
".
--grammar
Normally the Jam language grammar parsing files are not regenerated. This forces building of the grammar, although it may not force the regeneration of the grammar parser. If the parser is out of date it will be regenerated and subsequently built.
--with-python=path
Enables Python integration, given a path to the Python libraries.
--gc
Enables use of the Boehm Garbage Collector. The build will look for the
Boehm-GC source in a "boehm_gc" subdirectory from the bjam
sources.
--duma
Enables use of the DUMA (Detect Uintended Memory Access) debugging memory
allocator. The build expects to find the DUMA source files in a "duma"
subdirectory from the bjam
sources.
--toolset-root=path
Indicates where the toolset used to build is located. This option is
passed in by the bootstrap (build.bat
or build.sh
)
script.
--show-locate-target
For information, prints out where it will put the built executable.
--noassert
Disable debug assertions, even if building the debug version of the executable.
dist
Generate packages (compressed archives) as appropriate for distribution in the platform, if possible.
clean
Remove all the built executables and objects.