Skip to content

Commit 006b029

Browse files
theotherjimmyadbridge
authored andcommitted
Fix Microlib compatibility for -t ARM
Missing from common flags: * `-D__MICROLIB` * `--library_type=microlib` This patch adds them
1 parent 43f4316 commit 006b029

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

tools/toolchains/arm.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,12 @@ def __init__(self, target, notify=None, macros=None,
6262
if getattr(target, "default_lib", "std") == "small":
6363
if "-DMBED_RTOS_SINGLE_THREAD" not in self.flags['common']:
6464
self.flags['common'].append("-DMBED_RTOS_SINGLE_THREAD")
65+
if "-D__MICROLIB" not in self.flags['common']:
66+
self.flags['common'].append("-D__MICROLIB")
6567
if "--library_type=microlib" not in self.flags['ld']:
6668
self.flags['ld'].append("--library_type=microlib")
69+
if "--library_type=microlib" not in self.flags['common']:
70+
self.flags['common'].append("--library_type=microlib")
6771

6872
if target.core == "Cortex-M0+":
6973
cpu = "Cortex-M0"

0 commit comments

Comments
 (0)