From aec975a3f95f905b2d63ea1500ace28eddea7b9e Mon Sep 17 00:00:00 2001 From: Denis Shienkov Date: Thu, 26 Sep 2019 18:05:21 +0300 Subject: baremetal: Fix assembler command for SDCC compiler We need to use the assembler command in the followiong format: Usage: [-Options] outfile file1 [file2 file3 ...] Besides, we have added an additional assembler option '-l' to explicitly generate of a listing file; without of this option the linking fails. Change-Id: I0240b354f44edac94e3e4305fe6b1a4c34ca4bf9 Reviewed-by: Richard Weickelt Reviewed-by: Christian Kandeler --- share/qbs/modules/cpp/sdcc.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/share/qbs/modules/cpp/sdcc.js b/share/qbs/modules/cpp/sdcc.js index 2f148d2c2..9e7c8097e 100644 --- a/share/qbs/modules/cpp/sdcc.js +++ b/share/qbs/modules/cpp/sdcc.js @@ -252,8 +252,6 @@ function assemblerFlags(project, product, input, output, explicitlyDependsOn) { var tag = ModUtils.fileTagForTargetLanguage(input.fileTags.concat(output.fileTags)); var args = []; - args.push(input.filePath); - args.push("-o", output.filePath); var allIncludePaths = []; var systemIncludePaths = input.cpp.systemIncludePaths; @@ -267,6 +265,10 @@ function assemblerFlags(project, product, input, output, explicitlyDependsOn) { args = args.concat(ModUtils.moduleProperty(input, "platformFlags", tag), ModUtils.moduleProperty(input, "flags", tag), ModUtils.moduleProperty(input, "driverFlags", tag)); + + args.push("-ol"); + args.push(output.filePath); + args.push(input.filePath); return args; } -- cgit v1.2.3