From 0bbf075007df7313cceccfc9ad0512db912dfcbd Mon Sep 17 00:00:00 2001 Patch-Source: https://github.com/dotnet/core-setup/pull/9195 From: Antoine Martin Date: Tue, 22 Feb 2022 01:18:45 +0000 Subject: [PATCH 1/1] Fixed __rid_plat generation on alpine for core-setup /src/corehost/build.sh generates wrong plat_rid on Alpine Generated RID is expected to be alpine.x.xx-xx, while the computed RID is linux-musl-xxx. This patches it by matching what's expected. On portable builds it also broken as computed RID is linux rather than the expected linux-musl --- src/corehost/build.sh | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/corehost/build.sh b/src/corehost/build.sh index fb503e74..c3b34321 100755 --- a/src/corehost/build.sh +++ b/src/corehost/build.sh @@ -21,14 +21,11 @@ init_rid_plat() __rid_plat="" if [ -e /etc/os-release ]; then source /etc/os-release - if [[ "$ID" == "rhel" ]]; then + if [ "$ID" == "rhel" ] || [ "$ID" == "alpine" ] ; then # remove the last version number VERSION_ID=${VERSION_ID%.*} fi __rid_plat="$ID.$VERSION_ID" - if [[ "$ID" == "alpine" ]]; then - __rid_plat="linux-musl" - fi elif [ -e /etc/redhat-release ]; then local redhatRelease=$(