aboutsummaryrefslogtreecommitdiffstats
path: root/meta-agl-flutter/recipes-graphics/toyota
diff options
context:
space:
mode:
authorMarius Vlad <marius.vlad@collabora.com>2022-04-20 13:00:55 +0300
committerJan-Simon Moeller <jsmoeller@linuxfoundation.org>2022-05-04 16:32:55 +0000
commit9461fa4202505880f25c7f0673c6bdad4df8ee9c (patch)
treebf8c86990e2a58eb8b3c066b6276f01e334abe34 /meta-agl-flutter/recipes-graphics/toyota
parentfffdabd3e39e70a63c39243316e0b0e459df2b7f (diff)
ivi-homescreen_aglflutter: Use the agl-session for starting up
Bug-AGL: SPEC-4330 Signed-off-by: Marius Vlad <marius.vlad@collabora.com> Change-Id: Id09825fe02c0cf39d36c19291bc89113770c2d34
Diffstat (limited to 'meta-agl-flutter/recipes-graphics/toyota')
-rw-r--r--meta-agl-flutter/recipes-graphics/toyota/ivi-homescreen_aglflutter.inc19
1 files changed, 15 insertions, 4 deletions
diff --git a/meta-agl-flutter/recipes-graphics/toyota/ivi-homescreen_aglflutter.inc b/meta-agl-flutter/recipes-graphics/toyota/ivi-homescreen_aglflutter.inc
index 767637b7..dd3b8ec0 100644
--- a/meta-agl-flutter/recipes-graphics/toyota/ivi-homescreen_aglflutter.inc
+++ b/meta-agl-flutter/recipes-graphics/toyota/ivi-homescreen_aglflutter.inc
@@ -9,7 +9,18 @@ PACKAGECONFIG:remove = "gstreamer"
# AGL specifics
IVI_HOMESCREEN_APP_OVERRIDE = "--a=/usr/share/gallery"
-SERVICE_UNIT = "Requires=weston.service\nAfter=weston.service"
-SERVICE_USER_GROUP = "User=weston\nGroup=weston"
-SERVICE_RESTART = ""
-SERVICE_ENVIRONMENT = "Environment=XDG_RUNTIME_DIR=/run/user/200"
+SERVICE_UNIT = "Requires=agl-compositor.service\nAfter=agl-compositor.service"
+SERVICE_INSTALL = "WantedBy=agl-session.target"
+# we have a regular/agl-driver user, so avoid setting one
+SERVICE_ENVIRONMENT = ""
+SERVICE_USER_GROUP = ""
+SERVICE_RESTART = "Restart=on-failure"
+
+# we need to install as user session, not root.
+do_install:append() {
+ install -d ${D}${systemd_user_unitdir}/agl-session.target.wants
+ install -m0644 ${WORKDIR}/homescreen.service ${D}${systemd_user_unitdir}/homescreen.service
+ ln -s ../homescreen.service ${D}${systemd_user_unitdir}/agl-session.target.wants/homescreen.service
+}
+
+FILES:${PN} += " ${systemd_user_unitdir}"