[CMake] CMake + Ninja + MSVC confusion

Dominic Walsh DWalsh2 at slb.com
Wed Feb 12 12:22:26 EST 2014


Hi

I am trying to use the Ninja generator to compile on a Windows machine using the Visual Studio 11 compilers. 

>From a VS11 console I run cmake (version: 2.8.11.2 ):

cmake -G Ninja -DCMAKE_BUILD_TYPE=Debug -DCMAKE_SYSTEM_NAME=MSVC ..

I then run Ninja (version 1.4.0)

ninja -v 

and all appears well until the final link:
 
[70/70] cmd.exe /c cd . && c:\cygwin\bin\ld.exe /lib /nologo 
 .... <snip>....
/lib: file not recognized: Is a directory
ninja: build stopped: subcommand failed.

Cygwin is in my path but I am surprised that I appear to be using it to Link?

I thought the CMAKE_SYSTEM_NAME setting would have configured the linker?

I am obviously missing something obvious.

Thanks

Dominic Walsh








More information about the CMake mailing list