From: Zac Medico Date: Sat, 19 Feb 2011 22:53:45 +0000 (-0800) Subject: check_required_use: improve missing IUSE error X-Git-Tag: v2.1.9.41~14 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=91ae1f7c9902f48eb2d0826a96ea3ec6fae4cc62;p=portage.git check_required_use: improve missing IUSE error This will fix bug #355629. --- diff --git a/pym/portage/dep/__init__.py b/pym/portage/dep/__init__.py index a8d05f1f7..a92b481d1 100644 --- a/pym/portage/dep/__init__.py +++ b/pym/portage/dep/__init__.py @@ -2145,8 +2145,10 @@ def check_required_use(required_use, use, iuse_match): is_negated = False if not flag or not iuse_match(flag): - raise InvalidDependString( - _("malformed syntax: '%s'") % required_use) + msg = _("USE flag '%s' is not in IUSE") \ + % (flag,) + e = InvalidData(msg, category='IUSE.missing') + raise InvalidDependString(msg, errors=(e,)) return (flag in use and not is_negated) or \ (flag not in use and is_negated)