summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--man/portage.51
-rw-r--r--pym/portage/__init__.py29
2 files changed, 15 insertions, 15 deletions
diff --git a/man/portage.5 b/man/portage.5
index d95d28d83..3e8eb7afc 100644
--- a/man/portage.5
+++ b/man/portage.5
@@ -31,6 +31,7 @@ packages
packages.build
package.mask
package.provided
+package.unmask
package.use
package.use.force
package.use.mask
diff --git a/pym/portage/__init__.py b/pym/portage/__init__.py
index f5207b8b2..bd5425d46 100644
--- a/pym/portage/__init__.py
+++ b/pym/portage/__init__.py
@@ -1282,9 +1282,8 @@ class config(object):
del rawpusemask
self.pkgprofileuse = []
- rawprofileuse = [grabdict_package(
- os.path.join(x, "package.use"), juststrings=True) \
- for x in self.profiles]
+ rawprofileuse = [grabdict_package(os.path.join(x, "package.use"),
+ juststrings=True, recursive=1) for x in self.profiles]
for i in xrange(len(self.profiles)):
cpdict = {}
for k, v in rawprofileuse[i].iteritems():
@@ -1516,17 +1515,6 @@ class config(object):
self._plicensedict[cp] = cp_dict
cp_dict[k] = self.expandLicenseTokens(v)
- #package.unmask
- pkgunmasklines = grabfile_package(
- os.path.join(abs_user_config, "package.unmask"),
- recursive=1)
- for x in pkgunmasklines:
- mycatpkg=dep_getkey(x)
- if mycatpkg in self.punmaskdict:
- self.punmaskdict[mycatpkg].append(x)
- else:
- self.punmaskdict[mycatpkg]=[x]
-
#getting categories from an external file now
categories = [grabfile(os.path.join(x, "categories")) for x in locations]
self.categories = stack_lists(categories, incremental=1)
@@ -1536,12 +1524,16 @@ class config(object):
archlist = stack_lists(archlist, incremental=1)
self.configdict["conf"]["PORTAGE_ARCHLIST"] = " ".join(archlist)
- #package.mask
+ # package.mask and package.unmask
pkgmasklines = []
+ pkgunmasklines = []
for x in pmask_locations:
pkgmasklines.append(grabfile_package(
os.path.join(x, "package.mask"), recursive=1))
+ pkgunmasklines.append(grabfile_package(
+ os.path.join(x, "package.unmask"), recursive=1))
pkgmasklines = stack_lists(pkgmasklines, incremental=1)
+ pkgunmasklines = stack_lists(pkgunmasklines, incremental=1)
self.pmaskdict = {}
for x in pkgmasklines:
@@ -1551,6 +1543,13 @@ class config(object):
else:
self.pmaskdict[mycatpkg]=[x]
+ for x in pkgunmasklines:
+ mycatpkg=dep_getkey(x)
+ if mycatpkg in self.punmaskdict:
+ self.punmaskdict[mycatpkg].append(x)
+ else:
+ self.punmaskdict[mycatpkg]=[x]
+
pkgprovidedlines = [grabfile(os.path.join(x, "package.provided")) for x in self.profiles]
pkgprovidedlines = stack_lists(pkgprovidedlines, incremental=1)
has_invalid_data = False