Boost logo

Boost Interest :

Subject: Re: [Boost-cmake] Possible linker error
From: troy d. straszheim (troy_at_[hidden])
Date: 2009-10-07 12:54:43

motes motes wrote:
> I am trying to build an application using boost with CMake on Ubuntu
> 9.04. This is the content of my CMakeList.txt file:
> IF(Boost_unit_test_framework_LIBRARY)

I think it'd be easier to emulate the way some of the other libraries do
it using the unit test framework. See for instance


where you'll find

   DEPENDS boost_unit_test_framework boost_regex

This will only have effect if BUILD_TESTING is ON. If BUILD_TESTING is
ON, there will be *lots* of tests generated and this could become
cumbersome. You can have cmake build only tests for your library by
adding it to BOOST_TEST_LIBRARIES. e.g. To work on iostreams,
configure like this:


then 'make' in libs/iostreams/test will build my tests, and
'ctest' in that directory will run them. You could play with this and
then copy the approach in your project.

As usual I'm talking about the cmake branch in git.


Boost-cmake list run by bdawes at, david.abrahams at, gregod at, cpdaniel at, john at