summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/rpm/rpm
diff options
context:
space:
mode:
authorMark Hatle <mark.hatle@windriver.com>2013-08-09 17:51:30 -0500
committerSaul Wold <sgw@linux.intel.com>2013-08-13 10:13:19 -0700
commit6513fa327aeb7e9fdd313290c205917952eed226 (patch)
tree939ffe0f271dc153068c485d407365ac82d6430e /meta/recipes-devtools/rpm/rpm
parenta84ecc5ad158a7529a904785de25ebfedf5767a7 (diff)
downloadopenembedded-core-6513fa327aeb7e9fdd313290c205917952eed226.tar.gz
rpm: Enable compatibility with older RPM packages that have invalid platforms
Some LSB packages appear to have the platform set to '%{_target_platform}' which is not a valid platform field. This causes a failure of the type: warning: package lsb-test-core-4.1.15-1.x86_64 is intended for a %{_target_platform} platform When we detect an invalid platform, fall back and try to construct a new platform name that may be valid based on the arch and os contents of the package. (This should only ever be needed by invalid or older RPM packages.) Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
Diffstat (limited to 'meta/recipes-devtools/rpm/rpm')
-rw-r--r--meta/recipes-devtools/rpm/rpm/rpm-lsb-compatibility.patch24
1 files changed, 24 insertions, 0 deletions
diff --git a/meta/recipes-devtools/rpm/rpm/rpm-lsb-compatibility.patch b/meta/recipes-devtools/rpm/rpm/rpm-lsb-compatibility.patch
new file mode 100644
index 0000000000..7101e5cbda
--- /dev/null
+++ b/meta/recipes-devtools/rpm/rpm/rpm-lsb-compatibility.patch
@@ -0,0 +1,24 @@
+Enable platform tag matching workaround in OE.
+
+When installing some LSB packages the 'platform' field in the package
+appears to be invalid. Instead of relying solely on the platform comparison
+we also want to generate a perceived platform based on the valid rpm contents
+of arch and os.
+
+Upstream-Status: Pending
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+
+Index: rpm-5.4.9/lib/depends.c
+===================================================================
+--- rpm-5.4.9.orig/lib/depends.c
++++ rpm-5.4.9/lib/depends.c
+@@ -594,7 +594,7 @@ int rpmtsAddInstallElement(rpmts ts, Hea
+ platform = rpmExpand(arch, "-unknown-", os, NULL);
+
+ rc = rpmPlatformScore(platform, platpat, nplatpat);
+-#if defined(RPM_VENDOR_MANDRIVA)
++#if defined(RPM_VENDOR_MANDRIVA) || defined(RPM_VENDOR_OE)
+ /*
+ * If no match on platform tag, we'll try again with arch tag
+ * in case platform tag is inconsistent with it, which is the case