Skip to content

Commit

Permalink
Merge 5b2be5e into 42568b8
Browse files Browse the repository at this point in the history
  • Loading branch information
dep5 authored Jan 8, 2022
2 parents 42568b8 + 5b2be5e commit 41b6dda
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 8 deletions.
2 changes: 0 additions & 2 deletions tests/compiletests.run.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@ set SOURCE_DIR=%~dp0compiletests
:: find generic tools
if not defined CMD_VSWHERE call %~dp0..\tools\find-tools.bat

set /a NUM_VSVERSION_NEXT=NUM_VSVERSION + 1

if not exist "%CMD_CMAKE%" (
echo "no cmake found."
exit /b 1
Expand Down
2 changes: 1 addition & 1 deletion tests/compiletests.targets
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
</PropertyGroup>
<SetEnv name="platform" value="$(Platform)" prefix="false" />
<SetEnv name="configuration" value="$(Configuration)" prefix="false" />
<SetEnv name="NUM_VSVERSION" value="$(VsVersion)" prefix="false" />
<SetEnv name="ARG_VSVERSION" value="$(VsVersion)" prefix="false" />
<Exec Command="$(MSBuildThisFileDirectory)compiletests.run.cmd &quot;$(CompileTestBuildDir)&quot;" ConsoleToMSBuild="true" />
</Target>
<Target Name="AppendCleanTargetsForCompileTest" BeforeTargets="CoreClean">
Expand Down
2 changes: 1 addition & 1 deletion tests/googletest.targets
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
</PropertyGroup>
<SetEnv name="platform" value="$(Platform)" prefix="false" />
<SetEnv name="configuration" value="$(Configuration)" prefix="false" />
<SetEnv name="NUM_VSVERSION" value="$(VsVersion)" prefix="false" />
<SetEnv name="ARG_VSVERSION" value="$(VsVersion)" prefix="false" />
<Exec Command="$(MSBuildThisFileDirectory)googletest.build.cmd &quot;$(GoogleTestBuildDir)&quot; &quot;$(GoogleTestInstallDir)&quot;" ConsoleToMSBuild="true" />
</Target>
<Target Name="AppendCleanTargetsForGoogleTest" BeforeTargets="CoreClean">
Expand Down
11 changes: 7 additions & 4 deletions tools/find-tools.bat
Original file line number Diff line number Diff line change
Expand Up @@ -154,10 +154,9 @@ exit /b
::
:: ARG_VSVERSION
:: latest => the latest version of installed Visual Studio
:: 2017 => Visual Studio 2017
:: 2019 => Visual Studio 2019
:: 15 => Visual Studio 2017
:: 16 => Visual Studio 2019
:: 2017 or 15 => Visual Studio 2017
:: 2019 or 16 => Visual Studio 2019
:: 2022 or 17 => Visual Studio 2022
:: ---------------------------------------------------------------------------------------------------------------------
:msbuild
:: convert productLineVersion to Internal Major Version
Expand All @@ -167,6 +166,8 @@ exit /b
set NUM_VSVERSION=15
) else if "%ARG_VSVERSION%" == "2019" (
set NUM_VSVERSION=16
) else if "%ARG_VSVERSION%" == "2022" (
set NUM_VSVERSION=17
) else if "%ARG_VSVERSION%" == "latest" (
call :check_latest_installed_vsversion
) else (
Expand All @@ -185,6 +186,8 @@ exit /b
set CMAKE_G_PARAM=Visual Studio 15 2017
) else if "%NUM_VSVERSION%" == "16" (
set CMAKE_G_PARAM=Visual Studio 16 2019
) else if "%NUM_VSVERSION%" == "17" (
set CMAKE_G_PARAM=Visual Studio 17 2022
) else (
call :set_cmake_gparam_automatically
)
Expand Down
6 changes: 6 additions & 0 deletions vcx-props/vcxcompat.props
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,16 @@
<PropertyGroup Label="Globals" Condition="'$(VisualStudioVersion)' == '16.0'">
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
</PropertyGroup>
<PropertyGroup Label="Globals" Condition="'$(VisualStudioVersion)' == '17.0'">
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
</PropertyGroup>
<PropertyGroup Label="Configuration" Condition="'$(VisualStudioVersion)' == '15.0'">
<PlatformToolset>v141</PlatformToolset>
</PropertyGroup>
<PropertyGroup Label="Configuration" Condition="'$(VisualStudioVersion)' == '16.0'">
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Label="Configuration" Condition="'$(VisualStudioVersion)' == '17.0'">
<PlatformToolset>v143</PlatformToolset>
</PropertyGroup>
</Project>

0 comments on commit 41b6dda

Please sign in to comment.