Skip to content

Commit

Permalink
Merge pull request #66 from Flexberry/fix-client-profile
Browse files Browse the repository at this point in the history
Fix net40 client profile
  • Loading branch information
fluffynuts authored Sep 17, 2020
2 parents acda688 + 1acab70 commit 3fa6542
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 9 deletions.
7 changes: 5 additions & 2 deletions src/log4net/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -73,14 +73,17 @@
[assembly: AssemblyInformationalVersionAttribute("2.0.9.0-.NET 4.0")]
[assembly: AssemblyTitle("Apache log4net for .NET Framework 4.0")]
#endif // Client Profile
#elif (NET_2_0)
#elif (NET_3_5)
#if CLIENT_PROFILE
[assembly: AssemblyInformationalVersionAttribute("2.0.9.0-.NET 3.5 CP")]
[assembly: AssemblyTitle("Apache log4net for .NET Framework 3.5 Client Profile")]
#else
[assembly: AssemblyInformationalVersionAttribute("2.0.9.0-.NET 3.5")]
[assembly: AssemblyTitle("Apache log4net for .NET Framework 3.5")]
#endif // Client Profile
#elif (NET_2_0)
[assembly: AssemblyInformationalVersionAttribute("2.0.9.0-.NET 2.0")]
[assembly: AssemblyTitle("Apache log4net for .NET Framework 2.0")]
#endif // Client Profile
#elif (NETCF_1_0)
[assembly: AssemblyInformationalVersionAttribute("2.0.9.0-.NETCF 1.0")]
[assembly: AssemblyTitle("Apache log4net for .NET Compact Framework 1.0")]
Expand Down
2 changes: 1 addition & 1 deletion src/log4net/Core/LoggingEvent.cs
Original file line number Diff line number Diff line change
Expand Up @@ -324,7 +324,7 @@ [Flags] public enum FixFlags
[Serializable]
#endif
public class LoggingEvent
#if !NETCF && NET_2_0
#if !NETCF
: ISerializable
#endif
{
Expand Down
7 changes: 4 additions & 3 deletions src/log4net/Util/PropertiesDictionary.cs
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,11 @@ namespace log4net.Util
/// </remarks>
/// <author>Nicko Cadell</author>
/// <author>Gert Driesen</author>
#if NETCF || CLIENT_PROFILE
#if NETCF
public sealed class PropertiesDictionary : ReadOnlyPropertiesDictionary, IDictionary
#else
[Serializable] public sealed class PropertiesDictionary : ReadOnlyPropertiesDictionary, ISerializable, IDictionary
[Serializable]
public sealed class PropertiesDictionary : ReadOnlyPropertiesDictionary, ISerializable, IDictionary
#endif
{
#region Public Instance Constructors
Expand Down Expand Up @@ -72,7 +73,7 @@ public PropertiesDictionary(ReadOnlyPropertiesDictionary propertiesDictionary) :

#region Private Instance Constructors

#if !(NETCF || CLIENT_PROFILE)
#if !NETCF
/// <summary>
/// Initializes a new instance of the <see cref="PropertiesDictionary" /> class
/// with serialized data.
Expand Down
6 changes: 3 additions & 3 deletions src/log4net/log4net.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -69,14 +69,14 @@
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
<TargetFrameworkProfile>Client</TargetFrameworkProfile>
<OutDir>..\..\build\$(Configuration)\net35-client</OutDir>
<DefineConstants>$(DefineConstants);NET_2_0;CLIENT_PROFILE</DefineConstants>
<DefineConstants>$(DefineConstants);NET_2_0;NET_3_5;CLIENT_PROFILE</DefineConstants>
</PropertyGroup>
<PropertyGroup Condition="'$(TargetFramework)'=='net40-client'">
<TargetFrameworkIdentifier>.NETFramework</TargetFrameworkIdentifier>
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
<TargetFrameworkProfile>Client</TargetFrameworkProfile>
<OutDir>..\..\build\$(Configuration)\net40-client</OutDir>
<DefineConstants>$(DefineConstants);NET_2_0;CLIENT_PROFILE</DefineConstants>
<DefineConstants>$(DefineConstants);NET_2_0;NET_4_0;CLIENT_PROFILE</DefineConstants>
</PropertyGroup>
<PropertyGroup Condition="'$(TargetFramework)'=='netstandard1.3'">
<DefineConstants>$(DefineConstants);NETSTANDARD;NETSTANDARD1_3</DefineConstants>
Expand Down

0 comments on commit 3fa6542

Please sign in to comment.