1 |
Support -* in order to make it easier to create profiles for |
2 |
minimal systems (especially those built entirely from binary |
3 |
packages). |
4 |
|
5 |
X-Gentoo-Bug: 610670 |
6 |
X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=610670 |
7 |
--- |
8 |
pym/portage/util/__init__.py | 9 ++++++++- |
9 |
1 file changed, 8 insertions(+), 1 deletion(-) |
10 |
|
11 |
diff --git a/pym/portage/util/__init__.py b/pym/portage/util/__init__.py |
12 |
index c2c871f..45710ba 100644 |
13 |
--- a/pym/portage/util/__init__.py |
14 |
+++ b/pym/portage/util/__init__.py |
15 |
@@ -478,13 +478,20 @@ def grabfile_package(myfilename, compatlevel=0, recursive=0, |
16 |
eapi = read_corresponding_eapi_file( |
17 |
myfilename, default=eapi_default) |
18 |
mybasename = os.path.basename(myfilename) |
19 |
+ is_packages_file = mybasename == 'packages' |
20 |
atoms = [] |
21 |
for pkg, source_file in pkgs: |
22 |
pkg_orig = pkg |
23 |
# for packages and package.mask files |
24 |
if pkg[:1] == "-": |
25 |
+ if is_packages_file and pkg == '-*': |
26 |
+ if remember_source_file: |
27 |
+ atoms.append((pkg, source_file)) |
28 |
+ else: |
29 |
+ atoms.append(pkg) |
30 |
+ continue |
31 |
pkg = pkg[1:] |
32 |
- if pkg[:1] == '*' and mybasename == 'packages': |
33 |
+ if pkg[:1] == '*' and is_packages_file: |
34 |
pkg = pkg[1:] |
35 |
try: |
36 |
pkg = Atom(pkg, allow_wildcard=allow_wildcard, |
37 |
-- |
38 |
2.10.2 |