mirror of
https://github.com/platformio/platformio-core.git
synced 2025-07-31 18:44:27 +02:00
Project's "lib_compat_mode" has higher priority than "library.json"
This commit is contained in:
@@ -773,9 +773,14 @@ class PlatformIOLibBuilder(LibBuilderBase):
|
|||||||
|
|
||||||
@property
|
@property
|
||||||
def lib_compat_mode(self):
|
def lib_compat_mode(self):
|
||||||
mode = self._manifest.get("build", {}).get(
|
missing = object()
|
||||||
"libCompatMode",
|
mode = self.env.GetProjectConfig().getraw(
|
||||||
|
"env:" + self.env["PIOENV"], "lib_compat_mode", missing
|
||||||
)
|
)
|
||||||
|
if mode == missing:
|
||||||
|
mode = self._manifest.get("build", {}).get(
|
||||||
|
"libCompatMode",
|
||||||
|
)
|
||||||
if not mode and self._manifest.get("platforms"):
|
if not mode and self._manifest.get("platforms"):
|
||||||
mode = "strict"
|
mode = "strict"
|
||||||
# pylint: disable=no-member
|
# pylint: disable=no-member
|
||||||
|
Reference in New Issue
Block a user