From 5cc9a328ab4d64c42f3cda714f65e150eca31128 Mon Sep 17 00:00:00 2001 From: Ivan Kravets Date: Fri, 14 Feb 2020 22:57:51 +0200 Subject: [PATCH] Fixed an issue when Library Dependency Finder (LDF) ignores custom "libLDFMode" and "libCompatMode" options in `library.json` --- HISTORY.rst | 1 + platformio/builder/tools/piolib.py | 14 ++++---------- 2 files changed, 5 insertions(+), 10 deletions(-) diff --git a/HISTORY.rst b/HISTORY.rst index 8185432e..c7ef7e11 100644 --- a/HISTORY.rst +++ b/HISTORY.rst @@ -13,6 +13,7 @@ PlatformIO Core 4 * Improved support of PIO Home on card-sized PC (Raspberry Pi, etc.) (`issue #3313 `_) * Froze "marshmallow" dependency to 2.X for Python 2 (`issue #3380 `_) * Fixed "TypeError: unsupported operand type(s)" when system environment variable is used by project configuration parser (`issue #3377 `_) +* Fixed an issue when Library Dependency Finder (LDF) ignores custom "libLDFMode" and "libCompatMode" options in `library.json `__ 4.2.0 (2020-02-12) diff --git a/platformio/builder/tools/piolib.py b/platformio/builder/tools/piolib.py index e20226d1..b55c492e 100644 --- a/platformio/builder/tools/piolib.py +++ b/platformio/builder/tools/piolib.py @@ -727,22 +727,16 @@ class PlatformIOLibBuilder(LibBuilderBase): @property def lib_ldf_mode(self): return self.validate_ldf_mode( - self.env.GetProjectOption( - "lib_ldf_mode", - self._manifest.get("build", {}).get( - "libLDFMode", LibBuilderBase.lib_ldf_mode.fget(self) - ), + self._manifest.get("build", {}).get( + "libLDFMode", LibBuilderBase.lib_ldf_mode.fget(self) ) ) @property def lib_compat_mode(self): return self.validate_compat_mode( - self.env.GetProjectOption( - "lib_compat_mode", - self._manifest.get("build", {}).get( - "libCompatMode", LibBuilderBase.lib_compat_mode.fget(self) - ), + self._manifest.get("build", {}).get( + "libCompatMode", LibBuilderBase.lib_compat_mode.fget(self) ) )