fix(ci): un-bundle libwayland from the AppImage to stop the EGL abort (#67) - #170
Merged
SuperKali merged 1 commit intoAug 7, 2026
Merged
Conversation
linuxdeploy pulls libwebkit2gtk's transitive libwayland-{client,cursor,egl,
server} into the AppImage. Those copies come from the Ubuntu 24.04 build
environment, which is older than the Mesa users are running, so libEGL_mesa
hits a protocol/ABI mismatch while initialising the Wayland platform and
aborts with "Could not create default EGL display: EGL_BAD_PARAMETER" — the
webview never paints and the window stays blank white.
The abort happens inside EGL display init, before WebKit reads any of its
environment, which is why WEBKIT_DISABLE_DMABUF_RENDERER, GDK_BACKEND=x11 and
LIBGL_ALWAYS_SOFTWARE all have no effect.
libwayland — like libGL/libEGL/libgbm/libdrm, which linuxdeploy already
excludes — has to come from the running system so it matches the loaded EGL
stack. Strip the four bundled copies after the build and repack. Repacking
invalidates the updater signature Tauri produced, so re-sign the AppImage;
without that the in-app updater would reject every Linux update.
Only the AppImage bundles libraries; the .deb links the system libwayland and
is unaffected.
Fixes armbian#67
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes #67 — the Linux AppImage shows a blank white window and logs:
Root cause
linuxdeploypulls libwebkit2gtk's transitivelibwayland-{client,cursor,egl,server}into the AppImage. Those copies come from the Ubuntu 24.04 build environment and are older than the Mesa the user is running, so whenlibEGL_mesainitialises the Wayland platform it hits a protocol/ABI mismatch and aborts. The webview never paints.The abort happens inside EGL display init, before WebKit reads any of its environment — which is exactly why
WEBKIT_DISABLE_DMABUF_RENDERER,WEBKIT_DISABLE_COMPOSITING_MODE,GDK_BACKEND=x11andLIBGL_ALWAYS_SOFTWAREhave no effect for the reporters in #67.Fix
libwayland— likelibGL/libEGL/libgbm/libdrm, which linuxdeploy already excludes — has to come from the running system so it matches the loaded EGL stack. Its soname has been frozen for over a decade, so deferring to the host is safe.scripts/build/appimage-unbundle-wayland.shruns after the Tauri build: extract → delete the fourlibwayland-*→ repack withappimagetool→ re-sign. It's wired into all three workflows that produce an AppImage (maintenance-release,maintenance-build,maintenance-pr-check).This is the same thing several people in #67 confirmed by hand (
--appimage-extract,rm squashfs-root/usr/lib/*wayland*so*, runAppRun) — just done once at build time so users don't have to.Only the AppImage bundles libraries; the
.deblinks the systemlibwaylandand is unaffected.Note on the updater signature
Repacking changes the AppImage bytes, so the
.sigTauri emitted during the build no longer matches. The script re-signs withcargo tauri signer sign; without that the in-app updater would reject every Linux update. Worth a careful look during review, since it's the one part that can't be exercised without the release signing secret.(
tauri signer signreadsTAURI_PRIVATE_KEY/TAURI_PRIVATE_KEY_PASSWORD, not theTAURI_SIGNING_*names the bundler uses — the script maps them, and fails loudly rather than shipping a stale signature if the key is missing.)Verification
A/B tested against the published
Armbian.Imager_2.0.2_amd64.AppImageon Wayland (XDG_SESSION_TYPE=wayland), running the script exactly as CI invokes it:Stock release — reproduces the bug:
After the script — starts and renders:
No EGL error, and the
frontend::*lines mean the webview actually executed the app.The script found and removed all four libs, and repacked cleanly:
CI-side, the Linux job of this PR's own build exercises the script end to end.
Notes
appimagetoolbundles its ownmksquashfs.x86_64/aarch64), so the ARM64 AppImage gets the same treatment.--appimage-extract-and-runso no FUSE is needed on the runners.find … -deleteis path-tolerant and a no-op if a future linuxdeploy stops bundling these, so the step won't break the build once it's no longer needed.libwaylandgets loaded. The two aren't mutually exclusive.