Skip to content

Commit b4dec18

Browse files
jdxclaude
andcommitted
fix(build): install bindgen-cli on CI hosts for ARM builds
Instead of trying to install bindgen in cross containers during pre-build, install it on the GitHub Actions runner where it's needed. This resolves the issue where cargo isn't available during Docker image build phase. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
1 parent ec73c70 commit b4dec18

File tree

2 files changed

+2
-36
lines changed

2 files changed

+2
-36
lines changed

.github/workflows/release.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,8 @@ jobs:
8080
- if: matrix.runs-on == 'ubuntu-latest'
8181
uses: taiki-e/install-action@0aa4f22591557b744fe31e55dbfcdfea74a073f7 # v2
8282
with: { tool: cross }
83+
- if: matrix.runs-on == 'ubuntu-latest' && (contains(matrix.target, 'arm') || contains(matrix.target, 'aarch64'))
84+
run: cargo install --force --locked bindgen-cli
8385
- name: build-tarball
8486
uses: nick-fields/retry@ce71cc2ab81d554ebbe88c79ab5975992d79ba08 # v3
8587
with:

Cross.toml

Lines changed: 0 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -1,38 +1,2 @@
11
[build.env]
22
passthrough = ["AWS_ACCESS_KEY_ID", "AWS_SECRET_ACCESS_KEY"]
3-
4-
[target.armv7-unknown-linux-gnueabi]
5-
pre-build = [
6-
"apt-get update && apt-get --assume-yes install libclang-dev",
7-
"$CARGO install --force --locked bindgen-cli",
8-
]
9-
10-
[target.armv7-unknown-linux-musleabi]
11-
pre-build = [
12-
"apt-get update && apt-get --assume-yes install libclang-dev",
13-
"$CARGO install --force --locked bindgen-cli",
14-
]
15-
16-
[target.aarch64-unknown-linux-gnu]
17-
pre-build = [
18-
"apt-get update && apt-get --assume-yes install libclang-dev",
19-
"$CARGO install --force --locked bindgen-cli",
20-
]
21-
22-
[target.aarch64-unknown-linux-musl]
23-
pre-build = [
24-
"apt-get update && apt-get --assume-yes install libclang-dev",
25-
"$CARGO install --force --locked bindgen-cli",
26-
]
27-
28-
[target.x86_64-unknown-linux-gnu]
29-
pre-build = [
30-
"apt-get update && apt-get --assume-yes install libclang-dev",
31-
"$CARGO install --force --locked bindgen-cli",
32-
]
33-
34-
[target.x86_64-unknown-linux-musl]
35-
pre-build = [
36-
"apt-get update && apt-get --assume-yes install libclang-dev",
37-
"$CARGO install --force --locked bindgen-cli",
38-
]

0 commit comments

Comments
 (0)