Target .Netstandard 2.0 (#8)

* Fix build on non-windows platform

* Update to netstandard 2.0
Fix build on OSX

* Fix netstandard UWP API usage

* Update README.md

* Fix build

* Fix build

* Fix build on *Nix

* Remove Win stuff on nonwindows

* fix compilation

* Fixes

* Fix
This commit is contained in:
Luis v.d.Eltz
2022-03-06 19:13:33 +01:00
committed by GitHub
parent 2d78b282fc
commit 68d4c265a5
14 changed files with 329 additions and 121 deletions
+20 -12
View File
@@ -1,16 +1,24 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFrameworks>netcoreapp3.1;net5.0-windows10.0.17763.0</TargetFrameworks>
<Nullable>enable</Nullable>
</PropertyGroup>
<!--Note: Dotnet currently does not allow to build on non-windows platforms when a windows TFM is specified-->
<PropertyGroup Condition=" '$(OS)' != 'Windows_NT' ">
<TargetFrameworks>netstandard2.0;net5.0</TargetFrameworks>
</PropertyGroup>
<PropertyGroup Condition=" '$(OS)' == 'Windows_NT' ">
<TargetFrameworks>netstandard2.0;net5.0-windows10.0.17763.0</TargetFrameworks>
</PropertyGroup>
<ItemGroup>
<ProjectReference Include="..\DesktopNotifications.Apple\DesktopNotifications.Apple.csproj" />
<ProjectReference Include="..\DesktopNotifications.FreeDesktop\DesktopNotifications.FreeDesktop.csproj" />
<ProjectReference Include="..\DesktopNotifications.Windows\DesktopNotifications.Windows.csproj" />
<ProjectReference Include="..\DesktopNotifications\DesktopNotifications.csproj" />
</ItemGroup>
<PropertyGroup>
<OutputType>Exe</OutputType>
<Nullable>enable</Nullable>
<LangVersion>8.0</LangVersion>
</PropertyGroup>
</Project>
<ItemGroup>
<ProjectReference Include="..\DesktopNotifications.Apple\DesktopNotifications.Apple.csproj" />
<ProjectReference Include="..\DesktopNotifications.FreeDesktop\DesktopNotifications.FreeDesktop.csproj" />
<ProjectReference Include="..\DesktopNotifications.Windows\DesktopNotifications.Windows.csproj" />
<ProjectReference Include="..\DesktopNotifications\DesktopNotifications.csproj" />
</ItemGroup>
</Project>