[cmake-developers] -GNinja on Windows

Bill Hoffman bill.hoffman at kitware.com
Fri Jun 8 14:19:08 EDT 2012


On 6/8/2012 2:02 PM, Peter Kümmel wrote:

>>
>> I just tried to run an experimental dashboard and it failed.
>>
>> I think it was because my cmake build had a space in the path:
>>
>>
>> command = C:/Users/hoffman/Work/My
>> Builds/cmake-gmake/bin/cmcldeps.exe $in $out.d $out "Note: including
>> file: " C:\PROGRA~2\MICROS~1.0\VC\bin\cl.exe /nologo $FLAGS $DEFINES
>> /Fo$out /Fd$TARGET_PDB -c $in
>> description = Building C object $out
>>
>>
>> ninja gives this:
>>
>> $ ../ninja/ninja
>> [1/437] Building C object
>> Utilities\KWIML\test\CMakeFiles\cmIML_test.dir\test.c.obj
>> ninja: FATAL: CreateProcess: %1 is not a valid Win32 application.
>>
>
> Dependency parsing is a bit hairy. It also breaks on '(', e.g. "Program
> Files(x86)".
> Could you have a look at the .d files?
> Best place to debug this is a printf here:
> https://github.com/syntheticpp/ninja/blob/master/src/graph.cc#L85
>

It is not getting that far.  It is not even running cmcldeps.  :)
The command= line is bad, so nothing builds, and we get no .d files.

>
> I also found that CMAKE_CL_SHOWINCLUDE_PREFIX is not set for different
> CMakeLists.txt. I assume Windows-cl.cmake is the wrong place for it.
>
> How can I make CMAKE_CL_SHOWINCLUDE_PREFIX as visible as CMAKE_C_COMPILER?
>
I think it is going to have to go into CMakeCXXPlatform.cmake that gets 
configured just before the code you just added.

-Bill



More information about the cmake-developers mailing list