summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Misc/NEWS.d/next/Build/2021-06-30-02-32-46.bpo-44535.M9iN4-.rst1
-rw-r--r--PCbuild/python.props1
2 files changed, 2 insertions, 0 deletions
diff --git a/Misc/NEWS.d/next/Build/2021-06-30-02-32-46.bpo-44535.M9iN4-.rst b/Misc/NEWS.d/next/Build/2021-06-30-02-32-46.bpo-44535.M9iN4-.rst
new file mode 100644
index 0000000000..e06d0d3048
--- /dev/null
+++ b/Misc/NEWS.d/next/Build/2021-06-30-02-32-46.bpo-44535.M9iN4-.rst
@@ -0,0 +1 @@
+Enable building using a Visual Studio 2022 install on Windows.
diff --git a/PCbuild/python.props b/PCbuild/python.props
index 4a56d50b8b..60625101b4 100644
--- a/PCbuild/python.props
+++ b/PCbuild/python.props
@@ -11,6 +11,7 @@
We set BasePlatformToolset for ICC's benefit, it's otherwise ignored.
-->
+ <BasePlatformToolset Condition="'$(BasePlatformToolset)' == '' and ('$(MSBuildToolsVersion)' == '17.0' or '$(VisualStudioVersion)' == '17.0')">v142</BasePlatformToolset>
<BasePlatformToolset Condition="'$(BasePlatformToolset)' == '' and ('$(MSBuildToolsVersion)' == '16.0' or '$(VisualStudioVersion)' == '16.0')">v142</BasePlatformToolset>
<BasePlatformToolset Condition="'$(BasePlatformToolset)' == '' and ('$(MSBuildToolsVersion)' == '15.0' or '$(VisualStudioVersion)' == '15.0')">v141</BasePlatformToolset>
<BasePlatformToolset Condition="'$(BasePlatformToolset)' == '' and '$(VCTargetsPath14)' != ''">v140</BasePlatformToolset>