CsWinRT icon indicating copy to clipboard operation
CsWinRT copied to clipboard

Platform.xml not found

Open fubar-coder opened this issue 1 year ago • 0 comments

Describe the bug

When I try to build a WinUI 3 (C#) project, I get the following error:

EXEC : error : Could not read the Windows SDK's Platform.xml at C:\Program Files (x86)\Windows Kits\10\Platforms\UAP\10.0.19041.0\Platform.xml [D:\Entwicklung\Material.Icons\Material.Icons.WinUI3\Material.Icons.WinUI3.csproj]
C:\Users\fubar\.nuget\packages\microsoft.windows.cswinrt\2.1.1\build\Microsoft.Windows.CsWinRT.targets(290,5): error MSB3073: Der Befehl ""C:\Users\fubar\.nuget\packages\microsoft.windows.cswinrt\2.1.1\cswinrt.exe" @"Generated Files\\CsWinRT\cswinrt.rsp"" wurde mit dem Code 1 beendet. [D:\Entwicklung\Material.Icons\Material.Icons.WinUI3\Material.Icons.WinUI3.csproj]

To Reproduce

  1. git clone https://github.com/fubar-coder/Material.Icons.git
  2. cd .\Material.Icons
  3. git checkout -f a6997f592d344a8947c8a624b7881d9ca88f8524
  4. dotnet build

Expected behavior

It should use find the latest Windows SDK, UAP platform 10.0.22621.0 and should use the ApiContract information in the PreviousPlatforms.xml, //ApplicationPlatform[@version='10.0.19041.0'].

Version Info

  • CsWinRT, 2.1.1
  • .NET 8.0.401
  • Windows SDK 10, UAP Platform 10.0.22621.0

Additional context

First reported here: microsoft/microsoft-ui-xaml#9959

fubar-coder avatar Sep 07 '24 12:09 fubar-coder