[CMake] CTest and CMakeCache.txt

Marcel Loose loose at astron.nl
Tue Mar 17 05:23:50 EDT 2009


Hi all,

Following section 10.5 in "Mastering CMake" and the example in the Tests
directory of the CMake source distribution, I was trying to setup a
separate build stage for test programs for our project.

The reason for doing so is, that I want to separate compiling the source
files from compiling/linking the test files, since this will save time
during development.

However, I got stuck when CTest tries to run CMake. I use a couple of
CMake modules that are stored in <project-root-dir>/CMake, which CTest
cannot find. Furthermore, when CMake runs it stores some crucial
variables in the cache. But, ... when CTest starts CMake, it fails to
check the cache, and so it doesn't read the required variables from the
cache.

Am I missing something here?

Best regards,
Marcel Loose.



More information about the CMake mailing list