Skip to content

Windows Ninja build fails with 'C:\Program' is not recognized as an internal or external command #1292

@juandemanjon

Description

@juandemanjon

In a Windows environment where Ninja binary is a path with spaces the build fails and the error messages is:
'C:\Program' is not recognized as an internal or external command

The fix is pretty straight forward, just wrapping the %NINJA% call with quotes, which I am going to send a PR

Steps to reproduce
To reproduce it, ninja has to be in a path with spaces. In my environment I have:

where ninja
C:\ProgramData\chocolatey\bin\ninja.exe
C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\Common7\IDE\CommonExtensions\Microsoft\CMake\Ninja\ninja.exe

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions