Skip to content

Commit ded7d39

Browse files
committed
uvision - microlib fix - commands to use -D__MICROLIB
Exporters use --library_type=microlib. This will be unified soon, as currently the templates does not support ASM macros.
1 parent 5018270 commit ded7d39

File tree

1 file changed

+8
-6
lines changed
  • workspace_tools/toolchains

1 file changed

+8
-6
lines changed

workspace_tools/toolchains/arm.py

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -163,12 +163,14 @@ class ARM_MICRO(ARM):
163163
def __init__(self, target, options=None, notify=None, macros=None, silent=False, extra_verbose=False):
164164
ARM.__init__(self, target, options, notify, macros, silent, extra_verbose=extra_verbose)
165165

166-
# Compiler
167-
self.flags['asm'] += ["-D__MICROLIB"]
168-
self.flags['c'] += ["--library_type=microlib", "-D__MICROLIB"]
169-
self.flags['cxx'] += ["--library_type=microlib", "-D__MICROLIB"]
170-
171-
# Linker
166+
# add microlib to the command line flags
167+
self.asm += ["-D__MICROLIB"]
168+
self.cc += ["--library_type=microlib", "-D__MICROLIB"]
169+
self.cppc += ["--library_type=microlib", "-D__MICROLIB"]
170+
171+
# the exporter uses --library_type flag to set microlib
172+
self.flags['c'] += ["--library_type=microlib"]
173+
self.flags['cxx'] += ["--library_type=microlib"]
172174
self.flags['ld'].append("--library_type=microlib")
173175

174176
# We had to patch microlib to add C++ support

0 commit comments

Comments
 (0)