mirror of
https://github.com/PowerShell/PowerShell
synced 2026-06-08 12:12:50 +00:00
Turn on ReadyToRun (#12361)
Co-authored-by: Travis Plunk <travis.plunk@microsoft.com>
This commit is contained in:
@@ -97,6 +97,7 @@
|
||||
|
||||
<TargetFramework>netcoreapp5.0</TargetFramework>
|
||||
<LangVersion>8.0</LangVersion>
|
||||
<PublishReadyToRun>true</PublishReadyToRun>
|
||||
|
||||
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
|
||||
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
|
||||
|
||||
+2
-23
@@ -2233,6 +2233,7 @@ function Start-CrossGen {
|
||||
$CrossgenPath
|
||||
)
|
||||
|
||||
|
||||
$platformAssembliesPath = Split-Path $AssemblyPath -Parent
|
||||
$crossgenFolder = Split-Path $CrossgenPath
|
||||
|
||||
@@ -2361,29 +2362,7 @@ function Start-CrossGen {
|
||||
"Microsoft.ApplicationInsights.dll"
|
||||
)
|
||||
|
||||
# Common PowerShell libraries to crossgen
|
||||
$psCoreAssemblyList = @(
|
||||
"pwsh.dll",
|
||||
"Microsoft.PowerShell.Commands.Utility.dll",
|
||||
"Microsoft.PowerShell.Commands.Management.dll",
|
||||
"Microsoft.PowerShell.Security.dll",
|
||||
"Microsoft.PowerShell.ConsoleHost.dll",
|
||||
"System.Management.Automation.dll"
|
||||
)
|
||||
|
||||
# Add Windows specific libraries
|
||||
if ($environment.IsWindows) {
|
||||
$psCoreAssemblyList += @(
|
||||
"Microsoft.PowerShell.CoreCLR.Eventing.dll",
|
||||
"Microsoft.WSMan.Management.dll",
|
||||
"Microsoft.WSMan.Runtime.dll",
|
||||
"Microsoft.PowerShell.Commands.Diagnostics.dll",
|
||||
"Microsoft.PowerShell.GraphicalHost.dll",
|
||||
"Microsoft.Management.Infrastructure.CimCmdlets.dll"
|
||||
)
|
||||
}
|
||||
|
||||
$fullAssemblyList = $commonAssembliesForAddType + $psCoreAssemblyList
|
||||
$fullAssemblyList = $commonAssembliesForAddType
|
||||
|
||||
foreach ($assemblyName in $fullAssemblyList) {
|
||||
$assemblyPath = Join-Path $PublishPath $assemblyName
|
||||
|
||||
Reference in New Issue
Block a user