Skip to content

Instantly share code, notes, and snippets.

View itsHanibee's full-sized avatar
:shipit:
busy irl, reach me on my mail if time-sensitive

hani itsHanibee

:shipit:
busy irl, reach me on my mail if time-sensitive
View GitHub Profile
@itsHanibee
itsHanibee / patch-for-old-glibc.sh
Last active May 25, 2023 08:39 — forked from beakthoven/patch-for-old-glibc.sh
A script for patching toolchains to resolve glibc requirement issues on distros with old glibc packages. The script must be placed in the toolchain directory and then executed.
#!/usr/bin/env bash
WORK_DIR=$(pwd)
cd "$HOME" || exit
echo "Downloading patchelf binary from ArchLinux repos"
mkdir -p patchelf-temp
#curl -L https://github.com/Jebaitedneko/docker/raw/ubuntu/patchelf
curl -L https://archlinux.org/packages/extra/x86_64/patchelf/download | bsdtar -C patchelf-temp -xf -
mv "$HOME"/patchelf-temp/usr/bin/patchelf "$HOME"/
rm -rf "$HOME"/patchelf-temp