-
Notifications
You must be signed in to change notification settings - Fork 23
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Download correct musl toolchain
- Loading branch information
1 parent
5c82762
commit c7e1bd1
Showing
2 changed files
with
36 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -117,14 +117,27 @@ jobs: | |
run: | | ||
TMP_DIR=$(mktemp -d) | ||
pushd $TMP_DIR | ||
curl -LOJ http://more.musl.cc/10/x86_64-linux-musl/x86_64-linux-musl-native.tgz | ||
tar -xvf x86_64-linux-musl-native.tgz | ||
case $MATRIX_OS in | ||
ubuntu-latest) | ||
curl -LOJ https://musl.cc/x86_64-linux-musl-native.tgz | ||
tar -xvf x86_64-linux-musl-native.tgz | ||
TOOLCHAIN_DIR=$TMP_DIR/x86_64-linux-musl-native | ||
;; | ||
linux-arm64) | ||
curl -LOJ https://musl.cc/aarch64-linux-musl-native.tgz | ||
tar -xvf aarch64-linux-musl-native.tgz | ||
TOOLCHAIN_DIR=$TMP_DIR/aarch64-linux-musl-native | ||
;; | ||
*) | ||
echo 'Unexpected CPU architecture! | ||
exit 1 | ||
;; | ||
esac | ||
curl -LOJ https://zlib.net/fossils/zlib-1.3.tar.gz | ||
tar -xzf zlib-1.3.tar.gz | ||
cd zlib-1.3 | ||
TOOLCHAIN_DIR=$TMP_DIR/x86_64-linux-musl-native | ||
CC=$TOOLCHAIN_DIR/bin/gcc | ||
./configure --prefix=$TOOLCHAIN_DIR --static | ||
|
@@ -133,6 +146,8 @@ jobs: | |
echo "TOOLCHAIN_DIR=$TOOLCHAIN_DIR" >> $GITHUB_OUTPUT | ||
if: matrix.os == 'ubuntu-latest' || matrix.os == 'linux-arm64' | ||
env: | ||
MATRIX_OS: ${{ matrix.os }} | ||
|
||
- name: Cache Maven packages | ||
uses: actions/[email protected] | ||
|