Skip to content

Commit 7164de3

Browse files
fix(bundler): respect configured GDK backend (fix: #15781) (#15786)
1 parent 2e763a7 commit 7164de3

2 files changed

Lines changed: 6 additions & 2 deletions

File tree

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"tauri-bundler": "patch:bug"
3+
---
4+
5+
Respect an explicitly configured `GDK_BACKEND` in AppImage GTK hooks while retaining `x11` as the default.

‎crates/tauri-bundler/src/bundle/linux/appimage/linuxdeploy-plugin-gtk.sh‎

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,7 @@ APPIMAGE_GTK_THEME="${APPIMAGE_GTK_THEME:-"Adwaita:$GTK_THEME_VARIANT"}" # Allow
184184
export APPDIR="${APPDIR:-"$(dirname "$(realpath "$0")")"}" # Workaround to run extracted AppImage
185185
export GTK_DATA_PREFIX="$APPDIR"
186186
export GTK_THEME="$APPIMAGE_GTK_THEME" # Custom themes are broken
187-
export GDK_BACKEND=x11 # Crash with Wayland backend on Wayland - We tested it without it and ended up with this: https://github.com/tauri-apps/tauri/issues/8541
187+
export GDK_BACKEND="${GDK_BACKEND:-x11}" # Crash with Wayland backend on Wayland - We tested it without it and ended up with this: https://github.com/tauri-apps/tauri/issues/8541
188188
export XDG_DATA_DIRS="$APPDIR/usr/share:/usr/share:$XDG_DATA_DIRS" # g_get_system_data_dirs() from GLib
189189
EOF
190190

@@ -324,4 +324,3 @@ EOF
324324

325325
#binary patch absolute paths in libwebkit files
326326
find "$APPDIR"/usr/lib* -name 'libwebkit*' -exec sed -i -e "s|/usr|././|g" '{}' \;
327-

0 commit comments

Comments
 (0)