Mir

Wayland clients do not work on miral-desktop

Bug #1716353 reported by Alan Griffiths
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mir
Fix Released
Critical
Alan Griffiths

Bug Description

Install mir-examples from the staging PPA (or build Mir from trunk)

$ sudo add-apt-repository ppa:mir-team/staging
$ sudo apt update
$ sudo apt install mir-examples

Then run miral-desktop:

$ miral-desktop

In the terminal run:

$ QT_QPA_PLATFORM=wayland kate

Expect: Kate starts, using wayland
Actual: Kate crashes with "Failed to create display (No such file or directory)"

Tags: wayland

Related branches

Revision history for this message
Alan Griffiths (alan-griffiths) wrote :

The corresponding scenario works with mir-app, so I suspect that running the shell as root and connecting as the user is a usecase that doesn't (yet) work.

Revision history for this message
Alan Griffiths (alan-griffiths) wrote :

Yes, the client is looking for $XDG_RUNTIME_DIR/wayland-0 - which (obviously) the server didn't create. There ought to be a way to configure this right.

Revision history for this message
Alan Griffiths (alan-griffiths) wrote :

OK, so what is happening is that wl_display_add_socket_auto(display) relies on $XDG_RUNTIME_DIR being set. That's a sensible default, but, as root, this isn't the case so no socket is created.

The client is looking in the right place, we just need a way for the script to specify the wayland socket to the server, and that needs to call wl_display_add_socket(<socket>, display) instead. (Much as we do for the legacy Mir socket.)

Changed in mir:
assignee: nobody → Alan Griffiths (alan-griffiths)
Revision history for this message
Alan Griffiths (alan-griffiths) wrote :

Nope, wl_display_add_socket() also insists on having XDG_RUNTIME_DIR, we'll have to go with the flow.

Changed in mir:
status: Triaged → Fix Committed
Changed in mir:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.