Move IAR linker flags into the DEFAULT_FLAGS dict

pull/1914/head
Jimmy Brisson 2016-06-09 14:40:57 -05:00 committed by 0xc0170
parent 685f4ed648
commit a4baaf8d5c
1 changed files with 5 additions and 1 deletions

View File

@ -42,7 +42,7 @@ class IAR(mbedToolchain):
'asm': [],
'c': [],
'cxx': ["--c++", "--no_rtti", "--no_exceptions", "--guard_calls"],
'ld': [],
'ld': ["--skip_dynamic_initialization", "--threaded_lib"],
}
def __init__(self, target, options=None, notify=None, macros=None, silent=False, extra_verbose=False):
@ -195,6 +195,10 @@ class IAR(mbedToolchain):
self.default_cmd([self.ar, lib_path, '-f', archive_files])
def link(self, output, objects, libraries, lib_dirs, mem_map):
args = [self.ld, "-o", output, "--config", mem_map] + self.flags['ld']
self.default_cmd(self.hook.get_cmdline_linker(args + objects + libraries))
@hook_tool
def binary(self, resources, elf, bin):
# Build binary command