Can WPF applications be run in Linux or Mac with .Net Core 3?

LinuxWpf.Net CoreDesktop Application.Net Core-3.0

Linux Problem Overview


Microsoft announced .NET Core 3 comes with WPF and Windows Forms. So can I create a desktop application for Linux or Mac using .NET Core 3?

Linux Solutions


Solution 1 - Linux

No, they have clearly stated that these are windows only. In one of the .NET Core 3.0 discussions, they have also clarified that they do not intend to make these features cross-platform in the future since the whole concept is derived from windows specific features. They talked about thinking of a whole new idea for cross-platform applications, which is not easy.

Source: https://youtu.be/HNLZQeu05BY

Update

The newly announced .NET 5 now aims in avoiding all this confusion by no longer calling it ".NET Core".

Update 2

With blazor client-side (releases on may, 2020), there is a new experimental project for cross-platform apps using webview that is in the works.

Source: https://blog.stevensanderson.com/2019/11/01/exploring-lighter-alternatives-to-electron-for-hosting-a-blazor-desktop-app/

Solution 2 - Linux

No with WPF or Winforms. But you still can develop desktop apps on Linux, with .NET Core, using other libs like GtkSharp or Avalonia

Solution 3 - Linux

Well, the name itself says Windows Presentation Foundation. So it's primarily windows based.

But it is worth to be noted that the new UI framework, .NET MAUI that will be shipped with .NET 6 is cross-platform, with a single-codebase, single-project structure.

Currently in Preview at the time of writing, to be shipped in November 2021. Here's the roadmap.

Solution 4 - Linux

Although it is not native dotnet core on linux, but it may be helpful - using wine.

I find a very useful comment in the discussion here, more details here

In other words, it is possible to use windows version of dotnet core under wine.

I didn't try it yet, but from the article I mentioned I can say it looks nice and might be an option.

Attributions

All content for this solution is sourced from the original question on Stackoverflow.

The content on this page is licensed under the Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.

Content TypeOriginal AuthorOriginal Content on Stackoverflow
QuestionsiyadView Question on Stackoverflow
Solution 1 - LinuxNeville NazeraneView Answer on Stackoverflow
Solution 2 - LinuxThiago JediView Answer on Stackoverflow
Solution 3 - LinuxXpleriaView Answer on Stackoverflow
Solution 4 - LinuxViktor ArsanovView Answer on Stackoverflow