From: "Zac Medico" <zmedico@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] proj/portage:master commit in: pym/portage/package/ebuild/_config/, pym/portage/
Date: Sat, 19 Jan 2013 22:02:27 +0000 (UTC) [thread overview]
Message-ID: <1358632886.00c9dd27618d20acdb9a700fbef09e292c329fe3.zmedico@gentoo> (raw)
commit: 00c9dd27618d20acdb9a700fbef09e292c329fe3
Author: Zac Medico <zmedico <AT> gentoo <DOT> org>
AuthorDate: Sat Jan 19 22:01:26 2013 +0000
Commit: Zac Medico <zmedico <AT> gentoo <DOT> org>
CommitDate: Sat Jan 19 22:01:26 2013 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=00c9dd27
Fix stable mask logic for repoman.
For repoman, if the package has an effective stable keyword that
intersects with the effective ACCEPT_KEYWORDS for the current
profile, then consider it stable.
---
.../package/ebuild/_config/KeywordsManager.py | 28 +++++++++++++------
pym/portage/versions.py | 5 +++-
2 files changed, 23 insertions(+), 10 deletions(-)
diff --git a/pym/portage/package/ebuild/_config/KeywordsManager.py b/pym/portage/package/ebuild/_config/KeywordsManager.py
index d477889..3e029c3 100644
--- a/pym/portage/package/ebuild/_config/KeywordsManager.py
+++ b/pym/portage/package/ebuild/_config/KeywordsManager.py
@@ -111,15 +111,25 @@ class KeywordsManager(object):
if self._getMissingKeywords(pkg, pgroups, mygroups):
return False
- # If replacing all keywords with unstable variants would mask the
- # package, then it's considered stable.
- unstable = []
- for kw in mygroups:
- if kw[:1] != "~":
- kw = "~" + kw
- unstable.append(kw)
-
- return bool(self._getMissingKeywords(pkg, pgroups, set(unstable)))
+ if pkg.cpv._settings.local_config:
+ # If replacing all keywords with unstable variants would mask the
+ # package, then it's considered stable.
+ unstable = []
+ for kw in mygroups:
+ if kw[:1] != "~":
+ kw = "~" + kw
+ unstable.append(kw)
+
+ return bool(self._getMissingKeywords(pkg, pgroups, set(unstable)))
+ else:
+ # For repoman, if the package has an effective stable keyword that
+ # intersects with the effective ACCEPT_KEYWORDS for the current
+ # profile, then consider it stable.
+ for kw in pgroups:
+ if kw[:1] != "~":
+ if kw in mygroups:
+ return True
+ return False
def getMissingKeywords(self,
cpv,
diff --git a/pym/portage/versions.py b/pym/portage/versions.py
index d78873f..1dd2ff3 100644
--- a/pym/portage/versions.py
+++ b/pym/portage/versions.py
@@ -409,7 +409,10 @@ class _pkg_str(_unicode):
except AttributeError:
raise AttributeError('stable')
stable = settings._isStable(self)
- self.__dict__['_stable'] = stable
+ if settings.local_config:
+ # For repoman, don't cache this value, since
+ # it needs to be re-computed for each profile.
+ self.__dict__['_stable'] = stable
return stable
def pkgsplit(mypkg, silent=1, eapi=None):
next reply other threads:[~2013-01-19 22:02 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-01-19 22:02 Zac Medico [this message]
-- strict thread matches above, loose matches on Subject: below --
2013-06-21 22:24 [gentoo-commits] proj/portage:master commit in: pym/portage/package/ebuild/_config/, pym/portage/ Zac Medico
2012-09-21 3:29 Arfrever Frehtes Taifersar Arahesis
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1358632886.00c9dd27618d20acdb9a700fbef09e292c329fe3.zmedico@gentoo \
--to=zmedico@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox