[yum] Add ppc64 arch. change for BZ 713791.

James Antill james at fedoraproject.org
Tue Jun 28 21:08:35 UTC 2011


commit e3b4642edaa824dc8546f637e760648dc2ee2c8e
Author: James Antill <james at and.org>
Date:   Tue Jun 28 17:03:31 2011 -0400

    Add ppc64 arch. change for BZ 713791.

 yum-HEAD.patch            |   40 ++++++++++++++++++++++++++++++++++++++++
 yum-ppc64-preferred.patch |   13 +++++++++++++
 yum.spec                  |    7 ++++++-
 3 files changed, 59 insertions(+), 1 deletions(-)
---
diff --git a/yum-HEAD.patch b/yum-HEAD.patch
index 8501f19..c54d12e 100644
--- a/yum-HEAD.patch
+++ b/yum-HEAD.patch
@@ -1,3 +1,43 @@
+diff --git a/rpmUtils/arch.py b/rpmUtils/arch.py
+index 6082005..ad7bbb1 100644
+--- a/rpmUtils/arch.py
++++ b/rpmUtils/arch.py
+@@ -3,6 +3,8 @@
+ 
+ import os
+ 
++_ppc64_native_is_best = False
++
+ # dict mapping arch -> ( multicompat, best personality, biarch personality )
+ multilibArches = { "x86_64":  ( "athlon", "x86_64", "athlon" ),
+                    "sparc64v": ( "sparcv9v", "sparcv9v", "sparc64v" ),
+@@ -10,6 +12,8 @@ multilibArches = { "x86_64":  ( "athlon", "x86_64", "athlon" ),
+                    "ppc64":   ( "ppc", "ppc", "ppc64" ),
+                    "s390x":   ( "s390", "s390x", "s390" ),
+                    }
++if _ppc64_native_is_best:
++    multilibArches["ppc64"] = ( "ppc", "ppc64", "ppc64" )
+ 
+ arches = {
+     # ia32
+@@ -339,7 +343,7 @@ def getBestArch(myarch=None):
+     if arch.startswith("sparc64"):
+         arch = multilibArches[arch][1]
+ 
+-    if arch.startswith("ppc64"):
++    if arch.startswith("ppc64") and not _ppc64_native_is_best:
+         arch = 'ppc'
+ 
+     return arch
+@@ -357,7 +361,7 @@ def getBaseArch(myarch=None):
+ 
+     if myarch.startswith("sparc64"):
+         return "sparc"
+-    elif myarch.startswith("ppc64"):
++    elif myarch.startswith("ppc64") and not _ppc64_native_is_best:
+         return "ppc"
+     elif myarch.startswith("arm"):
+         return "arm"
 diff --git a/yum.spec b/yum.spec
 index abd203f..9e7ed43 100644
 --- a/yum.spec
diff --git a/yum-ppc64-preferred.patch b/yum-ppc64-preferred.patch
new file mode 100644
index 0000000..0aa1b4e
--- /dev/null
+++ b/yum-ppc64-preferred.patch
@@ -0,0 +1,13 @@
+diff -ru yum-3.4.3-orig/rpmUtils/arch.py yum-3.4.3/rpmUtils/arch.py
+--- yum-3.4.3-orig/rpmUtils/arch.py	2011-06-28 17:01:10.009680846 -0400
++++ yum-3.4.3/rpmUtils/arch.py	2011-06-28 17:01:31.849916539 -0400
+@@ -3,7 +3,7 @@
+ 
+ import os
+ 
+-_ppc64_native_is_best = False
++_ppc64_native_is_best = True
+ 
+ # dict mapping arch -> ( multicompat, best personality, biarch personality )
+ multilibArches = { "x86_64":  ( "athlon", "x86_64", "athlon" ),
+Only in yum-3.4.3/rpmUtils: arch.py~
diff --git a/yum.spec b/yum.spec
index 7fdb389..4b396c9 100644
--- a/yum.spec
+++ b/yum.spec
@@ -7,7 +7,7 @@
 Summary: RPM package installer/updater/manager
 Name: yum
 Version: 3.4.3
-Release: 1%{?dist}
+Release: 2%{?dist}
 License: GPLv2+
 Group: System Environment/Base
 Source0: http://yum.baseurl.org/download/3.4/%{name}-%{version}.tar.gz
@@ -19,6 +19,7 @@ Patch3: yum-multilib-policy-best.patch
 Patch4: no-more-exactarchlist.patch
 Patch5: geode-arch.patch
 Patch6: yum-HEAD.patch
+Patch7: yum-ppc64-preferred.patch
 Patch20: yum-manpage-files.patch
 
 URL: http://yum.baseurl.org/
@@ -123,6 +124,7 @@ Install this package if you want auto yum updates nightly via cron.
 %patch4 -p0
 %patch5 -p1
 %patch6 -p1
+%patch7 -p1
 %patch20 -p1
 
 %build
@@ -246,6 +248,9 @@ exit 0
 %config(noreplace) %{_sysconfdir}/sysconfig/yum-cron
 
 %changelog
+* Wed Jun 29 2011 James Antill <james at fedoraproject.org> - 3.4.3-2
+- Add ppc64 arch. change for BZ 713791.
+
 * Tue Jun 28 2011 James Antill <james at fedoraproject.org> - 3.4.3-1
 - update to 3.4.3
 - Real upstream workaround for rpm chroot and history insanity.


More information about the scm-commits mailing list