cmake fails to build external msproject with MAP_IMPORTED_CONFIG_<CONFIG>
I have a project that includes external Visual Studio project using include_external_msproject(libname mylib.vcxproj)
. Unfortunately, mylib defines different build configurations and I need to map them to cmake default build types (Release, Debug, etc.) using set_target_properties(libname PROPERTIES MAP_IMPORTED_CONFIG_DEBUG MYLIB_DEBUG)
.
The problem that I have with that approach is that I can't build such project using cmake --build .
because generated .vcxproj files doesn't contain the mapping I defined. As far as I understand, this information is present in .sln file, which can't be built using cmake --build . <options>
command.