Skip to content

GDK_BACKEND is propagated to the shell in terminal #1871

Description

@gasinvein

Describe the bug

The GDK_BACKEND environment variable set by Guake entrypoint is propagated to terminals and, in turn, to all the child processes.
This forces all GUI apps launched from Guake to use XWayland on Wayland session.

On a Wayland session, setting GDK_BACKEND to x11 while XDG_SESSION_TYPE is set to wayland, can cause apps misbehaviour.
E.g. GTK-based flatpak apps with --socket=fallback-x11 permission (which allows x11 socket only on X11 session) will fail to launch with Gtk-WARNING **: 18:18:53.576: cannot open display:, unless GDK_BACKEND is unset in advance.

#1763 seems somehow related to this.

Expected behavior

Guake itself runs with x11 GDK backend, while GDK_BACKEND env var is unset in the shell.

Actual behavior

GDK_BACKEND env var is set to x11 in the shell.

To Reproduce

  1. Launch Guake on Wayland session
  2. Run echo $GDK_BACKEND in the terminal
  3. Observe x11 in output

$ guake --support

Guake Version: 3.7.0

Vte Version: 0.64.2

Vte Runtime Version: 0.64.2


GTK+ Version: 3.24.30

GDK Backend: GdkX11.X11Display


Desktop Session: gnome


Display: :0

RGBA visual: True

Composited: True

  • Monitor: 0 - XWAYLAND0
    • Geometry: 2560 x 1440 at 0, 0
    • Size: 550 x 310 mm²
    • Primary: True
    • Refresh rate: 59.91 Hz
    • Subpixel layout: unknown

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions