weston-agl-driver-conf: add recipe 46/29346/2
authorScott Murray <scott.murray@konsulko.com>
Mon, 30 Oct 2023 21:49:22 +0000 (17:49 -0400)
committerJan-Simon Moeller <jsmoeller@linuxfoundation.org>
Sat, 4 Nov 2023 14:37:10 +0000 (14:37 +0000)
Add recipe which installs a systemd drop-in configuration override
to run Weston as the agl-driver user.  This will be used in the new
image for running agl-demo-control-panel, but may also be useful for
other downstream users.

Bug-AGL: SPEC-4952

Change-Id: I99c6801169e1c8e51a92c82fed354cdbbedda614
Signed-off-by: Scott Murray <scott.murray@konsulko.com>
Reviewed-on: https://gerrit.automotivelinux.org/gerrit/c/AGL/meta-agl-demo/+/29346
Tested-by: Jenkins Job builder account
Reviewed-by: Hiroyuki Ishii <ishii.hiroyuki002@jp.panasonic.com>
ci-image-boot-test: Jenkins Job builder account
Reviewed-by: Jan-Simon Moeller <jsmoeller@linuxfoundation.org>
ci-image-build: Jenkins Job builder account

recipes-graphics/wayland/weston-agl-driver-conf.bb [new file with mode: 0644]
recipes-graphics/wayland/weston-agl-driver-conf/weston-agl-driver.conf [new file with mode: 0644]

diff --git a/recipes-graphics/wayland/weston-agl-driver-conf.bb b/recipes-graphics/wayland/weston-agl-driver-conf.bb
new file mode 100644 (file)
index 0000000..763103d
--- /dev/null
@@ -0,0 +1,22 @@
+SUMMARY     = "Weston systemd configuration to run as agl-driver user"
+LICENSE     = "MIT"
+LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302"
+
+inherit systemd allarch features_check
+
+REQUIRED_DISTRO_FEATURES = "wayland systemd"
+
+SRC_URI = "file://weston-agl-driver.conf"
+
+do_configure[noexec] = "1"
+do_compile[noexec] = "1"
+
+do_install() {
+    # Install override drop-in
+    install -d ${D}${systemd_system_unitdir}/weston.service.d
+    install -m 0644 ${WORKDIR}/weston-agl-driver.conf ${D}${systemd_system_unitdir}/weston.service.d/
+}
+
+FILES:${PN} += "${systemd_system_unitdir}"
+
+RDEPENDS:${PN} += "weston agl-users"
diff --git a/recipes-graphics/wayland/weston-agl-driver-conf/weston-agl-driver.conf b/recipes-graphics/wayland/weston-agl-driver-conf/weston-agl-driver.conf
new file mode 100644 (file)
index 0000000..75ab576
--- /dev/null
@@ -0,0 +1,5 @@
+[Service]
+User=
+User=agl-driver
+Group=
+Group=agl-driver