summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/bb/parse
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2012-03-03 09:45:58 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2012-03-15 22:56:16 +0000
commitd3d9a37aa7addac066762f624ec857d34c57343b (patch)
tree7869778847e8e4649366d313dc0623e4ebe0101e /bitbake/lib/bb/parse
parentb1256965bb0d5e97862b5bcddc5864a491794741 (diff)
downloadast2050-yocto-poky-d3d9a37aa7addac066762f624ec857d34c57343b.zip
ast2050-yocto-poky-d3d9a37aa7addac066762f624ec857d34c57343b.tar.gz
parse/ast: Expand inherit statements before splitting them
This means that statements that expand to more then one entry such as: CLASSES = "a b" inherit ${CLASSES} work correctly instead of trying to inherit a class called "a b". (Bitbake rev: 2568e9ace6e6f483e1bf2a9ef2f4d8318d6c85b7) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/bb/parse')
-rw-r--r--bitbake/lib/bb/parse/ast.py4
-rw-r--r--bitbake/lib/bb/parse/parse_py/BBHandler.py2
2 files changed, 3 insertions, 3 deletions
diff --git a/bitbake/lib/bb/parse/ast.py b/bitbake/lib/bb/parse/ast.py
index 7cef3d0..eae840f 100644
--- a/bitbake/lib/bb/parse/ast.py
+++ b/bitbake/lib/bb/parse/ast.py
@@ -304,7 +304,7 @@ def handleBBHandlers(statements, filename, lineno, m):
def handleInherit(statements, filename, lineno, m):
classes = m.group(1)
- statements.append(InheritNode(filename, lineno, classes.split()))
+ statements.append(InheritNode(filename, lineno, classes))
def finalize(fn, d, variant = None):
all_handlers = {}
@@ -452,7 +452,7 @@ def multi_finalize(fn, d):
d.setVar("BBEXTENDVARIANT", variantmap[name])
else:
d.setVar("PN", "%s-%s" % (pn, name))
- bb.parse.BBHandler.inherit([extendedmap[name]], fn, 0, d)
+ bb.parse.BBHandler.inherit(extendedmap[name], fn, 0, d)
safe_d.setVar("BBCLASSEXTEND", extended)
_create_variants(datastores, extendedmap.keys(), extendfunc)
diff --git a/bitbake/lib/bb/parse/parse_py/BBHandler.py b/bitbake/lib/bb/parse/parse_py/BBHandler.py
index 125f458..815bce1 100644
--- a/bitbake/lib/bb/parse/parse_py/BBHandler.py
+++ b/bitbake/lib/bb/parse/parse_py/BBHandler.py
@@ -70,8 +70,8 @@ def supports(fn, d):
def inherit(files, fn, lineno, d):
__inherit_cache = data.getVar('__inherit_cache', d) or []
+ files = d.expand(files).split()
for file in files:
- file = data.expand(file, d)
if not os.path.isabs(file) and not file.endswith(".bbclass"):
file = os.path.join('classes', '%s.bbclass' % file)
OpenPOWER on IntegriCloud