diff mbox series

weston-init: fix weston not starting when xwayland is enabled

Message ID 20240821-weston-init-xwayland-v1-1-77cd13a14883@cherry.de
State Accepted, archived
Commit fa2314125318634108452af4e40c9eeee260767c
Headers show
Series weston-init: fix weston not starting when xwayland is enabled | expand

Commit Message

Quentin Schulz Aug. 21, 2024, 9:15 a.m. UTC
From: Quentin Schulz <quentin.schulz@cherry.de>

When xwayland PACKAGECONFIG option is set, xwayland is enabled in
weston.ini. However, if the xwayland module isn't installed, weston will
refuse to start with the following error message:
Failed to load module: /usr/lib/libweston-13/xwayland.so: cannot open shared object file: No such file or directory

Therefore, whenever the xwayland PACKAGECONFIG is set, weston-init
should depend on weston-xwayland to bring this module in.

Fixes: fdbe559c66c9 ("weston.init: enabled xwayland")
Signed-off-by: Quentin Schulz <quentin.schulz@cherry.de>
---
This should also be backported to scarthgap (kirkstone is not impacted
as the commit which introduced the bug isn't part of kirkstone).
---
 meta/recipes-graphics/wayland/weston-init.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)


---
base-commit: 30ee6edc57ff7629a72606d1005f92d43a5d14f9
change-id: 20240821-weston-init-xwayland-4dba6e694321

Best regards,
diff mbox series

Patch

diff --git a/meta/recipes-graphics/wayland/weston-init.bb b/meta/recipes-graphics/wayland/weston-init.bb
index 83f0cea49c..3de697ec34 100644
--- a/meta/recipes-graphics/wayland/weston-init.bb
+++ b/meta/recipes-graphics/wayland/weston-init.bb
@@ -84,7 +84,7 @@  USERADD_PACKAGES = "${PN}"
 #
 require ${THISDIR}/required-distro-features.inc
 
-RDEPENDS:${PN} = "weston kbd"
+RDEPENDS:${PN} = "weston kbd ${@bb.utils.contains('PACKAGECONFIG', 'xwayland', 'weston-xwayland', '', d)}"
 
 INITSCRIPT_NAME = "weston"
 INITSCRIPT_PARAMS = "start 9 5 2 . stop 20 0 1 6 ."