Skip to content

Android: NDK CI runner — per-ABI build + emulator smoke test of the four handler paths #67

@hyperpolymath

Description

@hyperpolymath

Context

The Android backend is now real (JNI vtable in jni.zig, backend routed by abi == .android, NDK-aware build.zig) and the non-UI component hosts (Service/Receiver/Widget) have landed with host-runnable logic tests. See the design doc: docs/architecture/android-components.adoc.

What CI cannot currently verify, because there is no NDK/emulator on the runners:

  • that libgossamer.so actually links for each ABI (aarch64-linux-android, x86_64-linux-android, arm-linux-androideabi);
  • that webview_android.zig compiles for an *-android target (it can't be host-compiled — it depends on the Android-flavoured GossamerHandle);
  • that the four handler paths (webview IPC, Service, Receiver, Widget) dispatch on a device.

Asks

  1. Build job: a workflow that installs the Android NDK (r26+) and runs just android-build (i.e. zig build -Dtarget=<abi>-linux-android for the three ABIs). Non-blocking at first, promote to required once stable.
  2. Emulator smoke test: boot an x86_64 emulator (API 26/34), install a tiny harness APK built from generated/android/, and assert:
    • JS postMessage round-trips through GossamerBridge;
    • gossamer_service_bind("onStartCommand", …) fires and the foreground notification appears;
    • gossamer_receiver_bind("android.intent.action.BOOT_COMPLETED", …) fires;
    • gossamer_widget_bind("onUpdate", …) renders the RemoteViews directive.

Notes

  • minSdk 26, targetSdk 34, ABIs arm64-v8a / x86_64 / armeabi-v7a (matches neurophone#83).
  • Symbol parity (generated native ↔ Zig export fn Java_*) is already checked in the PR; this issue is about runtime validation.

Part of the Phase 5 readiness checklist. Blocks a confident "neurophone can depend on gossamer-Android" verdict.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions