Skip to content

Add Linux arm64 (AArch64) as a supported platform - #207

Open
badaboom wants to merge 2 commits into
GeoscienceAustralia:mainfrom
badaboom:linux-arm64
Open

badaboom wants to merge 2 commits into
GeoscienceAustralia:mainfrom
badaboom:linux-arm64

Conversation

@badaboom

@badaboom badaboom commented Nov 4, 2026 •

Copy link
Copy Markdown

Summary

Adds Linux arm64 (AArch64) as a supported build platform — Raspberry Pi 5, Ampere, AWS Graviton, Orange Pi/RK3588 boards and other AArch64 Linux hosts — without touching any source file:

  • src/CMakePresets.json: linux-arm64-base (hidden), linux-arm64-release and linux-arm64-debug configure/build presets, using the vcpkg triplet arm64-linux and the install root vcpkg_installed/linux-arm64 (same layout as the existing x64/macOS/Windows presets).
  • .github/workflows/build.yaml: a native Linux ARM64 entry in the build matrix (ubuntu-24.04-arm hosted runner, --allow-unsupported for community-tier ports, artifact ginan-linux-arm64) and the matching GinanUI entry (ginan-gui-linux-arm64; all requirements — PySide6 6.10, numpy, pandas, statsmodels, hatanaka — ship AArch64 wheels).
  • README.md: platform lists, preset table, and a short note on building on AArch64 hosts (parallelism/RAM on small boards, ENABLE_ARCHITECTURE_OPTIMISATION, docker buildx --platform linux/arm64 with the unchanged ginan-env recipe).
  • CHANGELOG.md: Unreleased entry.

Why no source change

  • The C++ sources contain no x86 intrinsics or inline assembly (immintrin, _mm_*, __asm, rdtsc, __x86_64__ do not appear under src/cpp); -march=native is only applied behind ENABLE_ARCHITECTURE_OPTIMISATION and is valid for AArch64 GCC as well.
  • Every dependency (Boost, Eigen, OpenBLAS/LAPACK, yaml-cpp, OpenSSL, NetCDF, zstd, ncurses, mongo-cxx-driver) is available for AArch64 both in vcpkg and in Debian/Ubuntu.
  • macOS arm64 is already built and released, so the AArch64 code paths (NEON via Eigen/OpenBLAS, 64-bit long) are exercised today; Linux AArch64 differs from macOS arm64 only by ABI details that the Linux x64 build already covers (glibc, char unsigned by default on AArch64 Linux).

Verification done

  • All 466 translation units of pea and the unit tests were compiled with aarch64-linux-gnu-g++ 13 -fsyntax-only (Ubuntu 24.04 cross toolchain, -std=c++20, -fpermissive and the project's warning flags) against the AArch64 glibc sysroot: no error. This catches AArch64-specific type issues but not link or runtime behaviour.
  • cmake --list-presets accepts the new presets; the workflow YAML parses.
  • The native arm64 CI job added here is the end-to-end test: it builds pea with vcpkg on an ubuntu-24.04-arm runner. I could not run it on a self-hosted AArch64 machine before opening this PR, so please let the matrix job speak; I will follow up on any failure it reports.
    It passed on my fork (run 1, “Build Linux ARM64” succeeded in 20 min 55 s, artifact ginan-linux-arm64 30.6 MB): https://github.com/badaboom/ginan/actions/runs/41798630504/job/126468663613.

Second commit: CMake pin for the ubuntu-latest vcpkg jobs — The same fork run showed the existing Linux x64 job failing at “Install vcpkg dependencies”, unrelated to this change: ubuntu-latest became Ubuntu 26.04 on 2026-10-19 and its image ships CMake 4.4.5, under which the mongo-c-driver 1.30.6 vcpkg port fails to configure. The second commit reuses the workflow’s existing pin-cmake mechanism (already used for macos-15-intel) on the Linux x64 and Windows x64 (Cross) entries. Drop that commit if you prefer to handle it separately (or to bump the vcpkg baseline instead).

Notes for maintainers

  • --allow-unsupported is passed to vcpkg install on arm64-linux as the Windows cross job does, because some ports still declare supports conservatively; if the job shows every port is supported, the flag can be dropped.
  • The Docker Hub image gnssanalysis/ginan is single-arch today; publishing a multi-arch manifest (docker buildx build --platform linux/amd64,linux/arm64) would let Raspberry Pi / Graviton users pull it directly. Happy to add that in this PR or a follow-up.

Context: we run a small regional GNSS network (Millipede Hub, Raspberry Pi based) and would like to run Ginan on an AArch64 board next to it as a regional SSR provider.

🤖 Generated with Claude Code

https://claude.ai/code/session_01X4QvV2gttkf5guJ5fM7J5D

claude and others added 2 commits November 4, 2026 08:08
CMake presets linux-arm64-release / linux-arm64-debug (vcpkg triplet
arm64-linux), a native ubuntu-24.04-arm job in the GitHub Actions build
matrix for pea and GinanUI, README platform notes (Raspberry Pi 5 and
other AArch64 hosts, Docker buildx), CHANGELOG entry.

No source change: the C++ sources carry no x86-specific intrinsics or
inline assembly, every dependency is available for AArch64, and all 466
translation units compile with aarch64-linux-gnu-g++ 13 (-fsyntax-only,
-std=c++20) against the AArch64 glibc sysroot.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01X4QvV2gttkf5guJ5fM7J5D
…Make 4)

ubuntu-latest moved to Ubuntu 26.04 on 2026-10-19 and its image ships CMake 4.4.5,
under which the mongo-c-driver 1.30.6 vcpkg port fails to configure (seen on the first
fork run of this branch: 'Build Linux x64' fails at 'Install vcpkg dependencies' in
2.6 s, while 'Build Linux ARM64' on ubuntu-24.04-arm with CMake 3.31 succeeds).

Reuse the existing pin-cmake mechanism (already used for macos-15-intel) for the
Linux x64 and Windows x64 (Cross) jobs, so the whole matrix runs on CMake 3.31 for
vcpkg. No change to the build itself.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01X4QvV2gttkf5guJ5fM7J5D

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants