From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1QNwqf-0007IT-Jo for garchives@archives.gentoo.org; Sun, 22 May 2011 00:48:49 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id B0CB5E032F; Sun, 22 May 2011 00:48:40 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id 5EC4EE032F for ; Sun, 22 May 2011 00:48:40 +0000 (UTC) Received: from pelican.gentoo.org (unknown [66.219.59.40]) (using TLSv1 with cipher ADH-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id BDCFD1B401A for ; Sun, 22 May 2011 00:48:39 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by pelican.gentoo.org (Postfix) with ESMTP id 1AF1480506 for ; Sun, 22 May 2011 00:48:39 +0000 (UTC) From: "Zac Medico" To: gentoo-commits@lists.gentoo.org Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Zac Medico" Message-ID: Subject: [gentoo-commits] proj/portage:master commit in: pym/_emerge/ X-VCS-Repository: proj/portage X-VCS-Files: pym/_emerge/DepPriority.py pym/_emerge/DepPrioritySatisfiedRange.py pym/_emerge/depgraph.py X-VCS-Directories: pym/_emerge/ X-VCS-Committer: zmedico X-VCS-Committer-Name: Zac Medico X-VCS-Revision: d4bf8dc02293cfc81c19f39b12b5e180a5e12645 Date: Sun, 22 May 2011 00:48:39 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: quoted-printable X-Archives-Salt: X-Archives-Hash: d847bfa7cdb6908f9fcfd00218e292d1 commit: d4bf8dc02293cfc81c19f39b12b5e180a5e12645 Author: Zac Medico gentoo org> AuthorDate: Sun May 22 00:46:11 2011 +0000 Commit: Zac Medico gentoo org> CommitDate: Sun May 22 00:46:11 2011 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=3Dproj/portage.git;a= =3Dcommit;h=3Dd4bf8dc0 DepPriority: remove "rebuild" attribute Since the addition of DepPriorityNormalRange and DepPrioritySatisfiedRange in commit bd369956b2a2fbc019a655a372628998499156c0, which solves most cases of bug 199856, the Depriority.rebuild attribute doesn't appear to make any difference. The edges that this attribute differentiates are already naturally differentiated by the fact that the child node of a satisfied buildtime dependency that's not being rebuilt will naturally be identified as a leaf node earlier and removed from the graph, thereby eliminating the edge before there's an opportunity to compare it with a higher priority rebuild edge. The addition of the "optional" attribute (in commit 15476805a156acd11fdaaa19212691e8ee09b309) also plays a role here, since it converts some satisfied buildtime edges to optional edges, thereby reducing their priority. --- pym/_emerge/DepPriority.py | 2 +- pym/_emerge/DepPrioritySatisfiedRange.py | 31 +++++++-----------------= ----- pym/_emerge/depgraph.py | 12 ----------- 3 files changed, 9 insertions(+), 36 deletions(-) diff --git a/pym/_emerge/DepPriority.py b/pym/_emerge/DepPriority.py index 252a81e..3c2256a 100644 --- a/pym/_emerge/DepPriority.py +++ b/pym/_emerge/DepPriority.py @@ -4,7 +4,7 @@ from _emerge.AbstractDepPriority import AbstractDepPriority class DepPriority(AbstractDepPriority): =20 - __slots__ =3D ("satisfied", "optional", "rebuild", "ignored") + __slots__ =3D ("satisfied", "optional", "ignored") =20 def __int__(self): """ diff --git a/pym/_emerge/DepPrioritySatisfiedRange.py b/pym/_emerge/DepPr= ioritySatisfiedRange.py index 7fa2f09..edb29df 100644 --- a/pym/_emerge/DepPrioritySatisfiedRange.py +++ b/pym/_emerge/DepPrioritySatisfiedRange.py @@ -7,18 +7,17 @@ class DepPrioritySatisfiedRange(object): DepPriority Index Category =20 not satisfied and buildtime HARD - not satisfied and runtime 7 MEDIUM - not satisfied and runtime_post 6 MEDIUM_SOFT - satisfied and buildtime and rebuild 5 SOFT + not satisfied and runtime 6 MEDIUM + not satisfied and runtime_post 5 MEDIUM_SOFT satisfied and buildtime 4 SOFT satisfied and runtime 3 SOFT satisfied and runtime_post 2 SOFT optional 1 SOFT (none of the above) 0 NONE """ - MEDIUM =3D 7 - MEDIUM_SOFT =3D 6 - SOFT =3D 5 + MEDIUM =3D 6 + MEDIUM_SOFT =3D 5 + SOFT =3D 4 NONE =3D 0 =20 @classmethod @@ -51,21 +50,8 @@ class DepPrioritySatisfiedRange(object): def _ignore_satisfied_buildtime(cls, priority): if priority.__class__ is not DepPriority: return False - if priority.optional: - return True - if not priority.satisfied: - return False - if priority.buildtime: - return not priority.rebuild - return True - - @classmethod - def _ignore_satisfied_buildtime_rebuild(cls, priority): - if priority.__class__ is not DepPriority: - return False - if priority.optional: - return True - return bool(priority.satisfied) + return bool(priority.optional or \ + priority.satisfied) =20 @classmethod def _ignore_runtime_post(cls, priority): @@ -85,7 +71,7 @@ class DepPrioritySatisfiedRange(object): =20 ignore_medium =3D _ignore_runtime ignore_medium_soft =3D _ignore_runtime_post - ignore_soft =3D _ignore_satisfied_buildtime_rebuild + ignore_soft =3D _ignore_satisfied_buildtime =20 =20 DepPrioritySatisfiedRange.ignore_priority =3D ( @@ -94,7 +80,6 @@ DepPrioritySatisfiedRange.ignore_priority =3D ( DepPrioritySatisfiedRange._ignore_satisfied_runtime_post, DepPrioritySatisfiedRange._ignore_satisfied_runtime, DepPrioritySatisfiedRange._ignore_satisfied_buildtime, - DepPrioritySatisfiedRange._ignore_satisfied_buildtime_rebuild, DepPrioritySatisfiedRange._ignore_runtime_post, DepPrioritySatisfiedRange._ignore_runtime ) diff --git a/pym/_emerge/depgraph.py b/pym/_emerge/depgraph.py index 3ef47f8..d09ee87 100644 --- a/pym/_emerge/depgraph.py +++ b/pym/_emerge/depgraph.py @@ -1036,18 +1036,6 @@ class depgraph(object): return 0 =20 if not pkg.onlydeps: - if not pkg.installed and \ - "empty" not in self._dynamic_config.myparams and \ - vardbapi.match(pkg.slot_atom): - # Increase the priority of dependencies on packages that - # are being rebuilt. This optimizes merge order so that - # dependencies are rebuilt/updated as soon as possible, - # which is needed especially when emerge is called by - # revdep-rebuild since dependencies may be affected by ABI - # breakage that has rendered them useless. Don't adjust - # priority here when in "empty" mode since all packages - # are being merged in that case. - priority.rebuild =3D True =20 existing_node, existing_node_matches =3D \ self._check_slot_conflict(pkg, dep.atom)