Skip to content

Commit 6da8b29

Browse files
committed
tools: Support default_lib and c_lib
For backwards compatibility reasons, since the latest Mbed OS tools must be able to build any previous online-compiler-supported version of Mbed OS, allow targets to use `default_lib` or `c_lib`. This should enable the tools to work with Mbed OS 5 style targets.json.
1 parent 8be07a4 commit 6da8b29

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

tools/toolchains/mbed_toolchain.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1097,11 +1097,7 @@ def check_c_lib_supported(self, target, toolchain):
10971097
target.c_lib is modified to have the lowercased string of its original string.
10981098
This is done to be case insensitive when validating.
10991099
"""
1100-
if hasattr(target, "default_lib"):
1101-
raise NotSupportedException(
1102-
"target.default_lib is no longer supported, please use target.c_lib for C library selection."
1103-
)
1104-
if hasattr(target, "c_lib"):
1100+
if hasattr(target, "default_lib") or hasattr(target, "c_lib"):
11051101
target.c_lib = target.c_lib.lower()
11061102
if (
11071103
hasattr(target, "supported_c_libs") == False

0 commit comments

Comments
 (0)