Add Linux ARM64 (aarch64) native build support - #1561
Conversation
Port ARM64 build support from mvnd-1.x PR #1527 to master: - Add ubuntu-24.04-arm runner for Linux ARM64 builds - Fix broken matrix exclude rules (macos-latest→macos-15, windows-latest→windows-2025) - Add glibc.redef.aarch64 pinning all symbols to GLIBC_2.17 - Add #if defined(__aarch64__) conditional in dynamic-libc-start.c - Add uname -m arch detection in gcc wrapper script - Add linux-aarch64-image-only-require-glibc-2.17 profile in client/pom.xml - Add ARM64 glibc patch/verify steps in CI workflows - Add linux-aarch64 release asset upload steps Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
gnodet
left a comment
There was a problem hiding this comment.
This PR needs a rebase — most of the changes are now superseded by commit 99bd55d ("Fix CI: GraalVM 25 native builds with glibc backward compatibility", PR #1611) which already landed on master.
Merge state: DIRTY/CONFLICTING
Superseded changes (drop after rebase):
early-access.yaml— master already has full ARM64 supportdynamic-libc-start.c— aarch64 symver directives already on masterglibc.redef.aarch64— master has all entries plusstat stat@GLIBC_2.17gccwrapper — master uses a separategcc-aarch64wrapper instead of modifying the shared oneclient/pom.xmlprofile rename — master keeps the original name; ARM64 profilelinux-image-only-require-glibc-2.17already exists
Genuinely needed: Adding ARM64 support to release.yaml (ARM runner, glibc patching, verification, deploy steps). However, the current implementation uses patterns that are incompatible with GraalVM 25:
-
Hardcoded
ls -1for svm/clibraries — GraalVM 25 removedlibjvm.aandliblibchelper.a. Master'searly-access.yamlusesfind ... -name '*.a' 2>/dev/nullinstead. -
ldd4-library count check — Intentionally removed from master because GraalVM 25 with+StaticExecutableWithDynamicLibConly dynamically linkslibc.so. This check will fail. -
Missing
stat stat@GLIBC_2.17inglibc.redef.aarch64— Without this, the ARM64 binary requires glibc 2.33+ for stat(). -
Missing
stat-compat.cshim — Master'searly-access.yamlcompiles and links this to handle GraalVM 25'sstat@GLIBC_2.33dependency. -
Re-introduces
macos-15-intel— Oracle dropped macOS x64 support in GraalVM 25.0.2+. This was intentionally removed from master.
Suggested path forward: Rebase onto current master, drop all changes already merged via #1611, and rework the release.yaml ARM64 additions to mirror early-access.yaml's working GraalVM 25 patterns.
This review was generated by an AI agent and may contain inaccuracies. Please verify all suggestions before applying.
Claude Code on behalf of gnodet
gnodet
left a comment
There was a problem hiding this comment.
This PR is largely superseded by commit 99bd55d (PR #1611) already on master, which added comprehensive ARM64 + GraalVM 25 support. In its current state, the PR would re-introduce GraalVM 25 build failures.
Key issues (all verified independently):
-
early-access.yaml fully superseded — Master already has
ubuntu-24.04-arm, arch-conditional glibc patching, ARM64 verification, and removedmacos-15-intel. This PR re-introducesmacos-15-intelwhich will fail (Oracle dropped macOS x64 GraalVM 25 support). -
Missing
stat stat@GLIBC_2.17— Master'sglibc.redef.aarch64includes this because GraalVM 25 links againststat@GLIBC_2.33. Without it, the ARM64 binary requires glibc 2.33+, defeating the purpose of pinning. -
Hardcoded
ls -1for GraalVM library files — GraalVM 25 removedlibjvm.a/liblibchelper.a. Master switched tofind. Affects bothearly-access.yamlandrelease.yaml. -
ldd 4-library count assertion — GraalVM 25 with
+StaticExecutableWithDynamicLibConly linkslibc.so. The(( 4 == ... ))check fails. Master removed it. Affects bothearly-access.yamlandrelease.yaml. -
Profile rename conflicts with master — Renaming
linux-image-only-require-glibc-2.12conflicts with master which keeps the original name.
Remaining unique value:
The PR has two improvements worth preserving:
- ARM64 deploy steps in
release.yaml(not yet on master) - ARM64 verification regex
2\.1[0-7]is more correct than master's2\.1[017](master's character class only allows 2.10, 2.11, 2.17, not the full range 2.10–2.17)
Recommendation: Rebase onto master, drop all changes already merged via #1611, and rework the release.yaml ARM64 additions to use master's GraalVM 25-compatible patterns.
This review was generated by an AI agent and may contain inaccuracies. Please verify all suggestions before applying.
Claude Code on behalf of gnodet
gnodet
left a comment
There was a problem hiding this comment.
This PR appears to be superseded by commit 99bd55d ("Fix CI: GraalVM 25 native builds with glibc backward compatibility (#1611)"), which was merged to master on May 19, 2026 — two months after this PR was opened.
The PR is currently in CONFLICTING merge state and cannot be merged as-is. Key issues after verification:
-
Merge conflicts — master's
early-access.yaml,release.yaml,client/pom.xml,glibc.redef.aarch64, and gcc wrapper already contain ARM64 support from commit 99bd55d. -
Missing
stat stat@GLIBC_2.17entry — master added this inglibc.redef.aarch64to handle GraalVM 25's directstat()call against glibc 2.33+ headers. Without it, the ARM64 binary would require glibc 2.33 forstat(). -
Re-adds
macos-15-intel— removed on master because Oracle dropped macOS x64 support in GraalVM 25.0.2+. -
Retains
(( 4 == ... ))ldd library count assertion — master removed this because GraalVM 25 with+StaticExecutableWithDynamicLibConly dynamically linkslibc.so. -
Design divergence — PR uses single
gccwrapper withuname -mdetection; master uses separategcc-aarch64script.
Positive note: the PR's ARM64 verify regex [0-7] is more correct than master's [017] for matching glibc 2.10-2.17 versions — consider backporting this fix.
This PR should likely be closed as superseded, or rebased and reduced to only the release workflow ARM64 changes if those are still needed.
This review was generated by an AI agent and may contain inaccuracies. Please verify all suggestions before applying.
Claude Code on behalf of Guillaume Nodet
gnodet
left a comment
There was a problem hiding this comment.
AI Review — Needs Rework
This PR (created March 2026) adds Linux ARM64 native build support but has been largely superseded by commit 99bd55d (PR #1611, merged May 2026), which independently added ARM64 support with additional GraalVM 25 fixes. The PR is in CONFLICTING merge state and cannot be merged as-is.
Confirmed Issues
Functional (would cause CI failures):
-
Hardcoded
ls -1for libjvm.a/liblibchelper.a — GraalVM 25 removed these files. Master already switched tofind ... -name '*.a'. The patching step will fail. -
4-library ldd assertion — GraalVM 25 with
+StaticExecutableWithDynamicLibConly dynamically links libc.so. Master already removed this assertion. The verification step will fail. -
Missing
stat stat@GLIBC_2.17inglibc.redef.aarch64— Master's version includes this line. Without it, the ARM64 binary would require glibc 2.33+ forstat()calls, breaking backward compatibility. -
Re-introduces
macos-15-intel— Oracle dropped macOS x64 GraalVM support in 25.0.2+. Master intentionally removed this runner.
Design differences (merge conflicts):
- Profile renamed
linux-image-only-require-glibc-2.12→linux-amd64-...— master kept the original name. - PR modifies shared
gccwrapper withuname -mdetection — master uses a separategcc-aarch64script. dynamic-libc-start.caarch64 directives already on master — redundant change.
What's Still Valuable
The release.yaml ARM64 additions (deploy assets, ARM64 patching/verification steps) are NOT on master and would still be needed. However, they require the same GraalVM 25 fixes before they can work.
Also, the PR's verify regex 2\.1[0-7] is actually more correct than master's 2\.1[017] (which misses versions 2.12-2.16).
Recommendation
Rebase onto current master, drop all superseded changes, and rework the release.yaml ARM64 additions to mirror early-access.yaml's working GraalVM 25 patterns.
This review was generated by an AI agent and may contain inaccuracies. Please verify all suggestions before applying.
Claude Code on behalf of Guillaume Nodet
Summary
Port of #1527 (ARM64 builds for mvnd-1.x) to the master branch:
ubuntu-24.04-armto the build matrix for native Linux ARM64 buildsmacos-latestandwindows-latestinstead of actual runner names (macos-15,windows-2025)glibc.redef.aarch64that pins all symbols toGLIBC_2.17(the first glibc version with ARM64 support)#if defined(__aarch64__)indynamic-libc-start.cfor correctdlsym/dlvsymsymveruname -mdetection to select the correct redef filelinux-aarch64-image-only-require-glibc-2.17profile inclient/pom.xmlTest plan
🤖 Generated with Claude Code