From: Adrian Date: Mon, 15 Mar 2021 15:01:10 +0000 (+0100) Subject: weston-init: Set $HOME variable for SysVinit manager X-Git-Tag: lucaceresoli/bug-15201-perf-libtraceevent-missing~8378 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f5ddf5533b19a41be9e9cd403c2e7ded6da6f272;p=thirdparty%2Fopenembedded%2Fopenembedded-core-contrib.git weston-init: Set $HOME variable for SysVinit manager SysVinit sets by default the $HOME directory to "/" for the init scripts. It's picked then by the weston-launcher and make weston-terminal to have wrongly set $HOME environment variable for the root user. Signed-off-by: Adrian Fiergolski Signed-off-by: Richard Purdie --- diff --git a/meta/recipes-graphics/wayland/weston-init.bb b/meta/recipes-graphics/wayland/weston-init.bb index 65d7b81dc54..6b78e6722ff 100644 --- a/meta/recipes-graphics/wayland/weston-init.bb +++ b/meta/recipes-graphics/wayland/weston-init.bb @@ -30,6 +30,7 @@ DEFAULTBACKEND_x86-x32 = "fbdev" do_install() { if [ "${VIRTUAL-RUNTIME_init_manager}" != "systemd" ]; then install -Dm755 ${WORKDIR}/init ${D}/${sysconfdir}/init.d/weston + sed -i 's#ROOTHOME#${ROOT_HOME}#' ${D}/${sysconfdir}/init.d/weston fi install -D -p -m0644 ${WORKDIR}/weston.ini ${D}${sysconfdir}/xdg/weston/weston.ini install -Dm644 ${WORKDIR}/weston.env ${D}${sysconfdir}/default/weston diff --git a/meta/recipes-graphics/wayland/weston-init/init b/meta/recipes-graphics/wayland/weston-init/init index d3e87c6cef6..a849f29bcbd 100644 --- a/meta/recipes-graphics/wayland/weston-init/init +++ b/meta/recipes-graphics/wayland/weston-init/init @@ -30,6 +30,7 @@ done case "$1" in start) . /etc/profile + export HOME=ROOTHOME weston-start -- $OPTARGS ;;