Skip to content

Commit c3b9d45

Browse files
authoredDec 27, 2024··
build aarch64 binary (#241)
Signed-off-by: usamoi <[email protected]>
1 parent d4121e8 commit c3b9d45

File tree

1 file changed

+16
-3
lines changed

1 file changed

+16
-3
lines changed
 

‎.github/workflows/release.yml

+16-3
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,12 @@ jobs:
4949
fail-fast: false
5050
matrix:
5151
include:
52-
- os: ubuntu-20.04
52+
- os: ubuntu-22.04
5353
rust: stable
5454
target: x86_64-unknown-linux-musl
55+
- os: ubuntu-22.04
56+
rust: stable
57+
target: aarch64-unknown-linux-musl
5558
- os: macos-latest
5659
rust: stable
5760
target: x86_64-apple-darwin
@@ -68,10 +71,20 @@ jobs:
6871
with:
6972
fetch-depth: 1
7073
- name: Install packages (Ubuntu)
71-
if: matrix.os == 'ubuntu-20.04'
74+
if: matrix.os == 'ubuntu-22.04'
7275
run: |
76+
sudo dpkg --add-architecture arm64
77+
cat <<EOL | sudo tee "/etc/apt/sources.list"
78+
deb [arch=amd64] http://azure.archive.ubuntu.com/ubuntu jammy main restricted universe multiverse
79+
deb [arch=amd64] http://azure.archive.ubuntu.com/ubuntu jammy-updates main restricted universe multiverse
80+
deb [arch=amd64] http://azure.archive.ubuntu.com/ubuntu jammy-security main restricted universe multiverse
81+
deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports jammy main restricted universe multiverse
82+
deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports jammy-updates main restricted universe multiverse
83+
deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports jammy-security main restricted universe multiverse
84+
EOL
7385
sudo apt-get update
74-
sudo apt-get install -y --no-install-recommends xz-utils liblz4-tool musl-tools
86+
sudo apt-get install -y --no-install-recommends xz-utils liblz4-tool musl-tools musl-dev musl-dev:arm64
87+
echo "RUSTFLAGS=-Clinker=rust-lld" >> $GITHUB_ENV
7588
- name: Install Rust
7689
uses: actions-rs/toolchain@v1
7790
with:

0 commit comments

Comments
 (0)
Please sign in to comment.