Skip to content

Commit

Permalink
Attempt to use xctoolchain for clang32 bootstrap
Browse files Browse the repository at this point in the history
  • Loading branch information
dhinakg committed May 7, 2024
1 parent f872258 commit f57abfb
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions clang32-bootstrap.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ CHMOD="/bin/chmod"
CURL="/usr/bin/curl"
MKDIR="/bin/mkdir"
RM="/bin/rm"
UNZIP="/usr/bin/unzip"
TAR="/usr/bin/tar"

if [ -z "${OVERRIDE_PYTHON3}" ]; then
# Use whatever is in PATH
Expand All @@ -27,7 +27,7 @@ CLANG32_SCRIPTS=(
"libtool32"
)

CLANG32_ZIP="clang-12.zip"
CLANG32_ZIP="ACID32.xctoolchain.tar.xz"

"${CURL}" -LfsO "https://github.com/acidanthera/ocbuild/releases/download/llvm-kext32-latest/${CLANG32_ZIP}" || ret=$?
if [ $ret -ne 0 ]; then
Expand All @@ -39,7 +39,7 @@ if [ $ret -ne 0 ]; then
abort "Failed to create clang32 directory with code ${ret}"
fi

"${UNZIP}" -q "${CLANG32_ZIP}" -d "${CLANG32_DIR}" || ret=$?
"${TAR}" -xf "${CLANG32_ZIP}" -C "${CLANG32_DIR}" || ret=$?
if [ $ret -ne 0 ]; then
abort "Failed to extract downloaded clang32 with code ${ret}"
fi
Expand All @@ -64,3 +64,5 @@ done
if [ $ret -ne 0 ]; then
abort "Failed to install macholib with code ${ret}"
fi

echo "EXTERNAL_TOOLCHAINS_DIR=${!CLANG32_DIR}" >> "$GITHUB_ENV"

0 comments on commit f57abfb

Please sign in to comment.