mirror of
https://git.yoctoproject.org/poky
synced 2026-05-31 12:49:46 +00:00
Search up the directory tree for bblayers.conf
(Bitbake rev: 1c6b31c649474b4c2b63ef9d9311e61de20bc8c2) Signed-off-by: Chris Larson <chris_larson@mentor.com> Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
This commit is contained in:
committed by
Richard Purdie
parent
3238125138
commit
c04cee7ce8
@@ -510,14 +510,23 @@ class BBCooker:
|
|||||||
else:
|
else:
|
||||||
shell.start( self )
|
shell.start( self )
|
||||||
|
|
||||||
|
def _findLayerConf(self):
|
||||||
|
path = os.getcwd()
|
||||||
|
while path != "/":
|
||||||
|
bblayers = os.path.join(path, "conf", "bblayers.conf")
|
||||||
|
if os.path.exists(bblayers):
|
||||||
|
return bblayers
|
||||||
|
|
||||||
|
path, _ = os.path.split(path)
|
||||||
|
|
||||||
def parseConfigurationFiles(self, files):
|
def parseConfigurationFiles(self, files):
|
||||||
try:
|
try:
|
||||||
data = self.configuration.data
|
data = self.configuration.data
|
||||||
for f in files:
|
for f in files:
|
||||||
data = bb.parse.handle(f, data)
|
data = bb.parse.handle(f, data)
|
||||||
|
|
||||||
layerconf = os.path.join(os.getcwd(), "conf", "bblayers.conf")
|
layerconf = self._findLayerConf()
|
||||||
if os.path.exists(layerconf):
|
if layerconf:
|
||||||
bb.msg.debug(2, bb.msg.domain.Parsing, "Found bblayers.conf (%s)" % layerconf)
|
bb.msg.debug(2, bb.msg.domain.Parsing, "Found bblayers.conf (%s)" % layerconf)
|
||||||
data = bb.parse.handle(layerconf, data)
|
data = bb.parse.handle(layerconf, data)
|
||||||
|
|
||||||
@@ -565,6 +574,7 @@ class BBCooker:
|
|||||||
|
|
||||||
bb.event.fire(bb.event.ConfigParsed(), self.configuration.data)
|
bb.event.fire(bb.event.ConfigParsed(), self.configuration.data)
|
||||||
|
|
||||||
|
|
||||||
except IOError, e:
|
except IOError, e:
|
||||||
bb.msg.fatal(bb.msg.domain.Parsing, "Error when parsing %s: %s" % (files, str(e)))
|
bb.msg.fatal(bb.msg.domain.Parsing, "Error when parsing %s: %s" % (files, str(e)))
|
||||||
except bb.parse.ParseError, details:
|
except bb.parse.ParseError, details:
|
||||||
|
|||||||
Reference in New Issue
Block a user