Skip to content

Commit

Permalink
Reverted to netstandard 2.0 to avoid compatibility issues
Browse files Browse the repository at this point in the history
  • Loading branch information
ironfede committed Apr 22, 2023
1 parent e4f71d7 commit 0a1feb5
Show file tree
Hide file tree
Showing 8 changed files with 17 additions and 21 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,4 +74,4 @@ for (int i = 0; i < mgr.PropertySet0.NumProperties; i++)
...
```

OpenMcdf runs happily on the [Mono](http://www.mono-project.com/) platform and supports now **.NET 6**
OpenMcdf runs happily on the [Mono](http://www.mono-project.com/) platform and targets **netstandard 2.0** to allow maximum client compatibility AND .net framework 4 for legacy implementations.
2 changes: 1 addition & 1 deletion azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ pool:

variables:
buildConfiguration: 'Release'
libFramework: 'net6.0'
libFramework: 'netstandard2.0'
appFramework: 'net6.0'
# pay attention to slashes
testsProject: 'sources/Test/OpenMcdf.Test/OpenMcdf.Test.csproj'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ public static PropertyFactory Instance
get
{

#if NET6_0_OR_GREATER
#if NETSTANDARD2_0_OR_GREATER
Encoding.RegisterProvider(CodePagesEncodingProvider.Instance);
#endif
return instance.Value;
Expand Down
2 changes: 1 addition & 1 deletion sources/OpenMcdf.Extensions/OpenMcdf.Extensions.csproj
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFrameworks>net6.0;net40</TargetFrameworks>
<TargetFrameworks>netstandard2.0;net40</TargetFrameworks>
<Configurations>Debug;Release</Configurations>
<SignAssembly>true</SignAssembly>
<!-- Optional: Publish the repository URL in the built .nupkg (in the NuSpec <Repository> element) -->
Expand Down
9 changes: 5 additions & 4 deletions sources/OpenMcdf/OpenMcdf.csproj
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFrameworks>net6.0;net40</TargetFrameworks>
<TargetFrameworks>netstandard2.0;net40</TargetFrameworks>
<Configurations>Debug;Release</Configurations>
<SignAssembly>true</SignAssembly>
<!-- Optional: Publish the repository URL in the built .nupkg (in the NuSpec <Repository> element) -->
Expand Down Expand Up @@ -78,7 +78,7 @@
</PropertyGroup>
<PropertyGroup>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<Version>2.2.1.12</Version>
<Version>2.3.0.0</Version>
<PackageRequireLicenseAcceptance>true</PackageRequireLicenseAcceptance>
<Authors>ironfede</Authors>
<PackageLicenseUrl>https://opensource.org/licenses/MPL-2.0</PackageLicenseUrl>
Expand All @@ -88,9 +88,10 @@
<PackageTags>Compound file, c#, structured storage</PackageTags>
<Description>OpenMcdf is a 100% .net / C# component that allows developers to manipulate Microsoft Compound Document File Format for OLE structured storage.
It supports read/write operations on streams and storages and traversal of structures tree.</Description>
<Copyright>Copyright © 2010-2022, Federico Blaseotto</Copyright>
<Copyright>Copyright © 2010-2023, Federico Blaseotto</Copyright>
<PackageReadmeFile>README.md</PackageReadmeFile>
<PackageReleaseNotes>Bug fixing #88 and #90</PackageReleaseNotes>
<PackageReleaseNotes>Bug fixing #75 #76 #84 #94 #96
Updated to .NET 6.0</PackageReleaseNotes>
<Title>OpenMcdf</Title>
<PackageIcon>icon.png</PackageIcon>
</PropertyGroup>
Expand Down
10 changes: 4 additions & 6 deletions sources/Test/OpenMcdf.MemTest/OpenMcdf.MemTest.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,10 @@
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
<ItemGroup>
<Reference Include="OpenMcdf, Version=2.3.0.0, Culture=neutral, PublicKeyToken=fdbb1629d7c00800, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\bin\Debug\OpenMcdf\net40\OpenMcdf.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Data" />
<Reference Include="System.Xml" />
Expand Down Expand Up @@ -84,12 +88,6 @@
<Install>true</Install>
</BootstrapperPackage>
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\..\OpenMcdf\OpenMcdf.csproj">
<Project>{56e15d4a-8a37-4c7c-bb44-fd59aff220c1}</Project>
<Name>OpenMcdf</Name>
</ProjectReference>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
Expand Down
9 changes: 3 additions & 6 deletions sources/Test/OpenMcdf.PerfTest/OpenMcdf.PerfTest.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,9 @@
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
<ItemGroup>
<Reference Include="OpenMcdf">
<HintPath>..\..\..\bin\Debug\OpenMcdf\net40\OpenMcdf.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Data" />
<Reference Include="System.Xml" />
Expand Down Expand Up @@ -82,12 +85,6 @@
<ItemGroup>
<None Include="app.config" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\..\OpenMcdf\OpenMcdf.csproj">
<Project>{56e15d4a-8a37-4c7c-bb44-fd59aff220c1}</Project>
<Name>OpenMcdf</Name>
</ProjectReference>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
Expand Down
2 changes: 1 addition & 1 deletion sources/Test/OpenMcdf.Test/OpenMcdf.Test.csproj
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFrameworks>net45;net6.0</TargetFrameworks>
<TargetFrameworks>net45;net6.0</TargetFrameworks>
<IsPackable>false</IsPackable>
<Configurations>Debug;Release</Configurations>
<SignAssembly>true</SignAssembly>
Expand Down

0 comments on commit 0a1feb5

Please sign in to comment.