Skip to content

Kotlin/Native Linux cells, and the Linux chrome and reader checks, in the native-image gate - #65

Open
b-re-w wants to merge 1 commit into
extendedfrom
feat/linux-chrome-kn-cells
Open

b-re-w wants to merge 1 commit into
extendedfrom
feat/linux-chrome-kn-cells

Conversation

@b-re-w

@b-re-w b-re-w commented Oct 18, 2026

Copy link
Copy Markdown
Member

Closes #64

Kotlin/Native cells

  • "Build (Kotlin/Native, linux-x64 and linux-arm64)" builds extended/native-desktop/hello-awtfree as an Amper module of the core fork's window project (copied into extended/window/samples/ of the checkout, scene built as its Linux module). Its content is hello-awtfree's own Content.kt and TextSelfCheck.kt, linked. A klib is read only by the compiler that wrote it or a newer one, which is why it uses the core fork's toolchain rather than a Gradle build. arm64 is cross compiled on x86-64 (Kotlin/Native has no arm64 Linux host) and linked against the arm64 desktop libraries from the ports archive.
  • "One executable (Kotlin/Native, linux-x64)" and "(Kotlin/Native, linux-arm64)" run check-one-executable.sh on their own architecture, as the GraalVM cells do, then the chrome and reader check.

Linux chrome and reader check (FR-19.4, FR-19.7, NFR-8)

check-linux-chrome.sh, on every Linux cell (GraalVM x64 and arm64, Kotlin/Native x64 and arm64), on a virtual display and its own session bus with openbox and at-spi2:

  • no window manager title bar under the default WindowChrome.Modern (_NET_FRAME_EXTENTS all zero);
  • a caption drag moves the window by the pointer's distance, each edge and corner resizes from that side only, a double click maximises and a second restores (core fork extended/window/scripts/wm-chrome.sh);
  • the window's own count: at least eight sizes, stale=0, stretched=0, and no frame presented at a size other than the window's;
  • libatspi walks the tree (core fork extended/window/scripts/atspi-readback.c): entry "Name", label "Name", push button "click me", the caption's Minimize/Maximize/Close; sets the field, presses the button, and closes the window through Close.

hello-awtfree: content moved to Content.kt, the field labelled "Name", HELLO_RUN_SECONDS mode for the driven check. The scene platform patch now matches any list, since the scene declares the Linux targets (core fork JetBrains#146).

Pinned core commit

CORE_EXTENDED_REF points at the core fork's feat/linux-window-chrome head (core fork JetBrains#149, which has JetBrains#144 and JetBrains#146 merged in). It moves to the extended merge commit once those merge; this PR merges after that.

Not covered here

  • The Kotlin/Native surface for the scene (X11GlWindowSurface) is in the sample until native/linux can depend on the scene module; it uses X11Window.makeCurrent() and resizePainter from the core fork.
  • The macOS Kotlin/Native cell is the macOS agent's, in this same file.
  • Orca speech and the feel of a drag are hand checks on a desktop.

…ks, in the gate

"One executable (Kotlin/Native, linux-x64)" and "(Kotlin/Native, linux-arm64)"
run the GraalVM cells' gate on extended/native-desktop/hello-awtfree: the same
Compose content (Content.kt and TextSelfCheck.kt are linked from hello-awtfree)
hosted by the core fork's scene in its Kotlin/Native X11 window. It is an Amper
module of the core fork's window project, because a klib is read only by the
compiler that wrote it or a newer one. Both executables are built on x86-64,
arm64 cross compiled and linked against the arm64 desktop libraries, and each
is run on its own architecture.

check-linux-chrome.sh runs on every Linux cell, GraalVM and Kotlin/Native
(FR-19.4, FR-19.7, NFR-8): under openbox, no title bar of the window manager's,
a caption drag moves the window, each edge and corner resizes it from that
side, a double click maximises and restores, with no stale or stretched frame
by the window's own count; libatspi walks the AT-SPI tree for the field, its
label and the button, sets the field, presses the button and closes the window
with the caption's Close. The scripts are the core fork's wm-chrome.sh and
atspi-readback.c.

hello-awtfree's content moves to Content.kt, its field is labelled "Name", and
HELLO_RUN_SECONDS keeps it up for a check that drives it from outside. The
scene is patched to the JVM by any platform list, since it now declares the
Linux targets too. CORE_EXTENDED_REF points at the core fork's Linux chrome
branch until it merges.

Closes #64
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