CMakePM: Allow default build configurations for presets

Restrict the build types only if CMAKE_BUILD_TYPE or
CMAKE_CONFIGURATION_TYPES cache variables are set.

Change-Id: Ib88dcd5d4a0fca86f86e95815edff1116f896324
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
This commit is contained in:
Cristian Adam
2022-10-10 19:33:48 +02:00
parent f84bdee045
commit c1667f9bea
3 changed files with 30 additions and 6 deletions

View File

@@ -1985,6 +1985,8 @@ CMakeBuildConfigurationFactory::BuildType CMakeBuildConfigurationFactory::buildT
return BuildTypeRelWithDebInfo;
if (bt == "minsizerel")
return BuildTypeMinSizeRel;
if (bt == "profile")
return BuildTypeProfile;
return BuildTypeNone;
}