Skip to content

Commit e844dc1

Browse files
Cross-compile for aarch64-linux.
This architecture has a different c_char: u8, rather than i8. Due to rust-lang/rust#113735, this causes a build breakage, since CStr::from_ptr was documented to take an i8 but actually takes a c_char.
1 parent dff28a9 commit e844dc1

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

.github/workflows/build.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,3 +66,24 @@ jobs:
6666
shell: bash
6767
run: rustup run ${{ matrix.rust }} cargo run -p systest
6868

69+
build_arm_linux:
70+
name: Cross-compile for aarch64 linux
71+
72+
runs-on: ubuntu-20.04
73+
74+
steps:
75+
- uses: actions/checkout@v2
76+
with:
77+
submodules: recursive
78+
79+
- name: Install Rust
80+
shell: bash
81+
run: rustup target add aarch64-unknown-linux-gnu
82+
83+
- name: Install crossbuild headers
84+
shell: bash
85+
run: sudo apt-get update && sudo apt-get install -y crossbuild-essential-arm64
86+
87+
- name: Build cross compile aarch64
88+
shell: bash
89+
run: cargo build --all --target aarch64-unknown-linux-gnu

0 commit comments

Comments
 (0)