Add weston-wrapper
A tiny helper binary that restarts the compositor when it crashes. Useful even when clients do not support restarting to restart the compositor without the session going down. Based on kwin_wrapper from KWin.
Merge request reports
Activity
- Resolved by David Redondo
- Resolved by David Redondo
- Resolved by David Redondo
Sorry for overlooking this, but I am happy to relince my changes and I am sure @davidedmundson as well
- Resolved by David Redondo
- Resolved by David Redondo
The important part is keeping the socket on the file system.. Keeping the file on the fs is doable using a systemd service but only feasibly hardcoded socket names. Once you try and find the next socket that's free and export the right environment variables you end up with something like the wrapper.
I'm happy to close this as a MR. It was primarily made so the GTK devs would be easily able to test some other changes I had made for making GTK apps to handle the case of a compositor restarting.
Hi!
I have recently implemented a generic wrapper (named wl-restart) similar to this that currently has support for
Kwin
(same args askwin_wayland_wrapper
),hyprland
(merged, KDE CLI args),sway
(unmerged, KDE CLI args or env vars), andlabwc
(unmerged, KDE CLI args or env vars).The Labwc devs have voiced interest in a generic env var based mechanism (
WAYLAND_SOCKET_NAME
andWAYLAND_SOCKET_FD
) instead of a CLI arg, since some compositors use different CLI arg conventions (e.g. river).Would Weston be interested in merging support for recognizing either the KDE CLI args (
--socket
is already there, plus--wayland-fd
for FD handover) or the env var mechanism? (WAYLAND_SOCKET_NAME
andWAYLAND_SOCKET_FD
)Recognizing the env var could also be potentially gated behind a
--socket-handover
CLI option.I'm also open to suggestions regarding the socket passing mechanism. I do think having a generic restarting wrapper could be useful for smaller compositors to avoid duplicating work.
added Weston frontend label