[question] CMakeToolchain in combination with visual studio won't allow the Ninja generator?
See original GitHub issueI want to use the CMakePresets with Visual studio 2022 and use a native CMake project with Ninja generator.
However, using CMakeToolchain, I am unable to get the Ninja generator. The CMakePresets.json always has the Visual Studio generator, even with [conf] tools.cmake.cmaketoolchain:generator=Ninja
and/or [general] cmake_generator = Ninja
.
I tried, conan 1.50, 1.51 and 1.52.beta but with all the same result. Is it possible to enable Ninja and how should that be done?
(I tried to change it manually to Ninja, but in that case cmake fails with a platform error).
- [ x] I’ve read the CONTRIBUTING guide.
Issue Analytics
- State:
- Created a year ago
- Comments:8 (4 by maintainers)
Top Results From Across the Web
CMake integration with Ninja generator fails to find the right ...
When I switch the generator using the CMakeSettings.json to Visual Studio 15 2017 everything works as expected but Ninja doesn't.
Read more >Configure and build with CMake Presets in Visual Studio
Use external with command-line generators like Ninja. These values allow vendors like Visual Studio to supply the required environment before ...
Read more >vscode-cmake-tools/support - Gitter
preferredGenerators": ["Ninja"],. but when I call "build" in Visual Studio Code, it tries to configure the project again, invalidates the CMake cache and...
Read more >Question about Visual Studio Community configuration
Are you aware of the emcmake wrapper tool, and the cmake toolchain file in the Emscripten SDK? Those can help with building cmake...
Read more >Visual Studio, CMake and Toolchain Files - Stack Overflow
Minor comment please limit questions to 1 question in the future. Multiple questions clutters questions and makes search results worse.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
The configuration in
conan.conf
is not used by the new generators, only the one fromglobal.conf
and profiles[conf]
.conan.conf
dissapears in 2.0, it is recommended to migrate toglobal.conf
configuration.Thanks