[Bug 275445] x11/xwayland-run: wlheadless-run and xwfb-run fail to start without explicit -c cage

From: <bugzilla-noreply_at_freebsd.org>
Date: Thu, 30 Nov 2023 06:14:41 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=275445

            Bug ID: 275445
           Summary: x11/xwayland-run: wlheadless-run and xwfb-run fail to
                    start without explicit -c cage
           Product: Ports & Packages
           Version: Latest
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: Individual Port(s)
          Assignee: x11@FreeBSD.org
          Reporter: jbeich@FreeBSD.org
             Flags: maintainer-feedback?(x11@FreeBSD.org)
          Assignee: x11@FreeBSD.org

Running without extra flags fails because the installed config file isn't
actually used.

$ pkg install xwayland-run glx-utils
$ wlheadless-run -- glxgears
Traceback (most recent call last):
  File "/usr/local/bin/wlheadless-run", line 78, in <module>
    if wlheadless.run_compositor(compositor_args) < 0:
  File "/usr/local/lib/python3.9/site-packages/wlheadless/weston.py", line 72,
in run_compositor
    return self.wlheadless_common.run_compositor(compositor)
  File
"/usr/local/lib/python3.9/site-packages/wlheadless/wlheadless_common.py", line
108, in run_compositor
    proc = subprocess.Popen(compositor)
  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: 'weston'

$ truss wlheadless-run -- glxgears 2>&1 | fgrep wlheadless.conf
openat(AT_FDCWD,"wlheadless/wlheadless.conf",O_RDONLY|O_CLOEXEC,00) ERR#2 'No
such file or directory'
openat(AT_FDCWD,"wlheadless/wlheadless.conf",O_RDONLY|O_CLOEXEC,00) ERR#2 'No
such file or directory'

$ cat /usr/local/share/wlheadless/wlheadless.conf
[DEFAULT]
    Compositor = cage

-- 
You are receiving this mail because:
You are the assignee for the bug.