New in version 3.4.
Visual Studio Windows Target Platform Version.
When targeting Windows 10 and above, Visual Studio Generators for VS 2015 and above support specification of a Windows SDK version:
Otherwise, if the
WindowsSDKVersionenvironment variable is set to an available SDK version, that version is selected. This is intended for use in environments established by
vcvarsall.bator similar scripts.
New in version 3.27: This is enabled by policy
CMAKE_SYSTEM_VERSIONis set to an available SDK version, that version is selected.
Changed in version 3.27: This is disabled by policy
Otherwise, CMake uses the latest Windows SDK version available.
The chosen Windows target version number is provided
CMAKE_VS_WINDOWS_TARGET_PLATFORM_VERSION. If no Windows 10 SDK
is available this value will be empty.
One may set a
CMAKE_WINDOWS_KITS_10_DIR environment variable
to an absolute path to tell CMake to look for Windows 10 SDKs in
a custom location. The specified directory is expected to contain