diff options
Diffstat (limited to 'bitbake/lib/bb/parse/parse_py/BBHandler.py')
-rw-r--r-- | bitbake/lib/bb/parse/parse_py/BBHandler.py | 32 |
1 files changed, 20 insertions, 12 deletions
diff --git a/bitbake/lib/bb/parse/parse_py/BBHandler.py b/bitbake/lib/bb/parse/parse_py/BBHandler.py index 915db214f5..86fa18ebd2 100644 --- a/bitbake/lib/bb/parse/parse_py/BBHandler.py +++ b/bitbake/lib/bb/parse/parse_py/BBHandler.py | |||
@@ -94,7 +94,7 @@ def finalise(fn, d): | |||
94 | for f in anonfuncs: | 94 | for f in anonfuncs: |
95 | code = code + " %s(d)\n" % f | 95 | code = code + " %s(d)\n" % f |
96 | data.setVar("__anonfunc", code, d) | 96 | data.setVar("__anonfunc", code, d) |
97 | build.exec_func_python("__anonfunc", d) | 97 | build.exec_func("__anonfunc", d) |
98 | data.delVar('T', d) | 98 | data.delVar('T', d) |
99 | if t: | 99 | if t: |
100 | data.setVar('T', t, d) | 100 | data.setVar('T', t, d) |
@@ -114,7 +114,7 @@ def finalise(fn, d): | |||
114 | tasklist = data.getVar('__BBTASKS', d) or [] | 114 | tasklist = data.getVar('__BBTASKS', d) or [] |
115 | bb.build.add_tasks(tasklist, d) | 115 | bb.build.add_tasks(tasklist, d) |
116 | 116 | ||
117 | bb.event.fire(bb.event.RecipeParsed(fn, d)) | 117 | bb.event.fire(bb.event.RecipeParsed(fn), d) |
118 | 118 | ||
119 | 119 | ||
120 | def handle(fn, d, include = 0): | 120 | def handle(fn, d, include = 0): |
@@ -185,18 +185,26 @@ def handle(fn, d, include = 0): | |||
185 | multi = data.getVar('BBCLASSEXTEND', d, 1) | 185 | multi = data.getVar('BBCLASSEXTEND', d, 1) |
186 | if multi: | 186 | if multi: |
187 | based = bb.data.createCopy(d) | 187 | based = bb.data.createCopy(d) |
188 | else: | ||
189 | based = d | ||
190 | try: | ||
188 | finalise(fn, based) | 191 | finalise(fn, based) |
189 | darray = {"": based} | 192 | except bb.parse.SkipPackage: |
190 | for cls in multi.split(): | 193 | bb.data.setVar("__SKIPPED", True, based) |
191 | pn = data.getVar('PN', d, True) | 194 | darray = {"": based} |
192 | based = bb.data.createCopy(d) | 195 | |
193 | data.setVar('PN', pn + '-' + cls, based) | 196 | for cls in (multi or "").split(): |
194 | inherit([cls], based) | 197 | pn = data.getVar('PN', d, True) |
198 | based = bb.data.createCopy(d) | ||
199 | data.setVar('PN', pn + '-' + cls, based) | ||
200 | inherit([cls], based) | ||
201 | try: | ||
195 | finalise(fn, based) | 202 | finalise(fn, based) |
196 | darray[cls] = based | 203 | except bb.parse.SkipPackage: |
197 | return darray | 204 | bb.data.setVar("__SKIPPED", True, based) |
198 | else: | 205 | darray[cls] = based |
199 | finalise(fn, d) | 206 | return darray |
207 | |||
200 | bbpath.pop(0) | 208 | bbpath.pop(0) |
201 | if oldfile: | 209 | if oldfile: |
202 | bb.data.setVar("FILE", oldfile, d) | 210 | bb.data.setVar("FILE", oldfile, d) |