summaryrefslogtreecommitdiffstats
path: root/meta/classes/pixbufcache.bbclass
diff options
context:
space:
mode:
authorRoss Burton <ross.burton@intel.com>2016-10-13 20:36:35 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-10-15 09:49:10 +0100
commit03cdb3366ded46cd760656e4cda0be37c1f82109 (patch)
tree688dcc6180aac475a8639e328946974cb6818c7f /meta/classes/pixbufcache.bbclass
parentfcfd3e76eb52353345aa9a1f7ec0f9795e607493 (diff)
downloadopenembedded-core-contrib-03cdb3366ded46cd760656e4cda0be37c1f82109.tar.gz
pixbufcache: handle gdk-pixbuf not being present
It's possible - albeit unlikely - that gdk-pixbuf isn't present in the sysroot when a recipe inheriting this class is and the sysroot is finalised. One example would be if the sstate archive has librsvg but not gdk-pixbuf: librsvg will be extracted from the sstate but gdk-pixbuf will be built to "fill in the gap". In this situation the setscene completion hook installed by pixbufcache.bbclass will attempt to execute gdk-pixbuf-query-loaders, but that binary hasn't been installed by gdk-pixbuf yet. Also add gdk-pixbuf-native to DEPENDS in native builds to ensure that the binaries we expect will be present, as it's possible to build loaders without linking to GdkPixbuf. [ YOCTO #10420 ] Signed-off-by: Ross Burton <ross.burton@intel.com>
Diffstat (limited to 'meta/classes/pixbufcache.bbclass')
-rw-r--r--meta/classes/pixbufcache.bbclass6
1 files changed, 4 insertions, 2 deletions
diff --git a/meta/classes/pixbufcache.bbclass b/meta/classes/pixbufcache.bbclass
index dbe11e12da9..3f48a0f3446 100644
--- a/meta/classes/pixbufcache.bbclass
+++ b/meta/classes/pixbufcache.bbclass
@@ -54,6 +54,7 @@ gdkpixbuf_complete() {
# An error exit during populate_sysroot_setscene allows bitbake to
# try to recover by re-building the package.
#
+DEPENDS_append_class-native = " gdk-pixbuf-native"
SSTATEPOSTINSTFUNCS_append_class-native = " pixbufcache_sstate_postinst"
# See base.bbclass for the other half of this
@@ -61,7 +62,8 @@ pixbufcache_sstate_postinst() {
if [ "${BB_CURRENTTASK}" = "populate_sysroot" ]; then
${gdkpixbuf_complete}
elif [ "${BB_CURRENTTASK}" = "populate_sysroot_setscene" ]; then
- echo "${gdkpixbuf_complete}" >> ${STAGING_DIR}/sstatecompletions
+ if [ -x ${STAGING_LIBDIR_NATIVE}/gdk-pixbuf-2.0/gdk-pixbuf-query-loaders ]; then
+ echo "${gdkpixbuf_complete}" >> ${STAGING_DIR}/sstatecompletions
+ fi
fi
}
-