Skip to content

Commit

Permalink
Minor tweaks to the MimeKit[Lite].csproj net8.0 changes
Browse files Browse the repository at this point in the history
Also added net8.0 builds to the nuget packages and bumped their
dependencies to the 8.0.0 versions of System.Security.Cryptography.Pkcs
and System.Text.Encoding.CodePages.
  • Loading branch information
jstedfast committed Nov 17, 2023
1 parent fb5a35e commit be4cbe7
Show file tree
Hide file tree
Showing 4 changed files with 43 additions and 26 deletions.
19 changes: 9 additions & 10 deletions MimeKit/MimeKit.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,8 @@
<DebugType>full</DebugType>
</PropertyGroup>

<PropertyGroup Condition=" $(TargetFramework.StartsWith('net4')) Or $(TargetFramework.StartsWith('net6')) Or $(TargetFramework.StartsWith('net8')) ">
<!-- Enable serializable support for net4.x, net6.0 and net8.0 -->
<PropertyGroup Condition=" ! $(TargetFramework.StartsWith('netstandard')) ">
<DefineConstants>$(DefineConstants);SERIALIZABLE</DefineConstants>
</PropertyGroup>

Expand All @@ -62,24 +63,22 @@
<PackageReference Include="System.Data.DataSetExtensions" Version="4.5.0" />
</ItemGroup>

<ItemGroup Condition=" $(TargetFramework.StartsWith('netstandard2.')) Or $(TargetFramework.StartsWith('net6')) ">
<PackageReference Include="System.Security.Cryptography.Pkcs" Version="7.0.3" />
<PackageReference Include="System.Text.Encoding.CodePages" Version="7.0.0" />
</ItemGroup>

<ItemGroup Condition=" $(TargetFramework.StartsWith('net8')) ">
<PackageReference Include="System.Security.Cryptography.Pkcs" Version="8.0.0" />
<PackageReference Include="System.Text.Encoding.CodePages" Version="8.0.0" />
<ItemGroup Condition=" $(TargetFramework.StartsWith('netstandard2.')) Or $(TargetFramework.StartsWith('net6')) Or $(TargetFramework.StartsWith('net8')) ">
<PackageReference Include="System.Security.Cryptography.Pkcs" Version="8.0.0" />
<PackageReference Include="System.Text.Encoding.CodePages" Version="8.0.0" />
</ItemGroup>

<ItemGroup Condition=" $(TargetFramework.StartsWith('netstandard2.')) ">
<PackageReference Include="System.Reflection.TypeExtensions" Version="4.7.0" />
</ItemGroup>

<ItemGroup Condition=" $(TargetFramework.StartsWith('net4')) Or $(TargetFramework.StartsWith('netstandard2.')) Or $(TargetFramework.StartsWith('net6')) ">
<PackageReference Include="System.Runtime.CompilerServices.Unsafe" Version="6.0.0" />
</ItemGroup>

<ItemGroup Condition=" $(TargetFramework.StartsWith('net4')) Or $(TargetFramework.StartsWith('netstandard2.')) ">
<PackageReference Include="System.Buffers" Version="4.5.1" />
<PackageReference Include="System.Memory" Version="4.5.5" />
<PackageReference Include="System.Runtime.CompilerServices.Unsafe" Version="6.0.0" />
</ItemGroup>

<ItemGroup>
Expand Down
14 changes: 7 additions & 7 deletions MimeKit/MimeKitLite.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -47,26 +47,26 @@
<DebugType>full</DebugType>
</PropertyGroup>

<PropertyGroup Condition=" $(TargetFramework.StartsWith('net4')) Or $(TargetFramework.StartsWith('net6')) Or $(TargetFramework.StartsWith('net8')) ">
<!-- Enable serializable support for net4.x, net6.0 and net8.0 -->
<PropertyGroup Condition=" ! $(TargetFramework.StartsWith('netstandard')) ">
<DefineConstants>$(DefineConstants);SERIALIZABLE</DefineConstants>
</PropertyGroup>

<ItemGroup Condition=" $(TargetFramework.StartsWith('netstandard2.')) Or $(TargetFramework.StartsWith('net6')) ">
<PackageReference Include="System.Text.Encoding.CodePages" Version="7.0.0" />
</ItemGroup>

<ItemGroup Condition=" $(TargetFramework.StartsWith('net8')) ">
<ItemGroup Condition=" $(TargetFramework.StartsWith('netstandard2.')) Or $(TargetFramework.StartsWith('net6')) Or $(TargetFramework.StartsWith('net8')) ">
<PackageReference Include="System.Text.Encoding.CodePages" Version="8.0.0" />
</ItemGroup>

<ItemGroup Condition=" $(TargetFramework.StartsWith('netstandard2.')) ">
<PackageReference Include="System.Reflection.TypeExtensions" Version="4.7.0" />
</ItemGroup>

<ItemGroup Condition=" $(TargetFramework.StartsWith('net4')) Or $(TargetFramework.StartsWith('netstandard2.')) Or $(TargetFramework.StartsWith('net6')) ">
<PackageReference Include="System.Runtime.CompilerServices.Unsafe" Version="6.0.0" />
</ItemGroup>

<ItemGroup Condition=" $(TargetFramework.StartsWith('net4')) Or $(TargetFramework.StartsWith('netstandard2.')) ">
<PackageReference Include="System.Buffers" Version="4.5.1" />
<PackageReference Include="System.Memory" Version="4.5.5" />
<PackageReference Include="System.Runtime.CompilerServices.Unsafe" Version="6.0.0" />
</ItemGroup>

<ItemGroup>
Expand Down
22 changes: 16 additions & 6 deletions nuget/MimeKit.nuspec
Original file line number Diff line number Diff line change
Expand Up @@ -75,23 +75,29 @@
</group>
<group targetFramework="net6.0">
<dependency id="System.Runtime.CompilerServices.Unsafe" version="6.0.0" />
<dependency id="System.Security.Cryptography.Pkcs" version="7.0.3" />
<dependency id="System.Text.Encoding.CodePages" version="7.0.0" />
<dependency id="System.Security.Cryptography.Pkcs" version="8.0.0" />
<dependency id="System.Text.Encoding.CodePages" version="8.0.0" />
<dependency id="BouncyCastle.Cryptography" version="2.2.1" />
</group>
<group targetFramework="net8.0">
<dependency id="System.Runtime.CompilerServices.Unsafe" version="6.0.0" />
<dependency id="System.Security.Cryptography.Pkcs" version="8.0.0" />
<dependency id="System.Text.Encoding.CodePages" version="8.0.0" />
<dependency id="BouncyCastle.Cryptography" version="2.2.1" />
</group>
<group targetFramework="netstandard2.0">
<dependency id="System.Runtime.CompilerServices.Unsafe" version="6.0.0" />
<dependency id="System.Security.Cryptography.Pkcs" version="7.0.3" />
<dependency id="System.Text.Encoding.CodePages" version="7.0.0" />
<dependency id="System.Security.Cryptography.Pkcs" version="8.0.0" />
<dependency id="System.Text.Encoding.CodePages" version="8.0.0" />
<dependency id="System.Data.DataSetExtensions" version="4.5.0" />
<dependency id="System.Buffers" version="4.5.1" />
<dependency id="System.Memory" version="4.5.5" />
<dependency id="BouncyCastle.Cryptography" version="2.2.1" />
</group>
<group targetFramework="netstandard2.1">
<dependency id="System.Runtime.CompilerServices.Unsafe" version="6.0.0" />
<dependency id="System.Security.Cryptography.Pkcs" version="7.0.3" />
<dependency id="System.Text.Encoding.CodePages" version="7.0.0" />
<dependency id="System.Security.Cryptography.Pkcs" version="8.0.0" />
<dependency id="System.Text.Encoding.CodePages" version="8.0.0" />
<dependency id="System.Buffers" version="4.5.1" />
<dependency id="System.Memory" version="4.5.5" />
<dependency id="BouncyCastle.Cryptography" version="2.2.1" />
Expand Down Expand Up @@ -125,6 +131,10 @@
<file src="..\MimeKit\bin\Release\net6.0\MimeKit.pdb" target="lib\net6.0\MimeKit.pdb" />
<file src="..\MimeKit\bin\Release\net6.0\MimeKit.xml" target="lib\net6.0\MimeKit.xml" />
<file src="..\MimeKit\bin\Release\net6.0\MimeKit.dll.config" target="lib\net6.0\MimeKit.dll.config" />
<file src="..\MimeKit\bin\Release\net8.0\MimeKit.dll" target="lib\net8.0\MimeKit.dll" />
<file src="..\MimeKit\bin\Release\net8.0\MimeKit.pdb" target="lib\net8.0\MimeKit.pdb" />
<file src="..\MimeKit\bin\Release\net8.0\MimeKit.xml" target="lib\net8.0\MimeKit.xml" />
<file src="..\MimeKit\bin\Release\net8.0\MimeKit.dll.config" target="lib\net8.0\MimeKit.dll.config" />
<file src="mimekit-50.png" target="icons\mimekit-50.png" />
</files>
</package>
14 changes: 11 additions & 3 deletions nuget/MimeKitLite.nuspec
Original file line number Diff line number Diff line change
Expand Up @@ -63,19 +63,23 @@
</group>
<group targetFramework="net6.0">
<dependency id="System.Runtime.CompilerServices.Unsafe" version="6.0.0" />
<dependency id="System.Text.Encoding.CodePages" version="7.0.0" />
<dependency id="System.Text.Encoding.CodePages" version="8.0.0" />
</group>
<group targetFramework="net8.0">
<dependency id="System.Runtime.CompilerServices.Unsafe" version="6.0.0" />
<dependency id="System.Text.Encoding.CodePages" version="8.0.0" />
</group>
<group targetFramework="netstandard2.0">
<dependency id="System.Runtime.CompilerServices.Unsafe" version="6.0.0" />
<dependency id="System.Reflection.TypeExtensions" version="4.7.0" />
<dependency id="System.Text.Encoding.CodePages" version="7.0.0" />
<dependency id="System.Text.Encoding.CodePages" version="8.0.0" />
<dependency id="System.Buffers" version="4.5.1" />
<dependency id="System.Memory" version="4.5.5" />
</group>
<group targetFramework="netstandard2.1">
<dependency id="System.Runtime.CompilerServices.Unsafe" version="6.0.0" />
<dependency id="System.Reflection.TypeExtensions" version="4.7.0" />
<dependency id="System.Text.Encoding.CodePages" version="7.0.0" />
<dependency id="System.Text.Encoding.CodePages" version="8.0.0" />
<dependency id="System.Buffers" version="4.5.1" />
<dependency id="System.Memory" version="4.5.5" />
</group>
Expand Down Expand Up @@ -108,6 +112,10 @@
<file src="..\MimeKit\bin\Release\net6.0\MimeKitLite.pdb" target="lib\net6.0\MimeKitLite.pdb" />
<file src="..\MimeKit\bin\Release\net6.0\MimeKitLite.xml" target="lib\net6.0\MimeKitLite.xml" />
<file src="..\MimeKit\bin\Release\net6.0\MimeKitLite.dll.config" target="lib\net6.0\MimeKitLite.dll.config" />
<file src="..\MimeKit\bin\Release\net8.0\MimeKitLite.dll" target="lib\net8.0\MimeKitLite.dll" />
<file src="..\MimeKit\bin\Release\net8.0\MimeKitLite.pdb" target="lib\net8.0\MimeKitLite.pdb" />
<file src="..\MimeKit\bin\Release\net8.0\MimeKitLite.xml" target="lib\net8.0\MimeKitLite.xml" />
<file src="..\MimeKit\bin\Release\net8.0\MimeKitLite.dll.config" target="lib\net8.0\MimeKitLite.dll.config" />
<file src="mimekit-50.png" target="icons\mimekit-50.png" />
</files>
</package>

0 comments on commit be4cbe7

Please sign in to comment.