Pavel Shevaev wrote:
Can you create a complete but small example that shows the problem?

Ok, I tried to extract the minimal non-working example from my CMakeLists.txt.

foo/CMakeLists.txt:
==============================================
cmake_minimum_required(VERSION 2.6 FATAL_ERROR)
project(foo)

enable_testing()
include(CTest)
add_test(test test)

add_subdirectory(${foo_SOURCE_DIR}/../shared/lib/boost ${foo_BINARY_DIR})
==============================================

The problem is in the add_subdirectory call. You can not specify ${foo_BINARY_DIR} as a directory as it is already in use. We are working on a fix that will report this as an error. Basically what happens is the test file gets written correctly, then overwritten with nothing from the shared/lib/boost build directory that is told to go into the same directory.

So,  this should fix the problem:

add_subdirectory(${foo_SOURCE_DIR}/../shared/lib/boost boost_lib)

-Bill
_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake

Reply via email to