Patchwork [1/3] debian/_ipk.bbclass: Added multilib support for package_name_hook()

login
register
mail settings
Submitter Lianhao Lu
Date Sept. 16, 2011, 1:01 p.m.
Message ID <4d2f36c3f695ed2ad6d38c9f97e30eec306156ba.1316177782.git.lianhao.lu@intel.com>
Download mbox | patch
Permalink /patch/11557/
State New, archived
Headers show

Comments

Lianhao Lu - Sept. 16, 2011, 1:01 p.m.
[YOCTO #1486]
1. Added multilib support for package_name_hook() so MLPREFIX is kept in
the final package name.

2. clean the output of log_check_ipk.

Signed-off-by: Lianhao Lu <lianhao.lu@intel.com>
---
 meta/classes/debian.bbclass      |    4 ++++
 meta/classes/package_ipk.bbclass |    1 +
 meta/classes/rootfs_ipk.bbclass  |    2 +-
 3 files changed, 6 insertions(+), 1 deletions(-)

Patch

diff --git a/meta/classes/debian.bbclass b/meta/classes/debian.bbclass
index 46a9d08..1880830 100644
--- a/meta/classes/debian.bbclass
+++ b/meta/classes/debian.bbclass
@@ -104,6 +104,10 @@  python debian_package_name_hook () {
 						newpkg = pkgname
 					else:
 						newpkg = pkg.replace(orig_pkg, devname, 1)
+					mlpre=bb.data.getVar('MLPREFIX', d, True)
+					if mlpre:
+						if not newpkg.find(mlpre) == 0:
+							newpkg = mlpre + newpkg
 					if newpkg != pkg:
 						bb.data.setVar('PKG_' + pkg, newpkg, d)
 
diff --git a/meta/classes/package_ipk.bbclass b/meta/classes/package_ipk.bbclass
index e83aff8..c0893a6 100644
--- a/meta/classes/package_ipk.bbclass
+++ b/meta/classes/package_ipk.bbclass
@@ -75,6 +75,7 @@  package_tryout_install_multilib_ipk() {
 			fi
 		done
 		if [ ! -z "${selected_pkg}" ]; then
+			rm -f ${target_rootfs}
 			mkdir -p ${target_rootfs}/${opkglibdir}
 			opkg-cl ${ipkg_args} update
 			opkg-cl ${ipkg_args} install ${selected_pkg}
diff --git a/meta/classes/rootfs_ipk.bbclass b/meta/classes/rootfs_ipk.bbclass
index 695bee0..e02b816 100644
--- a/meta/classes/rootfs_ipk.bbclass
+++ b/meta/classes/rootfs_ipk.bbclass
@@ -114,7 +114,7 @@  fakeroot rootfs_ipk_do_rootfs () {
 			rm -rf ${IMAGE_ROOTFS}${opkglibdir}
 		fi
 	fi
-
+	set +x
 	log_check rootfs 	
 }