diff options
author | Joshua Lock <josh@linux.intel.com> | 2011-06-30 23:02:50 -0700 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2011-07-01 17:17:35 +0100 |
commit | 6769269bea2983a4036a535b3e679e13126318ed (patch) | |
tree | 94fd52bd7c01ec9158b30cd991f180e06be7c30f /bitbake/lib | |
parent | a8afb3b353486f5396c0dc92eeed2fb74b89eda2 (diff) | |
download | ast2050-yocto-poky-6769269bea2983a4036a535b3e679e13126318ed.zip ast2050-yocto-poky-6769269bea2983a4036a535b3e679e13126318ed.tar.gz |
cooker: add generic method to locate configuration files
Convert _findLayerConf(self) to _findConfigFile(self, configfile) so that
the core functionality of the method can be used elsewhere.
(Bitbake rev: c515b76c3a27d57d5ae8dddf15cc836811b24ee1)
Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib')
-rw-r--r-- | bitbake/lib/bb/cooker.py | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/bitbake/lib/bb/cooker.py b/bitbake/lib/bb/cooker.py index a6f3bef..369444b 100644 --- a/bitbake/lib/bb/cooker.py +++ b/bitbake/lib/bb/cooker.py @@ -646,15 +646,18 @@ class BBCooker: else: shell.start( self ) - def _findLayerConf(self): + def _findConfigFile(self, configfile): path = os.getcwd() while path != "/": - bblayers = os.path.join(path, "conf", "bblayers.conf") - if os.path.exists(bblayers): - return bblayers + confpath = os.path.join(path, "conf", configfile) + if os.path.exists(confpath): + return confpath path, _ = os.path.split(path) + def _findLayerConf(self): + return self._findConfigFile("bblayers.conf") + def parseConfigurationFiles(self, files): data = self.configuration.data bb.parse.init_parser(data) |