Skip to content

Commit 453a1d7

Browse files
committed
ARM: ARMC6: Specify CPU for ARM scatter file preprocessor
Fixes #5796
1 parent af9e073 commit 453a1d7

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

tools/toolchains/arm.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,8 @@ def __init__(self, target, notify=None, macros=None,
8181
self.ar = join(ARM_BIN, "armar")
8282
self.elf2bin = join(ARM_BIN, "fromelf")
8383

84+
self.SHEBANG += " --cpu=%s" % target.core.lower()
85+
8486
def parse_dependencies(self, dep_path):
8587
dependencies = []
8688
for line in open(dep_path).readlines():
@@ -356,6 +358,7 @@ def __init__(self, target, *args, **kwargs):
356358
self.ar = [join(TOOLCHAIN_PATHS["ARMC6"], "armar")]
357359
self.elf2bin = join(TOOLCHAIN_PATHS["ARMC6"], "fromelf")
358360

361+
self.SHEBANG += " -mcpu=%s" % target.core.lower()
359362

360363
def parse_dependencies(self, dep_path):
361364
return mbedToolchain.parse_dependencies(self, dep_path)

0 commit comments

Comments
 (0)