Skip to content

Android link test: every ABI a release ships, under every memory model - #822

Merged
ASDAlexander77 merged 1 commit into
mainfrom
android-link-all
Nov 12, 2026
Merged

ASDAlexander77 merged 1 commit into
mainfrom
android-link-all

Conversation

@ASDAlexander77

Copy link
Copy Markdown
Owner

The release's Android link test covered x86_64 only, under gc and own. It now covers every ABI a release ships, under every memory model.

What test-compile-android-link does now

The test links a small program twice: as an executable, and as a shared library with --no-undefined.

  • It links for each ABI: arm64-v8a (aarch64-linux-android29), armeabi-v7a (armv7a-linux-androideabi29) and x86_64 (x86_64-linux-android29).
  • It links under each memory model: gc, rc, none and own. That makes 24 binaries.
  • It uses the default library, collector and async runtime that the release builds for that ABI.
  • It checks that each binary is ELF and has its ABI's e_machine: AArch64, ARM or x86-64. A link for the wrong architecture fails.

As before, the test is skipped unless the NDK and all the libraries are present, and the release's "Test Compiler for Android" step fails on a skip. The release already builds every one of these libraries: all three ABIs in the collector and runtime scripts, and all ABIs and models in build_android.bat. So no build step changes; only that step's comment does.

Testing

Run locally with NDK r30:

  • The libraries were built with the release's own scripts: the collector and async runtime for armeabi-v7a (the other two ABIs were already built), and the default library for all three ABIs under all four models, in release mode.
  • ctest -C Release -R test-compile-android- passes both tests; the link test takes 3.2 s.
  • I checked the 24 binaries separately: each has the expected ELF machine.

It still only links; nothing runs on Android. A program that small pulls in only part of the default library, so a function Bionic lacks is caught only in the parts it links.

🤖 Generated with Claude Code

test-compile-android-link linked x86_64 only, under gc and own. It now links an executable and a
shared library for arm64-v8a, armeabi-v7a and x86_64 under gc, rc, none and own (24 binaries)
with the default library, collector and async runtime the release builds, and checks that each
is an ELF file for its ABI's machine. It skips, as before, until all of them are built; the
release step fails on a skip.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@ASDAlexander77
ASDAlexander77 merged commit 9a855e8 into main Nov 12, 2026
7 of 8 checks passed
@ASDAlexander77
ASDAlexander77 deleted the android-link-all branch November 12, 2026 12:01
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.

1 participant