From e805a5c751a7f417c5aa104fcbfc2d980cdcde84 Mon Sep 17 00:00:00 2001 From: Khang Nguyen Date: Thu, 9 Apr 2020 10:47:00 +0900 Subject: rcar-gen3: weston-init: Fix XDG_RUNTIME_DIR issue The gernerated weston.service is loaded simultaneously with weston@.service [1]. Since YP3.1_M3, it causes an issue as follows: | fatal: environment variable XDG_RUNTIME_DIR | is set to "/run/user/0", which is not a directory. This fixes the issue by changing weston init script in "/etc/init.d" to weston@, the generated unit file becomes weston@.service located in "run/systemd/generator.late" which has low precedence compared to the same name unit file in "/lib/systemd/system". [1]: /lib/systemd/system/weston@.service /run/systemd/generator.late/weston.service Signed-off-by: Khang Nguyen Signed-off-by: Duy Dang Signed-off-by: Takamitsu Honda Change-Id: Icc80dc62e16f0a659d5ad7f1ab8eb590ac7d8dde --- meta-rcar-gen3/recipes-graphics/wayland/weston-init.bbappend | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'meta-rcar-gen3') diff --git a/meta-rcar-gen3/recipes-graphics/wayland/weston-init.bbappend b/meta-rcar-gen3/recipes-graphics/wayland/weston-init.bbappend index 017ca3e..1722587 100644 --- a/meta-rcar-gen3/recipes-graphics/wayland/weston-init.bbappend +++ b/meta-rcar-gen3/recipes-graphics/wayland/weston-init.bbappend @@ -35,9 +35,14 @@ do_install_append_rcar-gen3() { # Set XDG_RUNTIME_DIR to /run/user/$UID (e.g. run/user/0) install -d ${D}/${sysconfdir}/profile.d install -m 0755 ${WORKDIR}/weston.sh ${D}/${sysconfdir}/profile.d/weston.sh + + # Fix weston.service and weston@.service run simultaneously. + mv ${D}/${sysconfdir}/init.d/weston ${D}/${sysconfdir}/init.d/weston@ } FILES_${PN}_append_rcar-gen3 = " \ ${sysconfdir}/profile.d/weston.sh \ " +INITSCRIPT_NAME = "weston@" + -- cgit 1.2.3-korg