mirror of
https://github.com/PowerShell/PowerShell
synced 2026-06-08 12:12:50 +00:00
Update packaging script to build reference assembly targeting netcoreapp2.1 and use actual .csproj files (#8729)
# Conflicts: # tools/packaging/packaging.psm1 # tools/packaging/packaging.strings.psd1
This commit is contained in:
@@ -1911,7 +1911,7 @@ function New-ReferenceAssembly
|
||||
{
|
||||
Push-Location $projectFolder
|
||||
|
||||
$sourceProjectRoot = Join-Path $PSScriptRoot "projects/reference/$assemblyName"
|
||||
$sourceProjectRoot = Join-Path $PSScriptRoot 'projects/reference'
|
||||
$sourceProjectFile = Join-Path $sourceProjectRoot "$assemblyName.csproj"
|
||||
Copy-Item -Path $sourceProjectFile -Destination "$projectFolder/$assemblyName.csproj" -Force
|
||||
|
||||
|
||||
@@ -132,22 +132,7 @@ NuspecTemplate = @'
|
||||
</metadata>
|
||||
</package>
|
||||
'@
|
||||
RefAssemblyCsProj = @'
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
<PropertyGroup>
|
||||
<TargetFramework>netstandard2.0</TargetFramework>
|
||||
<Version>{0}</Version>
|
||||
<DelaySign>true</DelaySign>
|
||||
<AssemblyOriginatorKeyFile>{1}</AssemblyOriginatorKeyFile>
|
||||
<SignAssembly>true</SignAssembly>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Microsoft.Management.Infrastructure" Version="1.0.0-alpha08" />
|
||||
<PackageReference Include="System.Security.AccessControl" Version="4.4.1" />
|
||||
<PackageReference Include="System.Security.Principal.Windows" Version="4.4.1" />
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
'@
|
||||
|
||||
NuGetConfigFile = @'
|
||||
<configuration>
|
||||
<packageSources>
|
||||
|
||||
+1
-1
@@ -7,7 +7,7 @@
|
||||
<authors>PowerShell</authors>
|
||||
<owners>PowerShell</owners>
|
||||
<requireLicenseAcceptance>false</requireLicenseAcceptance>
|
||||
<licenseUrl>https://github.com/PowerShell/PowerShell/blob/master/LICENSE.txt</licenseUrl>
|
||||
<license type="expression">MIT</license>
|
||||
<projectUrl>https://github.com/powershell/powershell</projectUrl>
|
||||
<iconUrl>https://github.com/PowerShell/PowerShell/blob/master/assets/Powershell_64.png</iconUrl>
|
||||
<description>This package contains the PowerShell Core for $runtime$.</description>
|
||||
@@ -0,0 +1,19 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
<PropertyGroup>
|
||||
<TargetFramework>netcoreapp2.1</TargetFramework>
|
||||
<Version>$(RefAsmVersion)</Version>
|
||||
<DelaySign>true</DelaySign>
|
||||
<AssemblyOriginatorKeyFile>$(SnkFile)</AssemblyOriginatorKeyFile>
|
||||
<SignAssembly>true</SignAssembly>
|
||||
<LangVersion>Latest</LangVersion>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="System.Management.Automation">
|
||||
<HintPath>$(SmaRefFile)</HintPath>
|
||||
</Reference>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Newtonsoft.Json" Version="12.0.1" />
|
||||
<PackageReference Include="System.Security.AccessControl" Version="4.5.0" />
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
@@ -0,0 +1,15 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
<PropertyGroup>
|
||||
<TargetFramework>netcoreapp2.1</TargetFramework>
|
||||
<Version>$(RefAsmVersion)</Version>
|
||||
<DelaySign>true</DelaySign>
|
||||
<AssemblyOriginatorKeyFile>$(SnkFile)</AssemblyOriginatorKeyFile>
|
||||
<SignAssembly>true</SignAssembly>
|
||||
<LangVersion>Latest</LangVersion>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Microsoft.Management.Infrastructure" Version="1.0.0" />
|
||||
<PackageReference Include="System.Security.AccessControl" Version="4.5.0" />
|
||||
<PackageReference Include="System.Security.Principal.Windows" Version="4.5.1" />
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
Reference in New Issue
Block a user