[CMake] Bug in 2.8 branch (Head branch also)

Michael Wild themiwi at gmail.com
Tue Nov 3 04:21:35 EST 2009


On 3. Nov, 2009, at 2:09 , Steven Wilson wrote:

> Consider the following:
>
> foo.cpp
>
> #include <iostream>
>
> int main()
> {
>    std::cout << "foo" << std::endl;
>    return 0;
> }
>
>
> CMakeLists.txt
>
> cmake_minimum_required(VERSION 2.6.4)
>
> add_executable(foo foo.cpp)
>
> set(BUILD_FOO ON PARENT_SCOPE)
>
>
> With CMake built from the CMake-2-8 branch and also the head  branch  
> of the
> CVS tree, the set(BUILD_FOO ON PARENT_SCOPE) crashes CMake on snow- 
> leopard.
>
> Thanks,
>
> Steve


I can confirm the crash, although it is probably a pretty bad idea to  
use PARENT_SCOPE in the top-level CMakeLists.txt. What would be the  
semantics of that? Ignore it?

Michael


More information about the CMake mailing list