layerindex/utils.py: Add to baseconfig=True for bb.parse.handle()

Bitbake's api has been changed via:
afb8478d3 parse: Add support for addpylib conf file directive and BB_GLOBAL_PYMODULES

The conf file won't be parsed without baseconfig=True:
bb.parse.ParseError: ParseError at /path/to/oe-core/meta/conf/layer.conf:132: unparsed line: 'addpylib ${LAYERDIR}/lib oe'

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Tim Orling <tim.orling@konsulko.com>
This commit is contained in:
Robert Yang 2022-12-19 23:26:19 -08:00 committed by Tim Orling
parent 0cc6d8eb1f
commit 5976f9fc68

View File

@ -314,7 +314,10 @@ def is_branch_valid(layerdir, branch):
def parse_conf(conf_file, d):
if hasattr(bb.parse, "handle"):
# Newer BitBake
data = bb.parse.handle(conf_file, d, include=True)
if hasattr(bb.parse.parse_py.ConfHandler, "__addpylib_regexp__"):
data = bb.parse.handle(conf_file, d, include=True, baseconfig=True)
else:
data = bb.parse.handle(conf_file, d, include=True)
else:
# Older BitBake (1.18 and below)
data = bb.cooker._parse(conf_file, d)