summaryrefslogtreecommitdiff
path: root/meta/recipes-graphics/pango
diff options
context:
space:
mode:
authorLaurentiu Palcu <laurentiu.palcu@intel.com>2012-12-19 21:13:38 +0200
committerSaul Wold <sgw@linux.intel.com>2013-01-04 22:01:20 -0800
commit75334cbee1f064b38f167269917e333989802e7d (patch)
treeaec28a0a0dc231b1ca7f89e9b6bbf3d459058696 /meta/recipes-graphics/pango
parentb693f6d3d48b281fbbf71fd56996c85e23c3a9c9 (diff)
downloadopenembedded-core-75334cbee1f064b38f167269917e333989802e7d.tar.gz
openembedded-core-75334cbee1f064b38f167269917e333989802e7d.tar.bz2
openembedded-core-75334cbee1f064b38f167269917e333989802e7d.zip
pango: have postinstalls run at do_rootfs time
Since pango-native is built anyway and all the modules are in the native sysroot, create the cache file by scanning those files instead of the target files. The latter will fail because the shared objects wouldn't be from the same ELF class. [YOCTO #3600] Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
Diffstat (limited to 'meta/recipes-graphics/pango')
-rw-r--r--meta/recipes-graphics/pango/pango.inc26
1 files changed, 22 insertions, 4 deletions
diff --git a/meta/recipes-graphics/pango/pango.inc b/meta/recipes-graphics/pango/pango.inc
index 839c00d933..81c2a7ee65 100644
--- a/meta/recipes-graphics/pango/pango.inc
+++ b/meta/recipes-graphics/pango/pango.inc
@@ -10,7 +10,7 @@ SECTION = "libs"
LICENSE = "LGPLv2.0+"
X11DEPENDS = "virtual/libx11 libxft"
-DEPENDS = "glib-2.0 fontconfig freetype zlib virtual/libiconv cairo elfutils"
+DEPENDS = "glib-2.0 fontconfig freetype zlib virtual/libiconv cairo elfutils pango-native"
PACKAGECONFIG ??= "${@base_contains('DISTRO_FEATURES', 'x11', 'x11', '', d)}"
PACKAGECONFIG[x11] = "--with-x,--without-x,${X11DEPENDS}"
@@ -44,13 +44,31 @@ LEAD_SONAME = "libpango-1.0*"
LIBV = "1.6.0"
postinst_prologue() {
+if ! [ -e $D${sysconfdir}/pango ] ; then
+ mkdir -p $D${sysconfdir}/pango
+fi
+
if [ "x$D" != "x" ]; then
- exit 1
+pango-querymodules $(ls -d -1 $D${libdir}/pango/${LIBV}/modules/*.so|\
+ sed -e "s:$D:$NATIVE_ROOT:g") >\
+ $D${sysconfdir}/pango/${MLPREFIX}pango.modules \
+ 2>$D${sysconfdir}/pango/${MLPREFIX}pango.err
+
+# pango-querymodules always returns 0, so we need to check if pango.err has
+# anything in it
+if [ -s $D${sysconfdir}/pango/${MLPREFIX}pango.err ]; then
+ rm $D${sysconfdir}/pango/${MLPREFIX}pango.err
+ exit 1
fi
-if ! [ -e $D${sysconfdir}/pango ] ; then
- mkdir -p $D${sysconfdir}/pango
+sed -i -e "s:$NATIVE_ROOT::g" $D${sysconfdir}/pango/${MLPREFIX}pango.modules
+
+# remove the empty pango.err
+rm $D${sysconfdir}/pango/${MLPREFIX}pango.err
+
+exit 0
fi
+
}
do_install_append () {