Browse Source

Update the UniversalWindowsPlatformTargetFrameworks condition to ensure the correct Windows Kit version is installed

pull/2047/head
Kévin Chalet 2 years ago
parent
commit
2588fea242
  1. 10
      Directory.Build.props

10
Directory.Build.props

@ -61,13 +61,15 @@
</NetStandardTargetFrameworks>
<!--
Note: the UWP/.NET Core 5.0 reference assemblies may not be available if the Windows SDK is not installed.
To ensure the solution can be built on machines that don't have UWP tooling installed, a directory check is
used to ensure the .NET Core 5.0 reference assemblies are present on the machine before targeting uap10.0.
Note: the .NET Core 5.0 reference assemblies or UWP contract assemblies may not be available if
the Windows SDK is not installed (or if a different version is installed). To ensure the solution
can be built on machines that don't have the UWP tooling installed, directory checks are used to
ensure the reference and contract assemblies are present on the machine before targeting uap10.0.
-->
<UniversalWindowsPlatformTargetFrameworks
Condition=" '$(UniversalWindowsPlatformTargetFrameworks)' == '' And $([MSBuild]::IsOSPlatform('Windows')) And
('$(GITHUB_ACTIONS)' == 'true' Or Exists('$(MSBuildProgramFiles32)\Reference Assemblies\Microsoft\Framework\.NETCore\v5.0')) ">
('$(GITHUB_ACTIONS)' == 'true' Or (Exists('$(MSBuildProgramFiles32)\Reference Assemblies\Microsoft\Framework\.NETCore\v5.0') And
Exists('$(MSBuildProgramFiles32)\Windows Kits\10\References\10.0.17763.0'))) ">
uap10.0.17763
</UniversalWindowsPlatformTargetFrameworks>
</PropertyGroup>

Loading…
Cancel
Save