First, you need to have the proper PATH, INCLUDE and LIB environment variables in your command shell. For this, call the file "vcvarsall.bat
" (or similar) with parameter:
vcvarsall.bat x86
Next you have to build bjam (you can also download it from the Boost page, but it's almost as quick). Go to the tools\jam\src
folder in Boost and type:
build.bat
It should produce a subfolder bin.ntx86
that contains bjam.exe. For convenience, copy it to the Boost main folder. Next, you can build bcp. Go into the tools\bcp
folder and type:
..\..\bjam.exe --toolset=msvc
Back in the Boost main folder you can then build any library you wish:
bjam toolset=msvc –-with-{library}
where {library}
is one of the libraries to build. All buildable libraries can be shown with:
bjam –-show-libraries
There are many more bjam build parameters. Some parameters with keywords you can specify are:
variant=debug|release
link=shared|static
threading=multi|single
An example would be:
bjam toolset=msvc –-with-filesystem threading=multi variant=debug stage
For more infos, visit the Boost documentation pages.
Edit: Updated link to point to most recent Boost documentation
Edit: Corrected options --with-{library} and –-show-libraries