summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2010-08-15 20:46:39 -0700
committerZac Medico <zmedico@gentoo.org>2010-08-15 20:46:39 -0700
commit39020a6a418c0910b372e04a8f4959ce258d1989 (patch)
tree27f5b95721239b6784a507ab8cb5510bb84a638a
parent3158c7762983e54bf83061d5fd6f3b656fb0c10a (diff)
downloadportage-39020a6a418c0910b372e04a8f4959ce258d1989.tar.gz
portage-39020a6a418c0910b372e04a8f4959ce258d1989.tar.bz2
portage-39020a6a418c0910b372e04a8f4959ce258d1989.zip
Add support for /etc/portage/package.accept_keywords. If both
package.accept_keywords and package.keywords are present, both of them will be used, and values from package.accept_keywords will override values from package.keywords. The package.accept_keywords file is intended to replace the package.keywords file, since profiles support a different form of package.keywords which modifies effective KEYWORDS (rather than ACCEPT_KEYWORDS). Note that bug #292083 requests support for package.accept_keywords in profiles.
-rw-r--r--man/portage.521
-rw-r--r--pym/portage/package/ebuild/config.py8
2 files changed, 21 insertions, 8 deletions
diff --git a/man/portage.5 b/man/portage.5
index e9da4c339..41224deb3 100644
--- a/man/portage.5
+++ b/man/portage.5
@@ -51,6 +51,7 @@ color.map
make.conf
mirrors
modules
+package.accept_keywords
package.keywords
package.license
package.mask
@@ -408,9 +409,9 @@ it were a single file.
.I Example:
.nf
-/etc/portage/package.keywords/common
-/etc/portage/package.keywords/e17
-/etc/portage/package.keywords/kde
+/etc/portage/package.accept_keywords/common
+/etc/portage/package.accept_keywords/e17
+/etc/portage/package.accept_keywords/kde
.fi
.RS
.TP
@@ -489,10 +490,16 @@ listed in \fBPORTDIR_OVERLAY\fR or a cvs tree, run `emerge \-\-regen`
to keep all metadata in that format alone (useful for querying), enable
FEATURES="metadata-transfer" in \fBmake.conf\fR(5).
.TP
-.BR package.keywords
-Per\-package KEYWORDS. Useful for mixing unstable packages in with a normally
+\fBpackage.accept_keywords\fR and \fBpackage.keywords\fR
+Per\-package ACCEPT_KEYWORDS. Useful for mixing unstable packages in with a normally
stable system or vice versa. This will allow ACCEPT_KEYWORDS to be augmented
-for a single package.
+for a single package. If both \fBpackage.accept_keywords\fR and
+\fBpackage.keywords\fR are present, both of them will be used, and values
+from \fBpackage.accept_keywords\fR will override values from
+\fBpackage.keywords\fR. The \fBpackage.accept_keywords\fR file is
+intended to replace the \fBpackage.keywords\fR file, since
+profiles support a different form of \fBpackage.keywords\fR which
+modifies effective KEYWORDS (rather than ACCEPT_KEYWORDS).
.I Format:
.nf
@@ -528,7 +535,7 @@ example, a binary only package which is built for x86 will look like:
games-fps/quake3-demo-1.11.ebuild:KEYWORDS="-* x86"
If you wish to accept this package anyways, then use one of the other keywords in your
-package.keywords like this:
+package.accept_keywords like this:
games-fps/quake3-demo x86
diff --git a/pym/portage/package/ebuild/config.py b/pym/portage/package/ebuild/config.py
index 23280d6f3..640a244f2 100644
--- a/pym/portage/package/ebuild/config.py
+++ b/pym/portage/package/ebuild/config.py
@@ -851,10 +851,16 @@ class config(object):
for k, v in pusedict.items():
self.pusedict.setdefault(k.cp, {})[k] = v
- #package.keywords
+ # package.accept_keywords and package.keywords
pkgdict = grabdict_package(
os.path.join(abs_user_config, "package.keywords"),
recursive=1, allow_wildcard=True)
+
+ for k, v in grabdict_package(
+ os.path.join(abs_user_config, "package.accept_keywords"),
+ recursive=1, allow_wildcard=True).items():
+ pkgdict.setdefault(k, []).extend(v)
+
for k, v in pkgdict.items():
# default to ~arch if no specific keyword is given
if not v: