I am using CMake to build a cross-platform (e.g. Linux/Windows) application which uses also thirdparty libraries as external projects.
I'm aware of the fact that MSVC is a multi-configuration environment, hence CMAKE_BUILD_TYPE is not used, instead it uses the CMAKE_CONFIGURATION_TYPES set to build every possible configuration.
I'm also aware of the fact that instead of providing a configuration at configuration type (e.g. cmake -DCMAKE_BUILD_TYPE ..) I need to provide the configuration at build type (cmake --build . --config Release)
See https://stackoverflow.com/questions/24460486/cmake-build-type-not-being-used-in-cmakelists-txt]
What I completely fail to understand is:
I don't want multi-configuration builds. I want to build either Debug or Release- but only one of them in the generated buildsystem. Can I achieve that with CMake + multi-config generator (like MSVC or Ninja Multi-Config) + ExternalProject projects? If yes, how?