From dde6df65ecbc522dc23cb8d24be3e4dd52657da8 Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Fri, 13 Jul 2012 16:33:49 -0700 Subject: slotmove: fix handling for EAPI 4-slot-abi This is just a really minimal fix, in order to prevent slotmove from behaving incorrectly with packages that use EAPI 4-slot-abi. Any slotmove commands that try so specify a sub-slot are treated as invalid for now, since that will required additional EAPI conditional logic, as reported in bug #426476. --- pym/portage/_global_updates.py | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'pym/portage/_global_updates.py') diff --git a/pym/portage/_global_updates.py b/pym/portage/_global_updates.py index 51750431d..c0f3df0b6 100644 --- a/pym/portage/_global_updates.py +++ b/pym/portage/_global_updates.py @@ -1,4 +1,4 @@ -# Copyright 2010 Gentoo Foundation +# Copyright 2010-2012 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 from __future__ import print_function @@ -32,11 +32,15 @@ def _global_updates(trees, prev_mtimes, quiet=False, if_mtime_changed=True): """ # only do this if we're root and not running repoman/ebuild digest - retupd = False if secpass < 2 or \ "SANDBOX_ACTIVE" in os.environ or \ len(trees) != 1: - return retupd + return False + + return _do_global_updates(trees, prev_mtimes, + quiet=quiet, if_mtime_changed=if_mtime_changed) + +def _do_global_updates(trees, prev_mtimes, quiet=False, if_mtime_changed=True): root = trees._running_eroot mysettings = trees[root]["vartree"].settings portdb = trees[root]["porttree"].dbapi @@ -61,6 +65,7 @@ def _global_updates(trees, prev_mtimes, quiet=False, if_mtime_changed=True): repo_map = {} timestamps = {} + retupd = False update_notice_printed = False for repo_name in portdb.getRepositories(): repo = portdb.getRepositoryPath(repo_name) @@ -237,8 +242,7 @@ def _global_updates(trees, prev_mtimes, quiet=False, if_mtime_changed=True): # Update progress above is indicated by characters written to stdout so # we print a couple new lines here to separate the progress output from # what follows. - print() - print() + writemsg_stdout("\n\n") if do_upgrade_packagesmessage and bindb and \ bindb.cpv_all(): -- cgit v1.2.3-1-g7c22