aboutsummaryrefslogtreecommitdiffstats
path: root/share/qbs/modules/cpp/sdcc.js
diff options
context:
space:
mode:
authorDenis Shienkov <denis.shienkov@gmail.com>2021-03-31 10:34:19 +0300
committerDenis Shienkov <denis.shienkov@gmail.com>2021-04-01 16:16:31 +0000
commite0266ffc85058d371e18b0ae8ea49585697ceb59 (patch)
tree2b86c248104951d3b36f4061783899167c8152c3 /share/qbs/modules/cpp/sdcc.js
parentfd1a0ce5b0bd23bb2121e896c1c2732c3d41884a (diff)
Share cpp::linkerMapSuffix property
It makes sense to add the cpp.linkerMapSuffix property to the base CppModule due the following reasons: 1. It is possible that the user wants to change the extension for the generated map files, which makes working with Qbs more flexible. 2. It will be easier to write an autotests that check the generation of the map files for a bare metal platforms, where object files can have various extensions such as ".map", ".m51", ".m66", and so forth. Change-Id: I1e5e3b39bf84fddfe8c06f2db9d3936c6a3ff027 Reviewed-by: Ivan Komissarov <ABBAPOH@gmail.com> Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Diffstat (limited to 'share/qbs/modules/cpp/sdcc.js')
-rw-r--r--share/qbs/modules/cpp/sdcc.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/share/qbs/modules/cpp/sdcc.js b/share/qbs/modules/cpp/sdcc.js
index 71ed22ffa..a47063401 100644
--- a/share/qbs/modules/cpp/sdcc.js
+++ b/share/qbs/modules/cpp/sdcc.js
@@ -303,7 +303,7 @@ function applicationLinkerOutputArtifacts(product) {
fileTags: ["mem_map"],
filePath: FileInfo.joinPaths(
product.destinationDirectory,
- product.targetName + ".map")
+ product.targetName + product.cpp.linkerMapSuffix)
};
return [app, lk_cmd, mem_summary, mem_map]
}
@@ -651,7 +651,7 @@ function prepareLinker(project, product, inputs, outputs, input, output) {
cmd = new JavaScriptCommand();
cmd.mapFilePath = FileInfo.joinPaths(
FileInfo.path(target.filePath),
- FileInfo.completeBaseName(target.fileName) + ".map");
+ FileInfo.completeBaseName(target.fileName) + product.cpp.linkerMapSuffix);
cmd.silent = true;
cmd.sourceCode = function() { File.remove(mapFilePath); };
cmds.push(cmd);