]> code.ossystems Code Review - meta-freescale.git/commitdiff
weston: Improve weston.ini selection logic
authorTom Hochstein <tom.hochstein@nxp.com>
Mon, 4 Nov 2019 16:21:47 +0000 (10:21 -0600)
committerOtavio Salvador <otavio@ossystems.com.br>
Mon, 4 Nov 2019 18:40:00 +0000 (15:40 -0300)
Add a variable WESTON_INI_INSTALL_FILE to make it easy to customize
the selection of the weston.ini file.

The main recipe now performs only a generic install of the selected file.

For AGL and IVI, we use the BBFILES_DYNAMIC mechanism to specify no
file and an IVI-specific file respectively.

Signed-off-by: Tom Hochstein <tom.hochstein@nxp.com>
conf/layer.conf
dynamic-layers/aglprofilegraphical/recipes-graphics/wayland/weston_5.0.0.imx.bbappend [new file with mode: 0644]
dynamic-layers/ivi/recipes-graphics/wayland/weston_5.0.0.imx.bbappend [new file with mode: 0644]
recipes-graphics/wayland/weston_5.0.0.imx.bb

index 1b71beadbfb29280556fe49df4ed8f30435b4e27..93e5f97ffe05cca1b7f2d0af5dbea592d39e2052 100644 (file)
@@ -27,12 +27,18 @@ ${QORIQ_MIRROR} http://download.ossystems.com.br/bsp/freescale/source/ \n \
 "
 
 BBFILES_DYNAMIC += " \
+    aglprofilegraphical:${LAYERDIR}/dynamic-layers/aglprofilegraphical/*/*/*.bb \
+    aglprofilegraphical:${LAYERDIR}/dynamic-layers/aglprofilegraphical/*/*/*.bbappend \
+    \
     browser-layer:${LAYERDIR}/dynamic-layers/browser-layer/*/*/*.bb \
     browser-layer:${LAYERDIR}/dynamic-layers/browser-layer/*/*/*.bbappend \
     \
     filesystem-layer:${LAYERDIR}/dynamic-layers/filesystem-layer/*/*/*.bb \
     filesystem-layer:${LAYERDIR}/dynamic-layers/filesystem-layer/*/*/*.bbappend \
     \
+    ivi:${LAYERDIR}/dynamic-layers/ivi/*/*/*.bb \
+    ivi:${LAYERDIR}/dynamic-layers/ivi/*/*/*.bbappend \
+    \
     networking-layer:${LAYERDIR}/dynamic-layers/networking-layer/*/*/*.bb \
     networking-layer:${LAYERDIR}/dynamic-layers/networking-layer/*/*/*.bbappend \
     \
diff --git a/dynamic-layers/aglprofilegraphical/recipes-graphics/wayland/weston_5.0.0.imx.bbappend b/dynamic-layers/aglprofilegraphical/recipes-graphics/wayland/weston_5.0.0.imx.bbappend
new file mode 100644 (file)
index 0000000..1a896a2
--- /dev/null
@@ -0,0 +1,2 @@
+# don't install default weston.ini
+WESTON_INI_INSTALL_FILE = ""
diff --git a/dynamic-layers/ivi/recipes-graphics/wayland/weston_5.0.0.imx.bbappend b/dynamic-layers/ivi/recipes-graphics/wayland/weston_5.0.0.imx.bbappend
new file mode 100644 (file)
index 0000000..d36fbd4
--- /dev/null
@@ -0,0 +1,2 @@
+# install default weston.ini for IVI
+WESTON_INI_INSTALL_FILE = "${B}/ivi-shell/weston.ini"
index 9f32d94a237013d9cd2a87f013920ad4a10d1b47..e9f354f07deb7458450a56c45020e80b90ed5aa7 100644 (file)
@@ -102,6 +102,9 @@ PACKAGECONFIG[imxg2d] = "--enable-imxg2d,--disable-imxg2d,virtual/libg2d"
 # Weston with OpenGL support
 PACKAGECONFIG[opengl] = "--enable-opengl,--disable-opengl"
 
+# Set to install a default weston.ini file
+WESTON_INI_INSTALL_FILE = "${B}/weston.ini"
+
 do_install_append() {
        # Weston doesn't need the .la files to load modules, so wipe them
        rm -f ${D}/${libdir}/libweston-${WESTON_MAJOR_VERSION}/*.la
@@ -120,13 +123,8 @@ do_install_append() {
        fi
 
        # install default weston.ini
-       if [ -n "${@bb.utils.filter('BBFILE_COLLECTIONS', 'aglprofilegraphical', d)}" ]; then
-               if [ "${@bb.utils.filter('BBFILE_COLLECTIONS', 'ivi', d)}" ]; then
-                       WESTON_INI_SRCDIR=${B}/ivi-shell
-               else
-                       WESTON_INI_SRCDIR=${B}
-               fi
-               install -D -m 0644 ${WESTON_INI_SRCDIR}/weston.ini ${D}${sysconfdir}/xdg/weston/weston.ini
+       if [ "${WESTON_INI_INSTALL_FILE}" != "" ]; then
+               install -D -m 0644 ${WESTON_INI_INSTALL_FILE} ${D}${sysconfdir}/xdg/weston/weston.ini
        fi
 }