diff options
Diffstat (limited to 'pym/_emerge/Package.py')
-rw-r--r-- | pym/_emerge/Package.py | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/pym/_emerge/Package.py b/pym/_emerge/Package.py index 0eba4b65..963bfd9f 100644 --- a/pym/_emerge/Package.py +++ b/pym/_emerge/Package.py @@ -218,6 +218,19 @@ class Package(Task): for flag in flags: if not flag in self.all and \ self._iuse_implicit_regex.match(flag) is None: + return False + return True + + def get_missing_iuse(self, flags): + """ + @returns: A list of flags missing from IUSE. + """ + if isinstance(flags, basestring): + flags = [flags] + missing_iuse = [] + for flag in flags: + if not flag in self.all and \ + self._iuse_implicit_regex.match(flag) is None: missing_iuse.append(flag) return missing_iuse |