Boost logo

Boost :

From: Maik Beckmann (maikbeckmann_at_[hidden])
Date: 2007-08-16 18:25:36


Am Donnerstag, 16. August 2007 22:42:02 schrieb Larry Evans:

> I assume the CMAKE_CXX_FLAGS:STRING value from
> the CMakeCache.txt is used since I saw the error message when
> make was run:
>
> Scanning dependencies of target boost_iostreams-shared
> [ 2%] Building CXX object
> libs/iostreams/src/CMakeFiles/boost_iostreams-shared.dir/file_descriptor.o
> cc1plus: error: unrecognized command line option "-std=gnu++0x"
> make[2]: ***
> [libs/iostreams/src/CMakeFiles/boost_iostreams-shared.dir/file_descriptor.o
>]

This means the compiler which was picked by CMake isn't aware of this option,
so you should delete CMakeCache.txt and run CMake again with the right CXX.

>
> > This behavior of CMake ensures that the results of the test CMake runs on
> > the compiler are allway valid. Since the results are stored in
> > CMakeLists.txt,
>
> Which CMakeLists.txt? The following command:
>
> cd ~/prog_dev/boost-svn/ro/sandbox-branches/boost-cmake/src/
> find . -name CMakeLists.txt -ls
> 5181833 12 -rw-r--r-- 1 evansl evansl 10169 Aug 13 16:16
> ./libs/config/test/CMakeLists.txt
> ...

Argh, sorry for the confusion. This
" results are stored in CMakeLists.txt "
should be
" results are stored in CMakeCache.txt "

A CMakeLists.txt is allways written by the user, CMake only reads but never
writes to them.

> > you have to remove it, which triggers CMake to rerun the compiler tests.
> Does 'it' refer to CMakeLists.txt or CMakeCache.txt?
CMakeCache.txt!

Maik


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk