Skip to content

Commit d87c626

Browse files
committed
Add linux aarch64 target to test and release
1 parent 763c8b9 commit d87c626

2 files changed

Lines changed: 16 additions & 7 deletions

File tree

.github/workflows/bindgen.yml

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ jobs:
9595
runs-on: ${{matrix.os}}
9696
strategy:
9797
matrix:
98-
os: [ubuntu-latest, macos-latest]
98+
os: [ubuntu-latest, ubuntu-24.04-arm, macos-latest]
9999
steps:
100100
- uses: actions/checkout@v4
101101

@@ -106,7 +106,7 @@ jobs:
106106
runs-on: ${{matrix.os}}
107107
strategy:
108108
matrix:
109-
os: [ubuntu-latest]
109+
os: [ubuntu-latest, ubuntu-24.04-arm]
110110
llvm_version: ["9.0", "16.0"]
111111
release_build: [0, 1]
112112
no_default_features: [0, 1]
@@ -116,6 +116,14 @@ jobs:
116116
feature_extra_asserts: [0]
117117

118118
include:
119+
- os: ubuntu-latest
120+
libtinfo: libtinfo5_6.3-2ubuntu0.1_amd64.deb
121+
ubuntu_repo: https://mirrors.kernel.org/ubuntu/pool/universe/n/ncurses/
122+
123+
- os: ubuntu-24.04-arm
124+
libtinfo: libtinfo5_6.3-2ubuntu0.1_arm64.deb
125+
ubuntu_repo: https://ports.ubuntu.com/ubuntu/pool/universe/n/ncurses/
126+
119127
# Test with extra asserts + docs just with latest llvm versions to
120128
# prevent explosion
121129
- os: ubuntu-latest
@@ -138,10 +146,10 @@ jobs:
138146
with:
139147
toolchain: stable
140148
- name: Install libtinfo
141-
if: matrix.os == 'ubuntu-latest'
149+
if: startsWith(matrix.os, 'ubuntu')
142150
run: |
143-
wget https://mirrors.kernel.org/ubuntu/pool/universe/n/ncurses/libtinfo5_6.3-2ubuntu0.1_amd64.deb
144-
sudo dpkg -i libtinfo5_6.3-2ubuntu0.1_amd64.deb
151+
wget ${{matrix.ubuntu_repo}}${{matrix.libtinfo}}
152+
sudo dpkg -i ${{matrix.libtinfo}}
145153
- name: Install LLVM and Clang
146154
uses: KyleMayes/install-llvm-action@v2.0.5
147155
with:
@@ -153,7 +161,7 @@ jobs:
153161
BINDGEN_FEATURE_RUNTIME: ${{matrix.feature_runtime}}
154162
BINDGEN_FEATURE_EXTRA_ASSERTS: ${{matrix.feature_extra_asserts}}
155163
BINDGEN_NO_DEFAULT_FEATURES: ${{matrix.no_default_features}}
156-
BINDGEN_RUST_FOR_LINUX_TEST: ${{matrix.os == 'ubuntu-latest' && matrix.llvm_version == '16.0' && matrix.feature_extra_asserts == 0 && 1 || 0}}
164+
BINDGEN_RUST_FOR_LINUX_TEST: ${{startsWith(matrix.os, 'ubuntu') && matrix.llvm_version == '16.0' && matrix.feature_extra_asserts == 0 && 1 || 0}}
157165
run: ./ci/test.sh
158166

159167
test-book:

dist-workspace.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ ci = "github"
1010
# The installers to generate for each app
1111
installers = ["shell"]
1212
# Target platforms to build apps for (Rust target-triple syntax)
13-
targets = ["aarch64-apple-darwin", "x86_64-apple-darwin", "x86_64-unknown-linux-gnu"]
13+
targets = ["aarch64-apple-darwin", "aarch64-unknown-linux-gnu", "x86_64-apple-darwin", "x86_64-unknown-linux-gnu"]
1414
# Whether to consider the binaries in a package for distribution (defaults true)
1515
dist = false
1616
# Which actions to run on pull requests
@@ -23,3 +23,4 @@ install-path = "CARGO_HOME"
2323
[dist.github-custom-runners]
2424
aarch64-apple-darwin = "macos-14"
2525
x86_64-apple-darwin = "macos-13"
26+
aarch64-unknown-linux-gnu = "ubuntu-24.04-arm"

0 commit comments

Comments
 (0)