[CMake] Broken Cmake Behavior using --build VS2010
J Decker
d3ck0r at gmail.com
Wed Dec 14 18:26:11 EST 2011
visual studio 2010; cmake latest....
cmake .. - generates a .sln file that is comprised of the last project
in the top level.
cmake --build . - tries to build the .sln that is comprised of the
first 'project' command that is encountered in the script.
If I reverse the project and include lines in the root cmakelists.txt
file; then the results are reversed.
----- CMakeLists.txt ----
include( other.txt )
project( this_root )
----- other.txt ---
project( other_root )
------ doit.bat ------
cmake -G "Visual Studio 10" ..
cmake --build .
----------- The Output -------------------
M:\tst\cmake\build>doit.bat
M:\tst\cmake\build>cmake -G "Visual Studio 10" ..
-- Check for working C compiler using: Visual Studio 10
-- Check for working C compiler using: Visual Studio 10 -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler using: Visual Studio 10
-- Check for working CXX compiler using: Visual Studio 10 -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Configuring done
-- Generating done
-- Build files have been written to: M:/tst/cmake/build
M:\tst\cmake\build>cmake --build .
Microsoft (R) Visual Studio Version 10.0.30319.1.
Copyright (C) Microsoft Corp. All rights reserved.
The following files were specified on the command line:
other_root.sln
These files could not be found and will not be loaded.
----------------------------------------------
More information about the CMake
mailing list