浏览代码

cmake-gui: Reset generator platform and toolset on configure (#15411)

At the start of each configure step we already reset the generator
selection (CMAKE_GENERATOR) to match that loaded for the current
project.  Add missing code to reset the generator platform and toolset
(CMAKE_GENERATOR_PLATFORM and CMAKE_GENERATOR_TOOLSET) also so that they
do not leak across projects.
Brad King 10 年之前
父节点
当前提交
1ade687d8d
共有 1 个文件被更改,包括 2 次插入0 次删除
  1. 2 0
      Source/QtDialog/QCMake.cxx

+ 2 - 0
Source/QtDialog/QCMake.cxx

@@ -147,6 +147,8 @@ void QCMake::configure()
   this->CMakeInstance->SetStartOutputDirectory(this->BinaryDirectory.toLocal8Bit().data());
   this->CMakeInstance->SetGlobalGenerator(
     this->CMakeInstance->CreateGlobalGenerator(this->Generator.toLocal8Bit().data()));
+  this->CMakeInstance->SetGeneratorPlatform("");
+  this->CMakeInstance->SetGeneratorToolset("");
   this->CMakeInstance->LoadCache();
   this->CMakeInstance->SetSuppressDevWarnings(this->SuppressDevWarnings);
   this->CMakeInstance->SetWarnUninitialized(this->WarnUninitializedMode);