All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] rootfs_rpm: add multilib prefix to rpm installed package list
@ 2012-09-18  0:17 Saul Wold
  2012-09-18  0:17 ` [PATCH v2] xserver-xorg: Modify RREPLACES for RCONFLICTS Saul Wold
  2012-09-18  4:18 ` [PATCH] rootfs_rpm: add multilib prefix to rpm installed package list Saul Wold
  0 siblings, 2 replies; 5+ messages in thread
From: Saul Wold @ 2012-09-18  0:17 UTC (permalink / raw)
  To: openembedded-core

RPM does not name it's packages with the Multilib prefix, but the rootfs_rpm class
keeps track of the Multilib prefixs in a list. Use that list to re-attach the prefix
for use with the license bbclass, buildhistory bbclass will also use this and make
it more accurate between multilib and non-multilib.

Signed-off-by: Saul Wold <sgw@linux.intel.com>
---
 meta/classes/rootfs_rpm.bbclass |   13 ++++++++++---
 1 files changed, 10 insertions(+), 3 deletions(-)

diff --git a/meta/classes/rootfs_rpm.bbclass b/meta/classes/rootfs_rpm.bbclass
index c0207d8..ad83ffb 100644
--- a/meta/classes/rootfs_rpm.bbclass
+++ b/meta/classes/rootfs_rpm.bbclass
@@ -142,11 +142,18 @@ RPM_QUERY_CMD = '${RPM} --root $INSTALL_ROOTFS_RPM -D "_dbpath ${rpmlibdir}" \
 
 list_installed_packages() {
 	if [ "$1" = "arch" ] ; then
-		${RPM_QUERY_CMD} -qa --qf "[%{NAME} %{ARCH}\n]"
+		GET_LIST=$(${RPM_QUERY_CMD} -qa --qf "[%{NAME} %{ARCH}\n]")
 	elif [ "$1" = "file" ] ; then
-		${RPM_QUERY_CMD} -qa --qf "[%{NAME} %{PACKAGEORIGIN}\n]"
+		GET_LIST=$(${RPM_QUERY_CMD} -qa --qf "[%{NAME} %{PACKAGEORIGIN}\n]")
 	else
-		${RPM_QUERY_CMD} -qa --qf "[%{NAME}\n]"
+		GET_LIST=$(${RPM_QUERY_CMD} -qa --qf "[%{NAME}\n]")
+	fi
+	if [ "x${MULTILIB_PREFIX_LIST}" = "x"]; then
+		echo "$GET_LIST"
+	else
+		for prefix in `echo ${MULTILIB_PREFIX_LIST}`; do
+			echo "$GET_LIST" | sed -e "s/^/$prefix\-/"
+		done
 	fi
 }
 
-- 
1.7.7.6




^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2012-09-18  4:31 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-09-18  0:17 [PATCH] rootfs_rpm: add multilib prefix to rpm installed package list Saul Wold
2012-09-18  0:17 ` [PATCH v2] xserver-xorg: Modify RREPLACES for RCONFLICTS Saul Wold
2012-09-18  2:40   ` Otavio Salvador
2012-09-18  4:17     ` Saul Wold
2012-09-18  4:18 ` [PATCH] rootfs_rpm: add multilib prefix to rpm installed package list Saul Wold

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.