[Yum-devel] [PATCH] Don't update-install same version diff. arch local pkgs.

James Antill james at and.org
Thu Mar 10 18:43:40 UTC 2011


---
 yum/__init__.py |   10 ++++++++--
 1 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/yum/__init__.py b/yum/__init__.py
index 5c44245..36fc203 100644
--- a/yum/__init__.py
+++ b/yum/__init__.py
@@ -3956,11 +3956,17 @@ class YumBase(depsolve.Depsolve):
                 if (po.arch != installed_pkg.arch and
                     (isMultiLibArch(po.arch) or
                      isMultiLibArch(installed_pkg.arch))):
-                    installpkgs.append(po)
+                    if updateonly:
+                        self.logger.warning(_('Package %s.%s not installed, cannot update it. Run yum install to install it instead.'), po.name, po.arch)
+                    else:
+                        installpkgs.append(po)
                 else:
                     donothingpkgs.append(po)
             elif self.allowedMultipleInstalls(po):
-                installpkgs.append(po)
+                if updateonly:
+                    self.logger.warning(_('Package %s.%s not installed, cannot update it. Run yum install to install it instead.'), po.name, po.arch)
+                else:
+                    installpkgs.append(po)
             else:
                 donothingpkgs.append(po)
 
-- 
1.7.3.4



More information about the Yum-devel mailing list