From: Maik Beckmann (maikbeckmann_at_[hidden])
Date: 2007-08-16 14:42:19
Am Donnerstag, 16. August 2007 20:10:48 schrieb Larry Evans:
> I tried this by creating a top-level build directory, built-by, with
> g++-4.1 #the "regular" compiler
> g++-4.3_v #the "variadic" compiler
> For 4.3_v, I had to first do `cmake <path-to-source>` then edit the
> g++-4.3_v/CMakeCache.txt to include the lines:
> //CXX compiler.
> //Flags used by the compiler during all build types.
> The FLAGS value was needed, as you know, to enable variadic templates.
> However, after I tried `make` the value of COMPILER:FILEPATH was
> reverted back to /usr/bin/g++ by something. How can that reversion be
> prevented or is there a better way to cause the variadic compiler to be
If you want to say CMake which compiler it has to use, you must give it via
the matching environment variable (CXX for the c++ compiler, CC for c, FC for
$ cd /path/to/builddir
Note: you have to remove CMakeCache.txt, if it exists.
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,
you have to remove it, which triggers CMake to rerun the compiler tests.
Regards, Maik Beckmann
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk