[oe-commits] [openembedded-core] 03/13: libc-package.bbclass: Only extract wanted files in prep_locale_tree()

git at git.openembedded.org git at git.openembedded.org
Sun Feb 17 22:25:27 UTC 2019


This is an automated email from the git hooks/post-receive script.

rpurdie pushed a commit to branch master-next
in repository openembedded-core.

commit 6b0042a53c4cc1a9bd403f3cf0fce0e65ef4b714
Author: Peter Kjellerstedt <peter.kjellerstedt at axis.com>
AuthorDate: Sun Feb 17 15:51:06 2019 +0100

    libc-package.bbclass: Only extract wanted files in prep_locale_tree()
    
    prep_locale_tree() predates the usrmerge DISTRO_FEATURE, which meant it
    was not prepared for the case when ${base_libdir} == ${libdir}. This
    lead to it extracting files and directories where it shouldn't.
    
    Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt at axis.com>
    Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
---
 meta/classes/libc-package.bbclass | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/meta/classes/libc-package.bbclass b/meta/classes/libc-package.bbclass
index 60000a9..ee59890 100644
--- a/meta/classes/libc-package.bbclass
+++ b/meta/classes/libc-package.bbclass
@@ -67,7 +67,12 @@ do_prep_locale_tree() {
 	for i in $treedir/${datadir}/i18n/charmaps/*gz; do 
 		gunzip $i
 	done
-	tar -cf - -C ${LOCALETREESRC}${base_libdir} -p . | tar -xf - -C $treedir/${base_libdir}
+	# The extract pattern "./l*.so*" is carefully selected so that it will
+	# match ld*.so and lib*.so*, but not any files in the gconv directory
+	# (if it exists). This makes sure we only unpack the files we need.
+	# This is important in case usrmerge is set in DISTRO_FEATURES, which
+	# means ${base_libdir} == ${libdir}.
+	tar -cf - -C ${LOCALETREESRC}${base_libdir} -p . | tar -xf - -C $treedir/${base_libdir} './l*.so*'
 	if [ -f ${STAGING_LIBDIR_NATIVE}/libgcc_s.* ]; then
 		tar -cf - -C ${STAGING_LIBDIR_NATIVE} -p libgcc_s.* | tar -xf - -C $treedir/${base_libdir}
 	fi

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Openembedded-commits mailing list