summaryrefslogtreecommitdiffstats
path: root/Source/cmGlobalVisualStudio14Generator.h
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2023-04-03 14:11:49 (GMT)
committerBrad King <brad.king@kitware.com>2023-04-05 16:06:22 (GMT)
commit2f3d945f8382fef4139c7d0c3879f6ff2f3756a0 (patch)
treefc31f53ed3169a2b1d0755f190ec945ca48cc896 /Source/cmGlobalVisualStudio14Generator.h
parentf0a67b629192466cec463c41df56ef3244817f70 (diff)
downloadCMake-2f3d945f8382fef4139c7d0c3879f6ff2f3756a0.zip
CMake-2f3d945f8382fef4139c7d0c3879f6ff2f3756a0.tar.gz
CMake-2f3d945f8382fef4139c7d0c3879f6ff2f3756a0.tar.bz2
VS: Add CMAKE_GENERATOR_PLATFORM field to control Windows SDK selection
Add a `version=` field to explicitly control the SDK version selection without relying on `CMAKE_SYSTEM_VERSION`. Fixes: #16713
Diffstat (limited to 'Source/cmGlobalVisualStudio14Generator.h')
-rw-r--r--Source/cmGlobalVisualStudio14Generator.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/Source/cmGlobalVisualStudio14Generator.h b/Source/cmGlobalVisualStudio14Generator.h
index 0f016b3..f59a323 100644
--- a/Source/cmGlobalVisualStudio14Generator.h
+++ b/Source/cmGlobalVisualStudio14Generator.h
@@ -7,6 +7,8 @@
#include <memory>
#include <string>
+#include <cm/optional>
+
#include "cmGlobalVisualStudio12Generator.h"
class cmGlobalGeneratorFactory;
@@ -39,6 +41,12 @@ protected:
bool IsWindowsStoreToolsetInstalled() const;
bool InitializePlatformWindows(cmMakefile* mf) override;
+ bool VerifyNoGeneratorPlatformVersion(
+ cmMakefile* mf,
+ cm::optional<std::string> reason = cm::nullopt) const override;
+
+ bool ProcessGeneratorPlatformField(std::string const& key,
+ std::string const& value) override;
// Used to adjust the max-SDK-version calculation to accommodate user
// configuration.
@@ -62,4 +70,6 @@ protected:
private:
class Factory;
friend class Factory;
+
+ cm::optional<std::string> GeneratorPlatformVersion;
};