diff --git a/getting_started/detail/build-from-source-head.rst b/getting_started/detail/build-from-source-head.rst index ff72e4f..4d63c08 100644 --- a/getting_started/detail/build-from-source-head.rst +++ b/getting_started/detail/build-from-source-head.rst @@ -2,36 +2,22 @@ .. Software License, Version 1.0. (See accompanying .. file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +Install Boost.Build +................... + Boost.Build_ is a text-based system for developing, testing, and -installing software. To use it, you'll need an executable called -``bjam``. +installing software. First, you'll need to build and +install it. To do this: -.. |precompiled-bjam| replace:: download a pre-built ``bjam`` executable +1. Go to the directory ``tools``\ |/|\ ``build``\ |/|\ ``v2``\ |/|. +2. Run ``bootstrap.bat`` +3. Run ``bjam install --prefix=``\ *PREFIX* where *PREFIX* is + the directory where you want Boost.Build to be installed +4. Add *PREFIX*\ |/|\ ``bin`` to your PATH environment variable. - -.. _precompiled-bjam: http://sourceforge.net/project/showfiles.php?group_id=7586&package_id=72941 -.. .. _Boost.Jam documentation: Boost.Jam_ .. _Boost.Build: ../../tools/build/index.html -.. _Boost.Jam: ../../tools/build/v2/engine/index.html .. _Boost.Build documentation: Boost.Build_ -Get ``bjam`` -............ - -``bjam`` is the |command-line tool| that drives the Boost Build -system. To build Boost binaries, you'll invoke ``bjam`` from the -Boost root. - -We suggest you |precompiled-bjam|_ for your platform. -Alternatively, you can build ``bjam`` yourself using `these -instructions`__. - -__ `building bjam`_ - -Move the ``bjam`` executable into a directory in your PATH. You can -see the list of directories in your PATH, separated by |pathsep|\ s, -by typing “\ |path|\ ” at the command prompt. - .. _toolset: .. _toolset-name: @@ -48,7 +34,7 @@ __ http://www.boost.org/boost-build2/doc/html/bbv2/reference/tools.html `building bjam`_, you should assume it won't work and instead choose newly from the table below. -.. _building bjam: ../../doc/html/jam/building.html +.. _building bjam: ../../doc/html/bbv2/installation.html +-----------+--------------------+-----------------------------+ |Toolset |Vendor |Notes | diff --git a/getting_started/detail/conclusion.rst b/getting_started/detail/conclusion.rst index 402dc6f..2c439e1 100644 --- a/getting_started/detail/conclusion.rst +++ b/getting_started/detail/conclusion.rst @@ -15,10 +15,8 @@ make this document clearer, please post it to the `Boost Users' mailing list`_. * `Boost.Build reference manual`_ -* `Boost.Jam reference manual`_ * `Boost Users' mailing list`_ * `Boost.Build mailing list`_ -* `Boost.Build Wiki`_ * `Index of all Boost library documentation`_ .. _Index of all Boost library documentation: ../../libs/index.html @@ -32,8 +30,6 @@ mailing list`_. -- the Boost Developers .. _Boost.Build reference manual: ../../tools/build/v2/index.html -.. _Boost.Jam reference manual: `Boost.Jam`_ .. _Boost Users' mailing list: http://www.boost.org/more/mailing_lists.htm#users -.. _Boost.Build Wiki: http://www.crystalclearsoftware.com/cgi-bin/boost_wiki/wiki.pl?Boost.Build_V2 .. _Boost.Build mailing list: http://www.boost.org/more/mailing_lists.htm#jamboost diff --git a/getting_started/detail/release-variables.rst b/getting_started/detail/release-variables.rst index 373d595..d35fe8a 100644 --- a/getting_started/detail/release-variables.rst +++ b/getting_started/detail/release-variables.rst @@ -9,4 +9,4 @@ .. |boost_ver| replace:: ``boost_1_46_0`` .. |boost_ver-bold| replace:: **boost_1_46_0** -.. _sf-download: http://sourceforge.net/project/showfiles.php?group_id=7586&package_id=8041 +.. _sf-download: http://www.boost.org/users/history/version_1_46_0.html diff --git a/getting_started/index.html b/getting_started/index.html index 9a39aa6..f82b1e4 100644 --- a/getting_started/index.html +++ b/getting_started/index.html @@ -16,7 +16,7 @@

Use the latest version of this Getting Started guide

-

The Boost website version of this Getting Started guide may +

The Boost website version of this Getting Started guide may have updated information, such as the location of additional installers or improved installation procedures, so you might want use that version if you've got an Internet connection available.

diff --git a/getting_started/index.rst b/getting_started/index.rst index c317614..7585d53 100644 --- a/getting_started/index.rst +++ b/getting_started/index.rst @@ -20,7 +20,7 @@ __ ../../index.htm if you've got an Internet connection available. .. _`Boost website version of this Getting Started guide`: - http://www.boost.org/doc/libs/release/more/getting_started/index.html + http://www.boost.org/more/getting_started/index.html Welcome ------- diff --git a/getting_started/unix-variants.html b/getting_started/unix-variants.html index dc6574e..10c8850 100644 --- a/getting_started/unix-variants.html +++ b/getting_started/unix-variants.html @@ -30,40 +30,40 @@

Index

-

1   Get Boost

+

1   Get Boost

The most reliable way to get a copy of Boost is to download a -distribution from SourceForge:

+distribution from SourceForge:

    -
  1. Download boost_1_46_0.tar.bz2.

    +
  2. Download boost_1_46_0.tar.bz2.

  3. In the directory where you want to put the Boost installation, execute

    @@ -81,14 +81,14 @@ creators usually choose to break Boost up into several packages, reorganize the directory structure of the Boost distribution, and/or rename the library binaries.1 If you have any trouble, we suggest using an official Boost distribution -from SourceForge.

    +from SourceForge.

-

2   The Boost Distribution

+

2   The Boost Distribution

This is a sketch of the resulting directory structure:

 boost_1_46_0/ .................The “boost root directory”
@@ -166,7 +166,7 @@ contains a subset of the Boost documentation.  Start with
 
 
-

3   Header-Only Libraries

+

3   Header-Only Libraries

The first thing many people want to know is, “how do I build Boost?” The good news is that often, there's nothing to build.

@@ -213,7 +213,7 @@ use.
-

4   Build a Simple Program Using Boost

+

4   Build a Simple Program Using Boost

To keep things simple, let's start by using a header-only library. The following program reads a sequence of integers from standard input, uses Boost.Lambda to multiply each number by three, and @@ -247,7 +247,7 @@ echo 1 2 3 | ./example

-

4.1   Errors and Warnings

+

4.1   Errors and Warnings

Don't be alarmed if you see compiler warnings originating in Boost headers. We try to eliminate them, but doing so isn't always practical.3 Errors are another matter. If you're @@ -260,11 +260,11 @@ correctly identified the -

5   Prepare to Use a Boost Library Binary

+

5   Prepare to Use a Boost Library Binary

If you want to use any of the separately-compiled Boost libraries, you'll need to acquire library binaries.

-

5.1   Easy Build and Install

+

5.1   Easy Build and Install

Issue the following commands in the shell (don't type $; that represents the shell's prompt):

@@ -292,7 +292,7 @@ path in place of the Boost root directory.

skip to the next step

-

5.2   Or, Build Custom Binaries

+

5.2   Or, Build Custom Binaries

If you're using a compiler other than your system's default, you'll need to use Boost.Build to create binaries.

You'll also @@ -306,31 +306,28 @@ separately. See the +

5.2.1   Install Boost.Build

Boost.Build is a text-based system for developing, testing, and -installing software. To use it, you'll need an executable called -bjam.

- -
-

5.2.1   Get bjam

-

bjam is the command-line tool that drives the Boost Build -system. To build Boost binaries, you'll invoke bjam from the -Boost root.

-

We suggest you download a pre-built bjam executable for your platform. -Alternatively, you can build bjam yourself using these -instructions.

-

Move the bjam executable into a directory in your PATH. You can -see the list of directories in your PATH, separated by colons, -by typing “echo $PATH” at the command prompt.

+installing software. First, you'll need to build and +install it. To do this:

+
    +
  1. Go to the directory tools/build/v2/.
  2. +
  3. Run bootstrap.bat
  4. +
  5. Run bjam install --prefix=PREFIX where PREFIX is +the directory where you want Boost.Build to be installed
  6. +
  7. Add PREFIX/bin to your PATH environment variable.
  8. +
-

5.2.2   Identify Your Toolset

+

5.2.2   Identify Your Toolset

First, find the toolset corresponding to your compiler in the following table (an up-to-date list is always available in the Boost.Build documentation).

Note

If you previously chose a toolset for the purposes of -building bjam, you should assume it won't work and instead +building bjam, you should assume it won't work and instead choose newly from the table below.

@@ -422,7 +419,7 @@ a hyphen, e.g. intel-9.0borland-5.4.3.

-

5.2.3   Select a Build Directory

+

5.2.3   Select a Build Directory

Boost.Build will place all intermediate files it generates while building into the build directory. If your Boost root directory is writable, this step isn't strictly necessary: by @@ -430,11 +427,11 @@ default Boost.Build will create a bin.v2/ subd purpose in your current working directory.

-

5.2.4   Invoke bjam

+

5.2.4   Invoke bjam

Change your current directory to the Boost root directory and invoke bjam as follows:

-bjam --build-dir=build-directory toolset=toolset-name   stage
+bjam --build-dir=build-directory toolset=toolset-name   stage
 

For a complete description of these and other invocation options, please see the Boost.Build documentation.

@@ -479,7 +476,7 @@ file by appending “>build.log -

5.3   Expected Build Output

+

5.3   Expected Build Output

During the process of building Boost libraries, you can expect to see some messages printed on the console. These may include

    @@ -503,7 +500,7 @@ look something like:

-

5.4   In Case of Build Errors

+

5.4   In Case of Build Errors

The only error messages you see when building Boost—if any—should be related to the IOStreams library's support of zip and bzip2 formats as described here. Install the relevant development @@ -520,7 +517,7 @@ for your compiler to the -

6   Link Your Program to a Boost Library

+

6   Link Your Program to a Boost Library

To demonstrate linking with a Boost binary library, we'll use the following simple program that extracts the subject lines from emails. It uses the Boost.Regex library, which has a @@ -560,7 +557,7 @@ $ c++ -I path/to/boost_1_46_0 example ~/boost/stage/lib/libboost_regex-gcc34-mt-d-1_36.a -

  • You can separately specify a directory to search (with -Ldirectory) and a library name to search for (with -llibrary,2 dropping the filename's leading lib and trailing +

  • You can separately specify a directory to search (with -Ldirectory) and a library name to search for (with -llibrary,2 dropping the filename's leading lib and trailing suffix (.a in this case):

     $ c++ -I path/to/boost_1_46_0 example.cpp -o example \
    @@ -578,7 +575,7 @@ automatically for you unless you pass a special option such as
     

    In both cases above, the bold text is what you'd add to the command lines we explored earlier.

    -

    6.1   Library Naming

    +

    6.1   Library Naming

    @@ -593,7 +590,7 @@ following elements:

    Prefix: except on Microsoft Windows, every Boost library name begins with this string. On Windows, only ordinary static libraries use the lib prefix; import libraries and DLLs do -not.4
    +not.4
    boost_regex
    Library name: all boost library filenames begin with boost_.
    -vc71
    @@ -636,7 +633,7 @@ libraries.
  • - + @@ -674,7 +671,7 @@ version number, will also be created.
    -

    6.2   Test Your Program

    +

    6.2   Test Your Program

    To test our subject extraction, we'll filter the following text file. Copy it out of your browser and save it as jayne.txt:

    @@ -714,7 +711,7 @@ Spoil Rock Hunter?”

    -

    7   Conclusion and Further Resources

    +

    7   Conclusion and Further Resources

    This concludes your introduction to Boost and to integrating it with your programs. As you start using Boost in earnest, there are surely a few additional points you'll wish we had covered. One day @@ -725,10 +722,8 @@ make this document clearer, please post it to the .

    @@ -751,7 +746,7 @@ to the
    -
    python-debugging=on
    dbuilding a debug version of your code.5building a debug version of your code.5 variant=debug
    p
    [2]That option is a dash followed by a lowercase “L” +
    [2]That option is a dash followed by a lowercase “L” character, which looks very much like a numeral 1 in some fonts.
    @@ -772,7 +767,7 @@ have any source code mechanism for suppressing warnings. - @@ -781,7 +776,7 @@ same name.
    [4]This convention distinguishes the static version of +
    [4]This convention distinguishes the static version of a Boost library from the import library for an identically-configured Boost DLL, which would otherwise have the same name.
    -
    [5]These libraries were compiled without optimization +
    [5]These libraries were compiled without optimization or inlining, with full debug symbols enabled, and without NDEBUG #defined. Although it's true that sometimes these choices don't affect binary compatibility with other diff --git a/getting_started/windows.html b/getting_started/windows.html index bada346..fbb463e 100644 --- a/getting_started/windows.html +++ b/getting_started/windows.html @@ -26,45 +26,45 @@ not supported—they may or may not work.

    Index

    -

    1   Get Boost

    +

    1   Get Boost

    The easiest way to get a copy of Boost is to use an installer. The -Boost website version of this Getting Started guide will have +Boost website version of this Getting Started guide will have undated information on installers as they become available, or see -Boost downloads or the installer provided by BoostPro +Boost downloads or the installer provided by BoostPro Computing. We especially recommend using an installer if you use Microsoft Visual Studio, because the installer can download and install precompiled library binaries, saving you the trouble of @@ -73,14 +73,14 @@ least install the Static Multithreaded variants of the boost_1_46_0.7z or boost_1_46_0.zip and unpack it to install a complete Boost +download boost_1_46_0.7z or boost_1_46_0.zip and unpack it to install a complete Boost distribution.1

    -

    2   The Boost Distribution

    +

    2   The Boost Distribution

    This is a sketch of the resulting directory structure:

     boost_1_46_0\ .................The “boost root directory”
    @@ -163,7 +163,7 @@ contains a subset of the Boost documentation.  Start with
     
     
    -

    3   Header-Only Libraries

    +

    3   Header-Only Libraries

    The first thing many people want to know is, “how do I build Boost?” The good news is that often, there's nothing to build.

    @@ -210,7 +210,7 @@ use.
    -

    4   Build a Simple Program Using Boost

    +

    4   Build a Simple Program Using Boost

    To keep things simple, let's start by using a header-only library. The following program reads a sequence of integers from standard input, uses Boost.Lambda to multiply each number by three, and @@ -266,7 +266,7 @@ caret (^) at the end of all but the last line. on this page use that technique to save horizontal space.

    -

    4.1   Build From the Visual Studio IDE

    +

    4.1   Build From the Visual Studio IDE

    • From Visual Studio's File menu, select New > Project…

    • @@ -307,7 +307,7 @@ Return key.

      skip to the next step

    -

    4.2   Or, Build From the Command Prompt

    +

    4.2   Or, Build From the Command Prompt

    From your computer's Start menu, if you are a Visual Studio 2005 user, select

    @@ -333,7 +333,7 @@ echo 1 2 3 | example
    -

    4.3   Errors and Warnings

    +

    4.3   Errors and Warnings

    Don't be alarmed if you see compiler warnings originating in Boost headers. We try to eliminate them, but doing so isn't always practical.5 Errors are another matter. If you're @@ -346,11 +346,11 @@ correctly identified the -

    5   Prepare to Use a Boost Library Binary

    +

    5   Prepare to Use a Boost Library Binary

    If you want to use any of the separately-compiled Boost libraries, you'll need to acquire library binaries.

    -

    5.1   Install Visual Studio Binaries

    +

    5.1   Install Visual Studio Binaries

    The installers supplied by BoostPro Computing will download and install pre-compiled binaries into the lib\ subdirectory of the boost root, typically C:\Program Files\boost\boost_1_46_0\lib\. If you installed @@ -360,7 +360,7 @@ now.

    skip to the next step

    -

    5.2   Or, Simplified Build From Source

    +

    5.2   Or, Simplified Build From Source

    If you wish to build from source with Visual C++, you can use a simple build procedure described in this section. Open the command prompt and change your current directory to the Boost root directory. Then, type @@ -375,7 +375,7 @@ libraries. Please consult the bjam.

    -

    5.3   Or, Build Binaries From Source

    +

    5.3   Or, Build Binaries From Source

    If you're using an earlier version of Visual C++, or a compiler from another vendor, you'll need to use Boost.Build to create your own binaries.

    @@ -387,31 +387,28 @@ separately. See the +

    5.3.1   Install Boost.Build

    Boost.Build is a text-based system for developing, testing, and -installing software. To use it, you'll need an executable called -bjam.

    - -
    -

    5.3.1   Get bjam

    -

    bjam is the command-line tool that drives the Boost Build -system. To build Boost binaries, you'll invoke bjam from the -Boost root.

    -

    We suggest you download a pre-built bjam executable for your platform. -Alternatively, you can build bjam yourself using these -instructions.

    -

    Move the bjam executable into a directory in your PATH. You can -see the list of directories in your PATH, separated by semicolons, -by typing “PATH” at the command prompt.

    +installing software. First, you'll need to build and +install it. To do this:

    +
      +
    1. Go to the directory tools\build\v2\.
    2. +
    3. Run bootstrap.bat
    4. +
    5. Run bjam install --prefix=PREFIX where PREFIX is +the directory where you want Boost.Build to be installed
    6. +
    7. Add PREFIX\bin to your PATH environment variable.
    8. +
    -

    5.3.2   Identify Your Toolset

    +

    5.3.2   Identify Your Toolset

    First, find the toolset corresponding to your compiler in the following table (an up-to-date list is always available in the Boost.Build documentation).

    Note

    If you previously chose a toolset for the purposes of -building bjam, you should assume it won't work and instead +building bjam, you should assume it won't work and instead choose newly from the table below.

    @@ -506,7 +503,7 @@ are using the msvc or gcc toolsets, which have special version detection code) or auto-linking will fail.

    -

    5.3.3   Select a Build Directory

    +

    5.3.3   Select a Build Directory

    Boost.Build will place all intermediate files it generates while building into the build directory. If your Boost root directory is writable, this step isn't strictly necessary: by @@ -514,15 +511,15 @@ default Boost.Build will create a bin.v2/ subd purpose in your current working directory.

    -

    5.3.4   Invoke bjam

    +

    5.3.4   Invoke bjam

    Change your current directory to the Boost root directory and invoke bjam as follows:

    -bjam --build-dir=build-directory toolset=toolset-name --build-type=complete stage
    +bjam --build-dir=build-directory toolset=toolset-name --build-type=complete stage
     

    For a complete description of these and other invocation options, please see the Boost.Build documentation.

    -

    For example, your session might look like this:4

    +

    For example, your session might look like this:4

     C:\WINDOWS> cd C:\Program Files\boost\boost_1_46_0
     C:\Program Files\boost\boost_1_46_0> bjam ^
    @@ -570,7 +567,7 @@ file by appending “>build.log 
    -

    5.4   Expected Build Output

    +

    5.4   Expected Build Output

    During the process of building Boost libraries, you can expect to see some messages printed on the console. These may include

      @@ -594,7 +591,7 @@ look something like:

    -

    5.5   In Case of Build Errors

    +

    5.5   In Case of Build Errors

    The only error messages you see when building Boost—if any—should be related to the IOStreams library's support of zip and bzip2 formats as described here. Install the relevant development @@ -611,7 +608,7 @@ for your compiler to the -

    6   Link Your Program to a Boost Library

    +

    6   Link Your Program to a Boost Library

    To demonstrate linking with a Boost binary library, we'll use the following simple program that extracts the subject lines from emails. It uses the Boost.Regex library, which has a @@ -656,7 +653,7 @@ GCC users should refer to the -

    6.1   Link From Within the Visual Studio IDE

    +

    6.1   Link From Within the Visual Studio IDE

    Starting with the header-only example project we created earlier:

      @@ -670,7 +667,7 @@ e.g. C:\Program Files\boos

      skip to the next step

    -

    6.3   Library Naming

    +

    6.3   Library Naming

    Note

    If, like Visual C++, your compiler supports auto-linking, @@ -703,7 +700,7 @@ following elements:

    Prefix: except on Microsoft Windows, every Boost library name begins with this string. On Windows, only ordinary static libraries use the lib prefix; import libraries and DLLs do -not.6
    +not.6
    boost_regex
    Library name: all boost library filenames begin with boost_.
    -vc71
    @@ -746,7 +743,7 @@ libraries.
    - + @@ -784,7 +781,7 @@ version number, will also be created.
    -

    6.4   Test Your Program

    +

    6.4   Test Your Program

    To test our subject extraction, we'll filter the following text file. Copy it out of your browser and save it as jayne.txt:

    @@ -806,7 +803,7 @@ Spoil Rock Hunter?”

    -

    7   Conclusion and Further Resources

    +

    7   Conclusion and Further Resources

    This concludes your introduction to Boost and to integrating it with your programs. As you start using Boost in earnest, there are surely a few additional points you'll wish we had covered. One day @@ -817,10 +814,8 @@ make this document clearer, please post it to the .

    @@ -835,7 +830,7 @@ mailing list.

    @@ -863,7 +858,7 @@ used in the examples.
    python-debugging=on
    dbuilding a debug version of your code.7building a debug version of your code.7 variant=debug
    p
    [1]We recommend -downloading boost_1_46_0.7z and using 7-Zip to decompress +downloading boost_1_46_0.7z and using 7-Zip to decompress it. We no longer recommend .zip files for Boost because they are twice as large as the equivalent .7z files. We don't recommend using Windows' built-in decompression as it can be painfully slow for large archives.
    -
    [4]

    In this example, the caret character ^ is a +

    [4]

    In this example, the caret character ^ is a way of continuing the command on multiple lines, and must be the final character used on the line to be continued (i.e. do not follow it with spaces). The command prompt responds with @@ -901,7 +896,7 @@ have any source code mechanism for suppressing warnings.

    - @@ -910,7 +905,7 @@ same name.
    [6]This convention distinguishes the static version of +
    [6]This convention distinguishes the static version of a Boost library from the import library for an identically-configured Boost DLL, which would otherwise have the same name.
    -
    [7]These libraries were compiled without optimization +
    [7]These libraries were compiled without optimization or inlining, with full debug symbols enabled, and without NDEBUG #defined. Although it's true that sometimes these choices don't affect binary compatibility with other diff --git a/getting_started/windows.rst b/getting_started/windows.rst index 5e07372..280373c 100644 --- a/getting_started/windows.rst +++ b/getting_started/windows.rst @@ -47,7 +47,7 @@ least install the Static Multithreaded variants of the Boost.Regex_ binaries when given the option. .. _`Boost website version of this Getting Started guide`: - http://www.boost.org/doc/libs/1_36_0/more/getting_started/index.html + http://www.boost.org/more/getting_started/index.html .. _`Boost downloads`: `sf-download`_ .. _installer: http://www.boostpro.com/products/free .. _BoostPro Computing: http://www.boostpro.com