Skip to content

Commit

Permalink
ResolveReadyToRunCompilers: map non-portable rids when targetOS is de…
Browse files Browse the repository at this point in the history
…termined.
  • Loading branch information
tmds committed Oct 7, 2022
1 parent f720423 commit 44ab0e6
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 5 deletions.
8 changes: 4 additions & 4 deletions eng/restore-toolset.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,10 @@ function InitializeCustomSDKToolset {

InitializeDotNetCli true

if [[ "$DISTRO" != "ubuntu" || "$MAJOR_VERSION" -le 16 ]]; then
InstallDotNetSharedFramework "1.0.5"
InstallDotNetSharedFramework "1.1.2"
fi
# if [[ "$DISTRO" != "ubuntu" || "$MAJOR_VERSION" -le 16 ]]; then
# InstallDotNetSharedFramework "1.0.5"
# InstallDotNetSharedFramework "1.1.2"
# fi
InstallDotNetSharedFramework "2.1.0"
InstallDotNetSharedFramework "2.2.8"
InstallDotNetSharedFramework "3.1.0"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,15 @@ private bool ValidateCrossgen2Support()

bool version5 = crossgen2PackVersion.Major < 6;
bool isSupportedTarget = ExtractTargetPlatformAndArchitecture(_targetRuntimeIdentifier, out _targetPlatform, out _targetArchitecture);
string targetOS = _targetPlatform switch

var runtimeGraph = new RuntimeGraphCache(this).GetRuntimeGraph(RuntimeGraphPath);
string portablePlatform = NuGetUtils.GetBestMatchingRid(
runtimeGraph,
_targetPlatform,
new[] { "linux", "linux-musl", "osx", "win" },
out _);

string targetOS = portablePlatform switch
{
"linux" => "linux",
"linux-musl" => "linux",
Expand Down

0 comments on commit 44ab0e6

Please sign in to comment.