summaryrefslogtreecommitdiffstats
path: root/recipes-graphics
diff options
context:
space:
mode:
authorScott Murray <scott.murray@konsulko.com>2022-11-21 02:54:41 -0500
committerScott Murray <scott.murray@konsulko.com>2022-11-21 16:38:19 -0500
commit301c4e13cd68cbe378bf43f5c3f7244b43356f8b (patch)
tree514b8fc0561fb2e9cb3cc71f12415c40b09d0736 /recipes-graphics
parentb29f7678fe1a27bbb4b6185f16910954ecc6ca03 (diff)
weston-ini-conf: Add bbappend to generate Flutter demo config
The Flutter homescreen in the Flutter demo image currently requires specifying the application activation area in the output sections in the weston.ini configuration for the compositor. Add a bbappend that creates a weston-ini-conf-flutter package with the required .ini. Bug-AGL: SPEC-4615 Change-Id: I59ef74abb8957ea2ad8b13b6de014662a2a867c8 Signed-off-by: Scott Murray <scott.murray@konsulko.com>
Diffstat (limited to 'recipes-graphics')
-rw-r--r--recipes-graphics/wayland/weston-ini-conf.bbappend1
-rw-r--r--recipes-graphics/wayland/weston-ini-conf_aglflutter.inc26
2 files changed, 27 insertions, 0 deletions
diff --git a/recipes-graphics/wayland/weston-ini-conf.bbappend b/recipes-graphics/wayland/weston-ini-conf.bbappend
new file mode 100644
index 00000000..b509b38e
--- /dev/null
+++ b/recipes-graphics/wayland/weston-ini-conf.bbappend
@@ -0,0 +1 @@
+require ${@bb.utils.contains('AGL_FEATURES', 'agl-flutter', 'weston-ini-conf_aglflutter.inc', '', d)}
diff --git a/recipes-graphics/wayland/weston-ini-conf_aglflutter.inc b/recipes-graphics/wayland/weston-ini-conf_aglflutter.inc
new file mode 100644
index 00000000..84e88e19
--- /dev/null
+++ b/recipes-graphics/wayland/weston-ini-conf_aglflutter.inc
@@ -0,0 +1,26 @@
+do_compile:append() {
+ # Put all of our cfg files together for a default portrait
+ # orientation configuration
+ rm -f ${WORKDIR}/weston.ini.flutter
+ for F in ${WESTON_FRAGMENTS}; do
+ cat ${WORKDIR}/${F}.cfg >> ${WORKDIR}/weston.ini.flutter
+ if grep -q '\[output\]' ${WORKDIR}/${F}.cfg; then
+ echo "activation-area=1080x1600+0,160" >> ${WORKDIR}/weston.ini.flutter
+ fi
+ echo >> ${WORKDIR}/weston.ini.flutter
+ done
+ sed -i -e '$ d' ${WORKDIR}/weston.ini.flutter
+}
+
+do_install:append() {
+ install -m 0644 ${WORKDIR}/weston.ini.flutter ${D}${weston_ini_dir}/
+}
+
+PACKAGE_BEFORE_PN += "${PN}-flutter"
+
+FILES:${PN}-flutter = "${weston_ini_dir}/weston.ini.flutter"
+
+RPROVIDES:${PN}-flutter = "weston-ini"
+RCONFLICTS:${PN}-flutter = "${PN}"
+ALTERNATIVE:${PN}-flutter = "weston.ini"
+ALTERNATIVE_TARGET_${PN}-flutter = "${weston_ini_dir}/weston.ini.flutter"