Skip to content
This repository has been archived by the owner on Jul 5, 2024. It is now read-only.

Commit

Permalink
Add targeting for net461, netstandard, net6
Browse files Browse the repository at this point in the history
  • Loading branch information
caesay committed Dec 31, 2021
1 parent eaf7029 commit e70686d
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
2 changes: 2 additions & 0 deletions src/Squirrel/Internal/ResourceUpdater.cs
Original file line number Diff line number Diff line change
Expand Up @@ -187,10 +187,12 @@ protected override bool ReleaseHandle()
/// </summary>
public static bool IsSupportedOS()
{
#if NETSTANDARD2_0_OR_GREATER || NET5_0_OR_GREATER
if (!RuntimeInformation.IsOSPlatform(OSPlatform.Windows))
{
return false;
}
#endif

try
{
Expand Down
12 changes: 10 additions & 2 deletions src/Squirrel/Squirrel.csproj
Original file line number Diff line number Diff line change
@@ -1,15 +1,17 @@
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>netstandard2.0</TargetFramework>
<TargetFrameworks>net461;netstandard2.0;net6.0</TargetFrameworks>
<Description>Squirrel</Description>
<Title>Squirrel</Title>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<AssemblyName>SquirrelLib</AssemblyName>
<GenerateDocumentationFile>true</GenerateDocumentationFile>
<DebugType>embedded</DebugType>
<DebugSymbols>true</DebugSymbols>
<PackageId>sqbuild</PackageId>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
</PropertyGroup>

<ItemGroup>
Expand All @@ -18,4 +20,10 @@
<PackageReference Include="System.IO.Packaging" Version="5.0.0" />
</ItemGroup>

<ItemGroup Condition=" $(TargetFramework.StartsWith('net461')) ">
<PackageReference Include="System.ValueTuple" Version="4.5" />
<Reference Include="System.Web" />
<Reference Include="System.Net.Http" />
</ItemGroup>

</Project>

0 comments on commit e70686d

Please sign in to comment.