Issue
I am trying to use the entire CMake workflow from Visual Studio. I created a folder with a CMakeLists.txt
file along with the code, and Visual Studio magically builds and configures it with the parameters I specified in the CMakeLists.txt
file.
However, I can't seem to configure the parameters that I am able to configure from the CMake GUI. I thought that the CMakeSettings.json
file that VS creates when I "Configure" the build would help me override the default settings, but VS still builds with the default parameters, even if I change their values there and save it.
What is the correct way to set the build parameters from Visual Studio?
Solution
I suggest you could refer to the following docs:
Configure and build with CMake Presets in Visual Studio
Customize CMake build settings
Answered By - Jeaninez - MSFT