diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/lib/Bcfg2/Server/Plugins/Packages/Portage.py | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/src/lib/Bcfg2/Server/Plugins/Packages/Portage.py b/src/lib/Bcfg2/Server/Plugins/Packages/Portage.py index efa76031e..5d96c8ad8 100644 --- a/src/lib/Bcfg2/Server/Plugins/Packages/Portage.py +++ b/src/lib/Bcfg2/Server/Plugins/Packages/Portage.py @@ -69,8 +69,21 @@ class PortageCollection(Collection): if 'gentoo-use-flags' in self.metadata.Probes: self.portage.settings['USE'] = \ self.metadata.Probes['gentoo-use-flags'] - self.portage.settings.lock() + # add package flags (accept_keywords, use) + if hasattr(self.metadata, 'PkgVars'): + for k in self.metadata.PkgVars['keywords']: + keyword = metadata.PkgVars['keywords'][k] + self.portage.settings._keywords_manager.pkeywordsdict[k] = \ + {k: tuple(keyword)} + + + for u in self.metadata.PkgVars['use']: + use = metadata.PkgVars['use'][u] + self.portage.settings._use_manager._pusedict[u] = \ + {u: tuple(use)} + + self.portage.settings.lock() # calculate deps setconfig = self.portage._sets.load_default_config( |