Skip to content

Fix the v0.7.4 Linux release build: GTK hook with X11 commented out - #53

Merged
stackrats merged 1 commit into
mainfrom
fix/appimage-commented-gdk-backend
Sep 28, 2026
Merged

stackrats merged 1 commit into
mainfrom
fix/appimage-commented-gdk-backend

Conversation

@stackrats

Copy link
Copy Markdown
Owner

What

  • The Linux release jobs for v0.7.4 failed in "Fix the AppImage for Wayland hosts": the GTK hook still forces GDK_BACKEND=x11 after the repack.
  • Cause: Tauri's CLI now bundles its own linuxdeploy-plugin-gtk (tauri-apps/tauri#16062), whose hook has # export GDK_BACKEND=x11 commented out. fix-appimage-wayland.sh matched that text inside the comment, its column-one rewrite changed nothing, and its verification matched the comment again.
  • Fix: detection, rewrite and verification all match only an active export GDK_BACKEND=x11, at any indentation. A hook that leaves GDK_BACKEND unset already gets GTK's Wayland-then-X11 choice and passes through unchanged.
  • No app code changes. Once merged, the v0.7.4 release is re-cut by dispatching release.yml against the existing tag.

Verified

  • scripts/test-fix-appimage-wayland.sh: 23 checks pass. The two new cases (Tauri's commented hook left byte-identical with GDK_BACKEND unset, and an indented export rewritten) both fail against the old script.
  • Full repack path on a real AppImage carrying Tauri's hook: the old script fails with the CI error, and the new one verifies it (3 removed, hook rewritten: 0, WebKit intact).

The v0.7.4 Linux release builds failed in "Fix the AppImage for Wayland
hosts": the script reported rewriting the GTK hook, then its own check
found the forced-X11 line still there and refused the AppImage.

Tauri's CLI now bundles its own copy of linuxdeploy-plugin-gtk
(tauri-apps/tauri#16062), and that hook carries the line commented out:
`# export GDK_BACKEND=x11`. The script matched the text anywhere on a line,
so the comment counted as forcing X11; the rewrite only replaced a line
starting with the export, so it changed nothing, and the verification
matched the same comment again.

Only an active export forces X11, so detection, rewrite and verification
now all match that — at any indentation, never inside a comment. A hook
that leaves GDK_BACKEND unset already gets GTK's Wayland-then-X11 choice
and passes through byte for byte.

The regression test gains both cases: Tauri's commented hook is left
unchanged with GDK_BACKEND unset, and an indented export is still
rewritten. Against the old script both fail. Run over a real AppImage
carrying Tauri's hook, the old script fails exactly as CI did, and the new
one repacks and verifies it.
@stackrats
stackrats merged commit 85c0b93 into main Sep 28, 2026
16 of 18 checks passed
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