Browse Source

Build: support for building strong-name edition packages again #561

pull/566/head
Christoph Ruegg 8 years ago
parent
commit
4304c00f0b
  1. 14
      build/build-framework.fsx
  2. 1
      src/Data.Tests/Data.Tests.csproj
  3. 15
      src/Data/Matlab/Matlab.csproj
  4. 15
      src/Data/Text/Text.csproj
  5. 13
      src/Directory.Build.props
  6. 6
      src/FSharp/FSharp.fsproj
  7. 2
      src/Numerics.Tests/Numerics.Tests.CUDA.csproj
  8. 2
      src/Numerics.Tests/Numerics.Tests.MKL.csproj
  9. 2
      src/Numerics.Tests/Numerics.Tests.OpenBLAS.csproj
  10. 9
      src/Numerics/Numerics.csproj
  11. 4
      src/Numerics/Properties/AssemblyInfo.cs

14
build/build-framework.fsx

@ -34,20 +34,30 @@ trace rootDir
// --------------------------------------------------------------------------------------
let msbuild targets configuration project =
let properties =
[
yield "Configuration", configuration
if hasBuildParam "strongname" then yield "StrongName", "True"
]
MSBuildHelper.build (fun p ->
{ p with
NoLogo = true
NodeReuse = true
Targets = targets
Properties = [ "Configuration", configuration ]
Properties = properties
RestorePackagesFlag = false
Verbosity = Some MSBuildVerbosity.Minimal
}) project
let dotnet workingDir command =
let properties =
[
if hasBuildParam "strongname" then yield "StrongName", "True"
]
let suffix = properties |> List.map (fun (name, value) -> sprintf """ /p:%s="%s" """ name value) |> String.concat ""
DotNetCli.RunCommand
(fun c -> { c with WorkingDir = workingDir})
command
(command + suffix)
// --------------------------------------------------------------------------------------

1
src/Data.Tests/Data.Tests.csproj

@ -3,7 +3,6 @@
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFrameworks>net45;netcoreapp1.1;netcoreapp2.0</TargetFrameworks>
<RuntimeFrameworkVersion>2.0.7</RuntimeFrameworkVersion>
<GenerateAssemblyInfo>false</GenerateAssemblyInfo>
<AssemblyName>MathNet.Numerics.Data.Tests</AssemblyName>
<RootNamespace>MathNet.Numerics.Data.Tests</RootNamespace>

15
src/Data/Matlab/Matlab.csproj

@ -3,27 +3,18 @@
<PropertyGroup>
<OutputType>Library</OutputType>
<TargetFrameworks>net40;netstandard1.3;netstandard2.0</TargetFrameworks>
<NetStandardImplicitPackageVersion>2.0.2</NetStandardImplicitPackageVersion>
<AssemblyName>MathNet.Numerics.Data.Matlab</AssemblyName>
<RootNamespace>MathNet.Numerics.Data.Matlab</RootNamespace>
<IsPackable>true</IsPackable>
<PackageId>MathNet.Numerics.Data.Matlab</PackageId>
<PackageId>MathNet.Numerics.Data.Matlab$(PackageIdSuffix)</PackageId>
<VersionPrefix>4.0.0</VersionPrefix>
<VersionSuffix></VersionSuffix>
<PackageVersion>4.0.0</PackageVersion>
<Version>4.0.0</Version>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
<FileVersion>4.0.0.0</FileVersion>
<Title>Math.NET Numerics - MATLAB Data I/O Extensions</Title>
<Authors>Christoph Ruegg, Marcus Cuda</Authors>
<Company>Math.NET Project</Company>
<Product>Math.NET Numerics</Product>
<Description>MathWorks MATLAB Data Input/Output Extensions for Math.NET Numerics, the numerical foundation of the Math.NET project, aiming to provide methods and algorithms for numerical computations in science, engineering and every day use.</Description>
<Copyright>Copyright Math.NET Project</Copyright>
<PackageRequireLicenseAcceptance>false</PackageRequireLicenseAcceptance>
<PackageLicenseUrl>https://numerics.mathdotnet.com/License.html</PackageLicenseUrl>
<PackageProjectUrl>https://numerics.mathdotnet.com/</PackageProjectUrl>
<PackageIconUrl>https://www.mathdotnet.com/images/MathNet128.png</PackageIconUrl>
<Title>Math.NET Numerics - MATLAB Data I/O Extensions$(TitleSuffix)</Title>
<Description>MathWorks MATLAB Data Input/Output Extensions for Math.NET Numerics, the numerical foundation of the Math.NET project, aiming to provide methods and algorithms for numerical computations in science, engineering and every day use.$(DescriptionSuffix)</Description>
<PackageReleaseNotes>Support for Math.NET Numerics v4
In addition to .Net 4.0 and newer now also targets .Net Standard 1.3 and 2.0.</PackageReleaseNotes>
<PackageTags>math numeric data matlab</PackageTags>

15
src/Data/Text/Text.csproj

@ -3,27 +3,18 @@
<PropertyGroup>
<OutputType>Library</OutputType>
<TargetFrameworks>net40;netstandard1.3;netstandard2.0</TargetFrameworks>
<NetStandardImplicitPackageVersion>2.0.2</NetStandardImplicitPackageVersion>
<AssemblyName>MathNet.Numerics.Data.Text</AssemblyName>
<RootNamespace>MathNet.Numerics.Data.Text</RootNamespace>
<IsPackable>true</IsPackable>
<PackageId>MathNet.Numerics.Data.Text</PackageId>
<PackageId>MathNet.Numerics.Data.Text$(PackageIdSuffix)</PackageId>
<VersionPrefix>4.0.0</VersionPrefix>
<VersionSuffix></VersionSuffix>
<PackageVersion>4.0.0</PackageVersion>
<Version>4.0.0</Version>
<AssemblyVersion>4.0.0.0</AssemblyVersion>
<FileVersion>4.0.0.0</FileVersion>
<Title>Math.NET Numerics - Text Data I/O Extensions</Title>
<Authors>Christoph Ruegg, Marcus Cuda</Authors>
<Company>Math.NET Project</Company>
<Product>Math.NET Numerics</Product>
<Description>Text Data Input/Output Extensions for Math.NET Numerics, the numerical foundation of the Math.NET project, aiming to provide methods and algorithms for numerical computations in science, engineering and every day use.</Description>
<Copyright>Copyright Math.NET Project</Copyright>
<PackageRequireLicenseAcceptance>false</PackageRequireLicenseAcceptance>
<PackageLicenseUrl>https://numerics.mathdotnet.com/License.html</PackageLicenseUrl>
<PackageProjectUrl>https://numerics.mathdotnet.com/</PackageProjectUrl>
<PackageIconUrl>https://www.mathdotnet.com/images/MathNet128.png</PackageIconUrl>
<Title>Math.NET Numerics - Text Data I/O Extensions$(TitleSuffix)</Title>
<Description>Text Data Input/Output Extensions for Math.NET Numerics, the numerical foundation of the Math.NET project, aiming to provide methods and algorithms for numerical computations in science, engineering and every day use.$(DescriptionSuffix)</Description>
<PackageReleaseNotes>Support for Math.NET Numerics v4
In addition to .Net 4.0 and newer now also targets .Net Standard 1.3 and 2.0.</PackageReleaseNotes>
<PackageTags>math numeric data text csv tsv json xml</PackageTags>

13
src/Directory.Build.props

@ -14,4 +14,17 @@
<RepositoryType>git</RepositoryType>
<NeutralLanguage>en</NeutralLanguage>
</PropertyGroup>
<PropertyGroup Condition="'$(StrongName)'=='True'">
<SignAssembly>true</SignAssembly>
<AssemblyOriginatorKeyFile>../MathNet.Numerics.snk</AssemblyOriginatorKeyFile>
<DelaySign>false</DelaySign>
<CommonConstants>STRONGNAME</CommonConstants>
<PackageIdSuffix>.Signed</PackageIdSuffix>
<TitleSuffix> - Strong Name Edition</TitleSuffix>
<DescriptionSuffix> This package contains strong-named assemblies for legacy use cases (not recommended).</DescriptionSuffix>
<DefineConstants>$(CommonConstants)</DefineConstants>
</PropertyGroup>
<PropertyGroup Condition="'$(TargetFramework)'!='netstandard1.3'">
<DefineConstants>NATIVE;$(CommonConstants)</DefineConstants>
</PropertyGroup>
</Project>

6
src/FSharp/FSharp.fsproj

@ -6,15 +6,15 @@
<AssemblyName>MathNet.Numerics.FSharp</AssemblyName>
<RootNamespace>MathNet.Numerics</RootNamespace>
<IsPackable>true</IsPackable>
<PackageId>MathNet.Numerics.FSharp</PackageId>
<PackageId>MathNet.Numerics.FSharp$(PackageIdSuffix)</PackageId>
<VersionPrefix>4.4.0</VersionPrefix>
<VersionSuffix></VersionSuffix>
<PackageVersion>4.4.0</PackageVersion>
<Version>4.4.0</Version>
<AssemblyVersion>4.4.0.0</AssemblyVersion>
<FileVersion>4.4.0.0</FileVersion>
<Title>Math.NET Numerics for F#</Title>
<Description>F# Modules for Math.NET Numerics, the numerical foundation of the Math.NET project, aiming to provide methods and algorithms for numerical computations in science, engineering and every day use. Supports .Net Framework 4.5 or higher and .Net Standard 1.6 or higher, on Windows, Linux and Mac.</Description>
<Title>Math.NET Numerics for F#$(TitleSuffix)</Title>
<Description>F# Modules for Math.NET Numerics, the numerical foundation of the Math.NET project, aiming to provide methods and algorithms for numerical computations in science, engineering and every day use. Supports .Net Framework 4.5 or higher and .Net Standard 1.6 or higher, on Windows, Linux and Mac.$(DescriptionSuffix)</Description>
<PackageReleaseNotes>Linear Algebra: managed provider performance improvements on basic vector arithmetics</PackageReleaseNotes>
<PackageTags>fsharp F# math numeric statistics probability integration interpolation regression solve fit linear algebra matrix fft</PackageTags>
<IsTool>false</IsTool>

2
src/Numerics.Tests/Numerics.Tests.CUDA.csproj

@ -8,7 +8,7 @@
<AssemblyName>MathNet.Numerics.Tests.CUDA</AssemblyName>
<RootNamespace>MathNet.Numerics.Tests</RootNamespace>
<IsPackable>false</IsPackable>
<DefineConstants>NATIVE;CUDA</DefineConstants>
<DefineConstants>NATIVE;CUDA;$(CommonConstants)</DefineConstants>
</PropertyGroup>
<ItemGroup Condition="'$(TargetFramework)'=='net461'">
<Reference Include="System" />

2
src/Numerics.Tests/Numerics.Tests.MKL.csproj

@ -8,7 +8,7 @@
<AssemblyName>MathNet.Numerics.Tests.MKL</AssemblyName>
<RootNamespace>MathNet.Numerics.Tests</RootNamespace>
<IsPackable>false</IsPackable>
<DefineConstants>NATIVE;MKL</DefineConstants>
<DefineConstants>NATIVE;MKL;$(CommonConstants)</DefineConstants>
</PropertyGroup>
<ItemGroup Condition="'$(TargetFramework)'=='net461'">
<Reference Include="System" />

2
src/Numerics.Tests/Numerics.Tests.OpenBLAS.csproj

@ -8,7 +8,7 @@
<AssemblyName>MathNet.Numerics.Tests.OpenBLAS</AssemblyName>
<RootNamespace>MathNet.Numerics.Tests</RootNamespace>
<IsPackable>false</IsPackable>
<DefineConstants>NATIVE;OPENBLAS</DefineConstants>
<DefineConstants>NATIVE;OPENBLAS;$(CommonConstants)</DefineConstants>
</PropertyGroup>
<ItemGroup Condition="'$(TargetFramework)'=='net461'">
<Reference Include="System" />

9
src/Numerics/Numerics.csproj

@ -6,15 +6,15 @@
<AssemblyName>MathNet.Numerics</AssemblyName>
<RootNamespace>MathNet.Numerics</RootNamespace>
<IsPackable>true</IsPackable>
<PackageId>MathNet.Numerics</PackageId>
<PackageId>MathNet.Numerics$(PackageIdSuffix)</PackageId>
<VersionPrefix>4.4.0</VersionPrefix>
<VersionSuffix></VersionSuffix>
<PackageVersion>4.4.0</PackageVersion>
<Version>4.4.0</Version>
<AssemblyVersion>4.4.0.0</AssemblyVersion>
<FileVersion>4.4.0.0</FileVersion>
<Title>Math.NET Numerics</Title>
<Description>Math.NET Numerics is the numerical foundation of the Math.NET project, aiming to provide methods and algorithms for numerical computations in science, engineering and every day use. Supports .Net Framework 4.0 or higher and .Net Standard 1.3 or higher, on Windows, Linux and Mac.</Description>
<Title>Math.NET Numerics$(TitleSuffix)</Title>
<Description>Math.NET Numerics is the numerical foundation of the Math.NET project, aiming to provide methods and algorithms for numerical computations in science, engineering and every day use. Supports .Net Framework 4.0 or higher and .Net Standard 1.3 or higher, on Windows, Linux and Mac.$(DescriptionSuffix)</Description>
<PackageReleaseNotes>Linear Algebra: managed provider performance improvements on basic vector arithmetics</PackageReleaseNotes>
<PackageTags>math numeric statistics probability integration interpolation regression solve fit linear algebra matrix fft</PackageTags>
<IsTool>false</IsTool>
@ -28,9 +28,6 @@
<EnableDefaultCompileItems>true</EnableDefaultCompileItems>
<NoWarn>1701;1702;1705;1591;1573</NoWarn>
</PropertyGroup>
<PropertyGroup Condition="'$(TargetFramework)'!='netstandard1.3'">
<DefineConstants>NATIVE</DefineConstants>
</PropertyGroup>
<ItemGroup Condition="'$(TargetFramework)' == 'net40'">
<Reference Include="System" />
<Reference Include="System.Core" />

4
src/Numerics/Properties/AssemblyInfo.cs

@ -37,6 +37,10 @@ using System.Runtime.InteropServices;
#if STRONGNAME
[assembly: InternalsVisibleTo("MathNet.Numerics.Tests, PublicKey=0024000004800000940000000602000000240000525341310004000001000100ed2314a577643d859571b8b9307c6ff2670525c4598fbb307e57ea65ebf5d4417284cb3da9181636480b623f4db8cc3c1947244ba069df0df86e2431621f51a488f9929519a1c5d0ae595f6e2d0e4094685f0c1229ff658360acbb9f63f1a0258e984dda00dc7ad4fd16dbb550ec1ef8a11df138402b7c1998ee224e652c839b")]
[assembly: InternalsVisibleTo("MathNet.Numerics.Tests.MKL, PublicKey=0024000004800000940000000602000000240000525341310004000001000100ed2314a577643d859571b8b9307c6ff2670525c4598fbb307e57ea65ebf5d4417284cb3da9181636480b623f4db8cc3c1947244ba069df0df86e2431621f51a488f9929519a1c5d0ae595f6e2d0e4094685f0c1229ff658360acbb9f63f1a0258e984dda00dc7ad4fd16dbb550ec1ef8a11df138402b7c1998ee224e652c839b")]
[assembly: InternalsVisibleTo("MathNet.Numerics.Tests.CUDA, PublicKey=0024000004800000940000000602000000240000525341310004000001000100ed2314a577643d859571b8b9307c6ff2670525c4598fbb307e57ea65ebf5d4417284cb3da9181636480b623f4db8cc3c1947244ba069df0df86e2431621f51a488f9929519a1c5d0ae595f6e2d0e4094685f0c1229ff658360acbb9f63f1a0258e984dda00dc7ad4fd16dbb550ec1ef8a11df138402b7c1998ee224e652c839b")]
[assembly: InternalsVisibleTo("MathNet.Numerics.Tests.OpenBLAS, PublicKey=0024000004800000940000000602000000240000525341310004000001000100ed2314a577643d859571b8b9307c6ff2670525c4598fbb307e57ea65ebf5d4417284cb3da9181636480b623f4db8cc3c1947244ba069df0df86e2431621f51a488f9929519a1c5d0ae595f6e2d0e4094685f0c1229ff658360acbb9f63f1a0258e984dda00dc7ad4fd16dbb550ec1ef8a11df138402b7c1998ee224e652c839b")]
[assembly: InternalsVisibleTo("Benchmark, PublicKey=0024000004800000940000000602000000240000525341310004000001000100ed2314a577643d859571b8b9307c6ff2670525c4598fbb307e57ea65ebf5d4417284cb3da9181636480b623f4db8cc3c1947244ba069df0df86e2431621f51a488f9929519a1c5d0ae595f6e2d0e4094685f0c1229ff658360acbb9f63f1a0258e984dda00dc7ad4fd16dbb550ec1ef8a11df138402b7c1998ee224e652c839b")]
#else
[assembly: InternalsVisibleTo("MathNet.Numerics.Tests")]
[assembly: InternalsVisibleTo("MathNet.Numerics.Tests.MKL")]

Loading…
Cancel
Save