summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2010-11-19 15:21:53 -0800
committerZac Medico <zmedico@gentoo.org>2010-11-19 15:21:53 -0800
commitb20c1f019a32b50e95f6fa40cd78021d62249d4b (patch)
tree34a98c310b4fb9bba5bc1c10afb61a0c060f0364
parent637a13355cf4cc2906e34b61606d31d62acc9fcc (diff)
downloadportage-b20c1f019a32b50e95f6fa40cd78021d62249d4b.tar.gz
portage-b20c1f019a32b50e95f6fa40cd78021d62249d4b.tar.bz2
portage-b20c1f019a32b50e95f6fa40cd78021d62249d4b.zip
Handle combination of incremental + USE_EXPAND
This fixes a corner case in the code from the previous commit.
-rw-r--r--pym/portage/package/ebuild/config.py11
1 files changed, 9 insertions, 2 deletions
diff --git a/pym/portage/package/ebuild/config.py b/pym/portage/package/ebuild/config.py
index 5ece5b0f3..6c513c696 100644
--- a/pym/portage/package/ebuild/config.py
+++ b/pym/portage/package/ebuild/config.py
@@ -1746,8 +1746,15 @@ class config(object):
if v is None:
continue
prefix = k.lower() + '_'
- for x in v.split():
- expand_use.append(prefix + x)
+ if k in myincrementals:
+ for x in v.split():
+ if x[:1] == '-':
+ expand_use.append('-' + prefix + x[1:])
+ else:
+ expand_use.append(prefix + x)
+ else:
+ for x in v.split():
+ expand_use.append(prefix + x)
if expand_use:
expand_use.append(use)
use = ' '.join(expand_use)