Merge "Check missing uncoditionally loaded missing modules at runtime"

This commit is contained in:
Alexander Smundak
2022-01-14 17:56:27 +00:00
committed by Gerrit Code Review
3 changed files with 50 additions and 26 deletions

View File

@@ -121,7 +121,7 @@ $(call inherit-product, part.mk)
ifdef PRODUCT_NAME
$(call inherit-product, part1.mk)
else # Comment
$(call inherit-product, $(LOCAL_PATH)/part1.mk)
$(call inherit-product, $(LOCAL_PATH)/part.mk)
endif
`,
expected: `load("//build/make/core:product_config.rbc", "rblf")
@@ -132,10 +132,12 @@ def init(g, handle):
cfg = rblf.cfg(handle)
rblf.inherit(handle, "part", _part_init)
if g.get("PRODUCT_NAME") != None:
if not _part1_init:
rblf.mkerror("product.mk", "Cannot find %s" % (":part1.star"))
rblf.inherit(handle, "part1", _part1_init)
else:
# Comment
rblf.inherit(handle, "part1", _part1_init)
rblf.inherit(handle, "part", _part_init)
`,
},
{
@@ -173,6 +175,8 @@ def init(g, handle):
cfg = rblf.cfg(handle)
_part_init(g, handle)
if g.get("PRODUCT_NAME") != None:
if not _part1_init:
rblf.mkerror("product.mk", "Cannot find %s" % (":part1.star"))
_part1_init(g, handle)
else:
if _part1_init != None: