From d2c978ab3b4e612578290bdb79f52018fdd67ba0 Mon Sep 17 00:00:00 2001 From: messense Date: Sat, 18 Jan 2025 21:08:16 +0800 Subject: [PATCH 1/2] Run tests on GitHub hosted arm64 Linux runner --- .github/workflows/ci.yml | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 14531d17144..bea49f52de1 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -102,6 +102,11 @@ jobs: python-architecture: "x64", rust-target: "x86_64-unknown-linux-gnu", }, + { + os: "ubuntu-22.04-arm", + python-architecture: "arm64", + rust-target: "aarch64-unknown-linux-gnu", + }, { os: "ubuntu-latest", python-architecture: "x64", @@ -193,6 +198,11 @@ jobs: python-architecture: "x64", rust-target: "x86_64-unknown-linux-gnu", }, + { + os: "ubuntu-22.04-arm", + python-architecture: "arm64", + rust-target: "aarch64-unknown-linux-gnu", + }, { os: "windows-latest", python-architecture: "x64", @@ -348,6 +358,15 @@ jobs: python-architecture: "x64", rust-target: "x86_64-apple-darwin", } + # arm64 Linux runner is in public preview, so test 3.13 on it + - rust: stable + python-version: "3.13" + platform: + { + os: "ubuntu-22.04-arm", + python-architecture: "arm64", + rust-target: "aarch64-unknown-linux-gnu", + } exclude: # ubuntu-latest (24.04) no longer supports 3.7 From 5ae6491aabd04d29a8c6df67a3d70fe022fa9b30 Mon Sep 17 00:00:00 2001 From: messense Date: Sat, 18 Jan 2025 21:26:09 +0800 Subject: [PATCH 2/2] Upgrade bindgen to 0.69.4 in pyo3-ffi-check --- pyo3-ffi-check/Cargo.toml | 2 +- pyo3-ffi-check/build.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pyo3-ffi-check/Cargo.toml b/pyo3-ffi-check/Cargo.toml index 776add0c910..874da3d2bef 100644 --- a/pyo3-ffi-check/Cargo.toml +++ b/pyo3-ffi-check/Cargo.toml @@ -13,7 +13,7 @@ path = "../pyo3-ffi" features = ["extension-module"] # A lazy way of skipping linking in most cases (as we don't use any runtime symbols) [build-dependencies] -bindgen = "0.66.1" +bindgen = "0.69.4" pyo3-build-config = { path = "../pyo3-build-config" } [workspace] diff --git a/pyo3-ffi-check/build.rs b/pyo3-ffi-check/build.rs index 072e8c072b0..67808888e1e 100644 --- a/pyo3-ffi-check/build.rs +++ b/pyo3-ffi-check/build.rs @@ -28,7 +28,7 @@ fn main() { let bindings = bindgen::Builder::default() .header("wrapper.h") .clang_args(clang_args) - .parse_callbacks(Box::new(bindgen::CargoCallbacks)) + .parse_callbacks(Box::new(bindgen::CargoCallbacks::new())) // blocklist some values which apparently have conflicting definitions on unix .blocklist_item("FP_NORMAL") .blocklist_item("FP_SUBNORMAL")