[oe-commits] Jonathan Liu : postinst-intercepts/update_font_cache: fix ownership of fontconfig cache

git at git.openembedded.org git at git.openembedded.org
Mon Mar 16 17:42:36 UTC 2015


Module: openembedded-core.git
Branch: master
Commit: 23393c6685860d0b1c459874d35395360d0b6d3c
URL:    http://git.openembedded.org/?p=openembedded-core.git&a=commit;h=23393c6685860d0b1c459874d35395360d0b6d3c

Author: Jonathan Liu <net147 at gmail.com>
Date:   Mon Mar  9 13:28:37 2015 +1100

postinst-intercepts/update_font_cache: fix ownership of fontconfig cache

The file ownership of the cache files in /var/cache/fontconfig needs to
be set to root:root otherwise it inherits the user and group id of the
build user.

[YOCTO #7411]

Signed-off-by: Jonathan Liu <net147 at gmail.com>
Signed-off-by: Ross Burton <ross.burton at intel.com>

---

 meta/classes/fontcache.bbclass                | 2 +-
 scripts/postinst-intercepts/update_font_cache | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/meta/classes/fontcache.bbclass b/meta/classes/fontcache.bbclass
index 2bf1e4b..ad5892c 100644
--- a/meta/classes/fontcache.bbclass
+++ b/meta/classes/fontcache.bbclass
@@ -12,7 +12,7 @@ FONT_EXTRA_RDEPENDS ?= "fontconfig-utils"
 fontcache_common() {
 if [ "x$D" != "x" ] ; then
 	$INTERCEPT_DIR/postinst_intercept update_font_cache ${PKG} mlprefix=${MLPREFIX} bindir=${bindir} \
-		libdir=${libdir} base_libdir=${base_libdir}
+		libdir=${libdir} base_libdir=${base_libdir} localstatedir=${localstatedir}
 else
 	fc-cache
 fi
diff --git a/scripts/postinst-intercepts/update_font_cache b/scripts/postinst-intercepts/update_font_cache
index 78f3365..3907f25 100644
--- a/scripts/postinst-intercepts/update_font_cache
+++ b/scripts/postinst-intercepts/update_font_cache
@@ -2,5 +2,6 @@
 
 PSEUDO_UNLOAD=1 qemuwrapper -L $D -E LD_LIBRARY_PATH=$D/${libdir}:$D/${base_libdir}\
 					$D${bindir}/fc-cache --sysroot=$D
+chown -R root:root $D${localstatedir}/cache/fontconfig
 
 



More information about the Openembedded-commits mailing list