Bug 275430 - x11/xwayland-run: missing dependency
Summary: x11/xwayland-run: missing dependency
Status: Open
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-x11 (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-11-29 17:23 UTC by Jan Beich
Modified: 2023-11-30 05:53 UTC (History)
1 user (show)

See Also:
bugzilla: maintainer-feedback? (x11)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jan Beich freebsd_committer freebsd_triage 2023-11-29 17:23:50 UTC
Running in a clean jail or fresh non-Xorg install (e.g., Sway) fails.

$ pkg install xwayland-run glx-utils
$ xwayland-run -- glxgears
[...]
Traceback (most recent call last):
  File "/usr/local/bin/xwayland-run", line 69, in <module>
    if xwayland.create_xauth_entry() != 0:
  File "/usr/local/lib/python3.9/site-packages/wlheadless/xwayland.py", line 108, in create_xauth_entry
    with subprocess.Popen(xauth_command_line, stdin = subprocess.PIPE) as proc:
  File "/usr/local/lib/python3.9/subprocess.py", line 951, in __init__
    self._execute_child(args, executable, preexec_fn, close_fds,
  File "/usr/local/lib/python3.9/subprocess.py", line 1837, in _execute_child
    raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'xauth'
Comment 1 Emmanuel Vadot freebsd_committer freebsd_triage 2023-11-29 17:43:46 UTC
Mhm right it uses xauth, I'll have a look at what other componant it might use.
Comment 2 Jan Beich freebsd_committer freebsd_triage 2023-11-30 05:53:30 UTC
To be pedantic, xwayland-run also depends on Xwayland binary which is only a problem if wlroots is built with X11=off as rootful Xwayland doesn't need interop with Wayland compositor. While adding Xwayland to RUN_DEPENDS should be easy there's a xwayland vs. xwayland-devel package conflict (see also bug 261202). Moreover, non-devel package lacks -Dxcsecurity=true (noted in review D35662) which may affect how XAUTHORITY works in a subtle way (ssh -X vs. ssh -Y within X11 WM).

$ make clean all deinstall install INSTALLS_DEPENDS= WITHOUT=X11 -C $(pkg query %do cage | fgrep wlroots)
$ pkg autoremove
$ xwayland-run -- glxgears
Traceback (most recent call last):
  File "/usr/local/bin/xwayland-run", line 65, in <module>
    if xwayland.spawn_xwayland(xserver_args) < 0:
  File "/usr/local/lib/python3.9/site-packages/wlheadless/xwayland.py", line 66, in spawn_xwayland
    proc = subprocess.Popen(command, stdout = subprocess.PIPE)
  File "/usr/local/lib/python3.9/subprocess.py", line 951, in __init__
    self._execute_child(args, executable, preexec_fn, close_fds,
  File "/usr/local/lib/python3.9/subprocess.py", line 1837, in _execute_child
    raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'Xwayland'