From 1eea6127e151aaf9914ed716475d020a416447d6 Mon Sep 17 00:00:00 2001 From: Chongyi Zheng Date: Thu, 29 Feb 2024 07:56:54 -0500 Subject: [PATCH] build: install zlib from alpine packages (#5317) --- scripts/install-glibc.sh | 20 +------------------- 1 file changed, 1 insertion(+), 19 deletions(-) diff --git a/scripts/install-glibc.sh b/scripts/install-glibc.sh index 3abfd53c..d594242a 100755 --- a/scripts/install-glibc.sh +++ b/scripts/install-glibc.sh @@ -2,19 +2,6 @@ set -euo pipefail -case $TARGETARCH in -amd64) - target=x86_64 - ;; -arm64) - target=arm64 - ;; -*) - echo "$TARGETARCH is not supported" - exit 1 - ;; -esac - url=$( set -euo pipefail curl -s \ @@ -31,14 +18,9 @@ apk add --no-cache --force-overwrite "glibc-${GLIBC_VERSION}.apk" rm "glibc-${GLIBC_VERSION}.apk" # Install zlib -mkdir /tmp/libz - apk add --no-cache --virtual .glibc-build-deps \ tar \ + zlib \ zstd -curl --retry 5 --retry-delay 5 -sL https://www.archlinux.org/packages/core/${target}/zlib/download | tar -x --zstd -C /tmp/libz -mv /tmp/libz/usr/lib/libz.so* /usr/glibc-compat/lib -rm -rf /tmp/libz - apk del --no-network --purge .glibc-build-deps