Visual Studio 11 support for Boost.Build

I have just submitted patch with update for Boost.Build machinery to properly detect Visual Studio 11 (currently available as Developer Preview).

I have very little experience with Boost.Build v2 internals, so the patch may need further improvements. It works in my environment on Windows 7 (64-bit) with Visual Studio 2010 Express Edition installed alongside the Visual Studio 11 Developer Preview.

If you want to use Visual Studio 11 as Boost.Build toolset, just put the following entry in your user-config.jam file:

using msvc : 11.0 ;

To verify if the toolset is recognised correctly, use b2 debugging options:

b2 --debug-configuration --debug-building --debug-generator buffer.cpp
notice: found boost-build.jam at D:/dev/boost/_svn/trunk/boost-build.jam
notice: loading Boost.Build from D:/dev/boost/_svn/trunk/tools/build/v2
notice: Searching C:\Windows C:\Users\mloskot C:\Users\mloskot D:\dev\boost\_svn\trunk\tools/build/v2 D:/dev/boost/_svn/trunk/tools/build/v2/kernel D:/dev/
boost/_svn/trunk/tools/build/v2/util D:/dev/boost/_svn/trunk/tools/build/v2/build D:/dev/boost/_svn/trunk/tools/build/v2/tools D:/dev/boost/_svn/trunk/tool
s/build/v2/contrib D:/dev/boost/_svn/trunk/tools/build/v2/. for site-config configuration file site-config.jam .
notice: Loading site-config configuration file site-config.jam from D:/dev/boost/_svn/trunk/tools/build/v2/site-config.jam .
notice: Searching C:\Users\mloskot C:\Users\mloskot D:\dev\boost\_svn\trunk\tools/build/v2 D:/dev/boost/_svn/trunk/tools/build/v2/kernel D:/dev/boost/_svn/
trunk/tools/build/v2/util D:/dev/boost/_svn/trunk/tools/build/v2/build D:/dev/boost/_svn/trunk/tools/build/v2/tools D:/dev/boost/_svn/trunk/tools/build/v2/
contrib D:/dev/boost/_svn/trunk/tools/build/v2/. for user-config configuration file user-config.jam .
notice: Loading user-config configuration file user-config.jam from C:/Users/mloskot/user-config.jam .
notice: [msvc-cfg] msvc-11.0 detected, command: 'C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\bin\cl.exe'
notice: [msvc-cfg] msvc-10.0 detected, command: 'C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin\cl.exe'
notice: [msvc-cfg] msvc-10.0express detected, command: 'C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin\cl.exe'
notice: will use 'C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\bin\cl.exe' for msvc, condition <toolset>msvc-11.0
notice: [msvc-cfg] condition: '<toolset>msvc-11.0/<architecture>/<address-model>', setup: 'call "C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\vcv
arsall.bat" x86 >nul
...

and look for the following message reported:

notice: will use 'C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\bin\cl.exe' for msvc, condition <toolset>msvc-11.0

Updating Boost.Build extensions

I’ve been continuing my Boost.Build adventures leading to preparation for review of the new Boost.GIL I/O framework. Here is a short patch with update I had to applie to Boost.Build extensions scripts for the libraries: jpeg-8a, libtiff 3.9.4 and zlib 1.2.4. It is boost-build_extensions-r66346-update.patch

This patch allowed me to successfully compile Boost.GIL tests. It’s been posted to the Boost mailing list, so perhaps it will be integrated with boost_extensions in the Boost Sandbox repository.

Video lecture about CMake

Bill Hoffman from Kitware gives presentation about CMake and a pack of related tools to the happiest easygoing working nation on the Earth:

It’s worth to watch if interested in CMake.

mloskot @ boost regression tests

I run Boost C++ Libraries regression tests for the first time today. The test driver is brilliant. It’s a single python script run.py that takes care of all aspects of regression tests run: gets build system, builds bjam (a clever make equivalent) if not available, grabs Boost source tree, builds Boost libraries, runs tests, combines tests reports to single XML files and uploads it to server in secret location. All this by single command:

python run.py --tag="trunk" --runner="mloskot-x86_64" \
   --toolsets="gcc" --bjam-toolset="gcc" --bjam-options="-j4"

Then, a scheduled magic on the server crunches all uploaded reports and builds detailed summary of regression tests. My builder is called mloskot-x86_64.

That is really a user friendly infrastructure of running regression tests and it allows an average Boost user to contribute in testing.

bjam output in colours

Recently, I’ve been heavily using Boost Build and bjam utility for building GGL library tests on Linux, so I developed a small tool that makes it easier to visually recognize compilation output by printing bjam messages in colours.

The script is called colorbb and was inspired by colormake written by Bjarni R. Einarsson. Actually, I grabbed Bjarni’s two scripts written in Perl and Shell and adopted it to parse bjam output.

colorbb-ggl-build

colorbb is a very simple utility and it likely needs to be improved to properly recognize all bjam messages. It’s available from my SVN repository at http://svn.devjavu.com/mloskot/scripts/colorbb/ personal Git repository at http://github.com/mloskot/.