diff --git a/NuGet.Config b/NuGet.Config index 1cbcecba8..55f84e99d 100644 --- a/NuGet.Config +++ b/NuGet.Config @@ -3,7 +3,6 @@ - diff --git a/build_projects/dotnet-cli-build/build.ps1 b/build_projects/dotnet-cli-build/build.ps1 index 21030843b..0f27922a7 100644 --- a/build_projects/dotnet-cli-build/build.ps1 +++ b/build_projects/dotnet-cli-build/build.ps1 @@ -35,9 +35,6 @@ else $env:DOTNET_BUILD_SKIP_PACKAGING=0 } -Write-Host "Disabling crossgen for the CLI build. See issue - https://github.com/dotnet/cli/issues/3059" -$env:DISABLE_CROSSGEN=1 - # Load Branch Info cat "$RepoRoot\branchinfo.txt" | ForEach-Object { if(!$_.StartsWith("#") -and ![String]::IsNullOrWhiteSpace($_)) { diff --git a/build_projects/shared-build-targets-utils/Utils/Crossgen.cs b/build_projects/shared-build-targets-utils/Utils/Crossgen.cs index 8b9d3290b..0c501794f 100644 --- a/build_projects/shared-build-targets-utils/Utils/Crossgen.cs +++ b/build_projects/shared-build-targets-utils/Utils/Crossgen.cs @@ -154,10 +154,15 @@ namespace Microsoft.DotNet.Cli.Build IList crossgenArgs = new List { "-readytorun", "-in", file, "-out", tempPathName, - "-JITPath", GetLibCLRJitPathForVersion(), "-platform_assemblies_paths", platformAssembliesPaths }; + if (CurrentPlatform.IsUnix) + { + crossgenArgs.Add("-JITPath"); + crossgenArgs.Add(GetLibCLRJitPathForVersion()); + } + ExecSilent(_crossGenPath, crossgenArgs, env); File.Copy(tempPathName, file, overwrite: true);