[CMake] changing CMAKE_FILES_DIRECTORY

naryniecki naryniecki at o2.pl
Tue Jul 27 03:44:34 EDT 2010


hi,
I have problem with changing this variable.
I have directory structure as follow:
root_dir
 sources
 build
 conf1
 conf2
I have CMakeLists.txt placed in root_dir. I need to build my project in 2 configuration (conf1 and conf2) and want all cmake-files where generated to conf1 or conf2. I want to be able to run cmake from root_dir. CMAKE_FILES_DIRECTORY is set as directory in which I run cmake, so I have CMakeFiles generated in root_dir. When I put set(CMAKE_FILES_DIRECTORY /build/conf1/${CMAKE_FILES_DIRECTORY}) on the begging of CMakeLists.txt I got to 2 CMakeFiles directory: one in root_dir and one in root_dir/build/conf1 and cmake fails while TRY_COMPILE. this is because he look for some temporary file in root_dir/build/conf1 and they are in root_dir.
How can I change it?
br.
marek
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20100727/cca11580/attachment.htm>


More information about the CMake mailing list