Project's "lib_compat_mode" has higher priority than "library.json"

This commit is contained in:
Ivan Kravets
2021-01-23 15:54:52 +02:00
parent ef6e70a38b
commit 484567f242

View File

@ -773,6 +773,11 @@ class PlatformIOLibBuilder(LibBuilderBase):
@property
def lib_compat_mode(self):
missing = object()
mode = self.env.GetProjectConfig().getraw(
"env:" + self.env["PIOENV"], "lib_compat_mode", missing
)
if mode == missing:
mode = self._manifest.get("build", {}).get(
"libCompatMode",
)