Paket
Paket copied to clipboard
Paket 7 in multi-target repo fails with: 'Windows is required to build Windows desktop applications.'
Description
In a solution with separate macOS and Windows Desktop projects, paket install now fails with errors such as:
/usr/local/share/dotnet/sdk/6.0.300/Sdks/Microsoft.NET.Sdk/targets/Microsoft.NET.Sdk.FrameworkReferenceResolution.targets(90,5): error NETSDK1100: Windows is required to build Windows desktop applications. [/Users/jwostenberg/Code/Interstellar/src/Interstellar.Wpf.Chromium/Interstellar.Wpf.Chromium.fsproj]
/usr/local/share/dotnet/sdk/6.0.300/Sdks/Microsoft.NET.Sdk/targets/Microsoft.NET.Sdk.FrameworkReferenceResolution.targets(90,5): error NETSDK1100: Windows is required to build Windows desktop applications. [/Users/jwostenberg/Code/Interstellar/Examples/Examples.Wpf.Chromium/Examples.Wpf.Chromium.fsproj]
/usr/local/share/dotnet/sdk/6.0.300/Sdks/Microsoft.NET.Sdk/targets/Microsoft.NET.Sdk.FrameworkReferenceResolution.targets(90,5): error NETSDK1100: Windows is required to build Windows desktop applications. [/Users/jwostenberg/Code/Interstellar/src/Interstellar.WinForms.Chromium/Interstellar.WinForms.Chromium.fsproj]
/usr/local/share/dotnet/sdk/6.0.300/Sdks/Microsoft.NET.Sdk/targets/Microsoft.NET.Sdk.FrameworkReferenceResolution.targets(90,5): error NETSDK1100: Windows is required to build Windows desktop applications. [/Users/jwostenberg/Code/Interstellar/Examples/Examples.WinForms.Chromium/Examples.WinForms.Chromium.fsproj]
Total time taken: 10 milliseconds
Paket failed with
-> dotnet restore "Interstellar.Windows.sln" failed
Repro steps
- Have a repo with two solutions and two projects
1a.
MyProject.Windows.slnwhich containsMyProject.Windows.fsprojwith a TFM ofnet6.0-windows1b.MyProject.macOS.slnwhich containsMyProject.macOS.fsprojwith a TFM ofnet6.0-macos - On macOS, try to do a
dotnet paket install
Expected behavior
paket install should work and not fail
Actual behavior
Paket blows up
Known workarounds
Downgrade to Paket 6.0.13.