fix: skip glibc requirements check on nixos (#202982)

pull/203006/head
Robo 2024-01-22 17:51:44 +09:00 committed by GitHub
parent 0d71d26b8c
commit 8baf105cbd
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 7 additions and 0 deletions

View File

@ -10,6 +10,13 @@ ARCH=$(uname -m)
found_required_glibc=0
found_required_glibcxx=0
# Extract the ID value from /etc/os-release
OS_ID="$(cat /etc/os-release | grep -Eo 'ID=([^"]+)' | sed 's/ID=//')"
if [ "$OS_ID" = "nixos" ]; then
echo "Warning: NixOS detected, skipping GLIBC check"
exit 0
fi
# Based on https://github.com/bminor/glibc/blob/520b1df08de68a3de328b65a25b86300a7ddf512/elf/cache.c#L162-L245
case $ARCH in
x86_64) LDCONFIG_ARCH="x86-64";;