From 4922574f29ffef9341177b394a350bd054e20a68 Mon Sep 17 00:00:00 2001 From: Naoto Yamaguchi Date: Sun, 23 Apr 2023 05:21:11 +0900 Subject: Overwrite agl-compositor-init setting to become adopt guest container When existing agl demo integrate to container guest, need to overwrite agl-compositor-init setting. - Remove real tty device dependency. - Adjust drm lease setting from default. This patch realize this overwrite method in case of container guest. Bug-AGL: SPEC-4766 Change-Id: If3acc66a2836d7ab78e408b14931126071e3d32c Signed-off-by: Naoto Yamaguchi --- .../agl-compositor.conf | 4 ++++ .../agl-compositor.env | 2 ++ recipes-graphics/wayland/agl-compositor-init.bbappend | 1 + .../agl-compositor-init_agl-container-guest-demo.inc | 15 +++++++++++++++ 4 files changed, 22 insertions(+) create mode 100644 recipes-graphics/wayland/agl-compositor-init-agl-container-guest/agl-compositor.conf create mode 100644 recipes-graphics/wayland/agl-compositor-init-agl-container-guest/agl-compositor.env create mode 100644 recipes-graphics/wayland/agl-compositor-init.bbappend create mode 100644 recipes-graphics/wayland/agl-compositor-init_agl-container-guest-demo.inc diff --git a/recipes-graphics/wayland/agl-compositor-init-agl-container-guest/agl-compositor.conf b/recipes-graphics/wayland/agl-compositor-init-agl-container-guest/agl-compositor.conf new file mode 100644 index 000000000..0ff470552 --- /dev/null +++ b/recipes-graphics/wayland/agl-compositor-init-agl-container-guest/agl-compositor.conf @@ -0,0 +1,4 @@ +[Unit] + +[Service] +Environment=XDG_SESSION_TYPE=wayland diff --git a/recipes-graphics/wayland/agl-compositor-init-agl-container-guest/agl-compositor.env b/recipes-graphics/wayland/agl-compositor-init-agl-container-guest/agl-compositor.env new file mode 100644 index 000000000..d817effa6 --- /dev/null +++ b/recipes-graphics/wayland/agl-compositor-init-agl-container-guest/agl-compositor.env @@ -0,0 +1,2 @@ +DLM_RUNTIME_PATH=/var/display/drm-lease-manager +DRM_LEASE_DEVICE=lease diff --git a/recipes-graphics/wayland/agl-compositor-init.bbappend b/recipes-graphics/wayland/agl-compositor-init.bbappend new file mode 100644 index 000000000..e78295624 --- /dev/null +++ b/recipes-graphics/wayland/agl-compositor-init.bbappend @@ -0,0 +1 @@ +require ${@bb.utils.contains('AGL_FEATURES', 'agl-container-guest-demo', 'agl-compositor-init_agl-container-guest-demo.inc', '', d)} diff --git a/recipes-graphics/wayland/agl-compositor-init_agl-container-guest-demo.inc b/recipes-graphics/wayland/agl-compositor-init_agl-container-guest-demo.inc new file mode 100644 index 000000000..9fa2daf94 --- /dev/null +++ b/recipes-graphics/wayland/agl-compositor-init_agl-container-guest-demo.inc @@ -0,0 +1,15 @@ +FILESEXTRAPATHS:prepend := "${THISDIR}/agl-compositor-init-agl-container-guest:" + +SRC_URI:append = " \ + file://agl-compositor.env \ + " + +DRM_LEASE_DEVICE = "lease" + +do_install:append() { + install -Dm644 ${WORKDIR}/agl-compositor.env ${D}${sysconfdir}/default/agl-compositor +} + +FILES:${PN} += "\ + ${sysconfdir}/default/agl-compositor \ + " -- cgit 1.2.3-korg