Skip to content

Commit bbea53f

Browse files
committed
Add .net core 2.0 support
1 parent d8149b9 commit bbea53f

File tree

4 files changed

+21
-24
lines changed

4 files changed

+21
-24
lines changed

samples/Exceptionless.SampleWebApi/App.config

Lines changed: 1 addition & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -9,26 +9,6 @@
99
</settings>
1010
</exceptionless>
1111
<startup>
12-
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5.2" />
12+
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6.2" />
1313
</startup>
14-
<runtime>
15-
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
16-
<dependentAssembly>
17-
<assemblyIdentity name="Microsoft.Owin" publicKeyToken="31bf3856ad364e35" culture="neutral" />
18-
<bindingRedirect oldVersion="0.0.0.0-3.0.1.0" newVersion="3.0.1.0" />
19-
</dependentAssembly>
20-
<dependentAssembly>
21-
<assemblyIdentity name="System.Web.Http" publicKeyToken="31bf3856ad364e35" culture="neutral" />
22-
<bindingRedirect oldVersion="0.0.0.0-5.2.3.0" newVersion="5.2.3.0" />
23-
</dependentAssembly>
24-
<dependentAssembly>
25-
<assemblyIdentity name="System.Net.Http.Formatting" publicKeyToken="31bf3856ad364e35" culture="neutral" />
26-
<bindingRedirect oldVersion="0.0.0.0-5.2.3.0" newVersion="5.2.3.0" />
27-
</dependentAssembly>
28-
<dependentAssembly>
29-
<assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" />
30-
<bindingRedirect oldVersion="0.0.0.0-9.0.0.0" newVersion="9.0.0.0" />
31-
</dependentAssembly>
32-
</assemblyBinding>
33-
</runtime>
3414
</configuration>

src/Exceptionless/Exceptionless.csproj

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<AssemblyTitle>Exceptionless client for non visual (ie. Console and Services) applications.</AssemblyTitle>
88
<Description>Exceptionless client for portable applications. $(Description)</Description>
99
<PackageTags>Exceptionless;Error;Report;Reporting;Exception;Logging;Log;ELMAH;pcl;NETSTANDARD;Core</PackageTags>
10-
<TargetFrameworks>netstandard1.2;netstandard1.3;netstandard1.4;netstandard1.5;portable46-net451+win81+wpa81;net45</TargetFrameworks>
10+
<TargetFrameworks>netstandard1.2;netstandard1.3;netstandard1.4;netstandard1.5;netstandard2.0;portable46-net451+win81+wpa81;net45</TargetFrameworks>
1111
</PropertyGroup>
1212

1313
<ItemGroup Label="Package">
@@ -109,6 +109,15 @@
109109
<PackageReference Include="System.Xml.XmlSerializer" Version="4.3.0" />
110110
</ItemGroup>
111111

112+
<PropertyGroup Condition="'$(TargetFramework)' == 'netstandard2.0'" Label="Build">
113+
<DefineConstants>$(DefineConstants);NO_SQL_CLIENT;NETSTANDARD;NETSTANDARD2_0</DefineConstants>
114+
</PropertyGroup>
115+
116+
<ItemGroup Condition="'$(TargetFramework)' == 'netstandard2.0'" Label="Package References">
117+
<PackageReference Include="Microsoft.Extensions.PlatformAbstractions" Version="1.1.0" />
118+
<PackageReference Include="System.Reflection.Emit.Lightweight" Version="4.3.0" />
119+
</ItemGroup>
120+
112121
<PropertyGroup Condition="'$(TargetFramework)' == 'portable46-net451+win81+wpa81'" Label="Build">
113122
<TargetFrameworkIdentifier>.NETPortable</TargetFrameworkIdentifier>
114123
<TargetFrameworkVersion>v4.6</TargetFrameworkVersion>

src/Exceptionless/Newtonsoft.Json/Serialization/JsonTypeReflector.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -389,7 +389,7 @@ public static bool DynamicCodeGeneration
389389
{
390390
if (_dynamicCodeGeneration == null)
391391
{
392-
#if !(DOTNET || PORTABLE40 || PORTABLE || NETSTANDARD1_0 || NETSTANDARD1_1 || NETSTANDARD1_2 || NETSTANDARD1_3 || NETSTANDARD1_4 || NETSTANDARD1_5)
392+
#if !(DOTNET || PORTABLE40 || PORTABLE || NETSTANDARD1_0 || NETSTANDARD1_1 || NETSTANDARD1_2 || NETSTANDARD1_3 || NETSTANDARD1_4 || NETSTANDARD1_5 || NETSTANDARD2_0)
393393
try
394394
{
395395
new ReflectionPermission(ReflectionPermissionFlag.MemberAccess).Demand();

src/Platforms/Exceptionless.AspNetCore/Exceptionless.AspNetCore.csproj

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<AssemblyTitle>Exceptionless client for ASP.NET Core</AssemblyTitle>
88
<Description>Exceptionless client for ASP.NET Core. $(Description)</Description>
99
<PackageTags>ASP.NET;Exceptionless;Error;Report;Reporting;Exception;Logging;Log;ELMAH</PackageTags>
10-
<TargetFrameworks>netstandard1.5;net451</TargetFrameworks>
10+
<TargetFrameworks>netstandard1.5;netstandard2.0;net451</TargetFrameworks>
1111
</PropertyGroup>
1212

1313
<ItemGroup Label="Package">
@@ -45,6 +45,14 @@
4545
<PackageReference Include="System.Net.Primitives" Version="4.3.0" />
4646
</ItemGroup>
4747

48+
<PropertyGroup Condition=" '$(TargetFramework)' == 'netstandard2.0' " Label="Build">
49+
<DefineConstants>$(DefineConstants);NETSTANDARD2_0</DefineConstants>
50+
</PropertyGroup>
51+
52+
<ItemGroup Condition=" '$(TargetFramework)' == 'netstandard2.0' " Label="Package References">
53+
<PackageReference Include="System.Net.Primitives" Version="4.3.0" />
54+
</ItemGroup>
55+
4856
<PropertyGroup Condition=" '$(TargetFramework)' == 'net451' " Label="Build">
4957
<DefineConstants>$(DefineConstants);NET45</DefineConstants>
5058
</PropertyGroup>

0 commit comments

Comments
 (0)