summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDenis Shienkov <denis.shienkov@gmail.com>2019-10-09 22:20:56 +0300
committerDenis Shienkov <denis.shienkov@gmail.com>2019-10-10 14:01:56 +0000
commit39ddab6b69fb3bbd14c5aa019e31271c65e6f16c (patch)
treea220396e7001cf7e3043459ba376502e8f56eea4
parent905ee49fabe197bfe4537c1f10df9d7c48f731c2 (diff)
baremetal: Fix merging issues from 1.14 to master
Change-Id: Id859d95ddfb776ec534ba0e46d989bb2ba30770a Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
-rw-r--r--share/qbs/modules/cpp/keil.js17
-rw-r--r--share/qbs/modules/cpp/keil.qbs16
-rw-r--r--share/qbs/modules/cpp/sdcc.js11
-rw-r--r--share/qbs/modules/cpp/sdcc.qbs11
4 files changed, 9 insertions, 46 deletions
diff --git a/share/qbs/modules/cpp/keil.js b/share/qbs/modules/cpp/keil.js
index ceee3f0d2..4e40a3e64 100644
--- a/share/qbs/modules/cpp/keil.js
+++ b/share/qbs/modules/cpp/keil.js
@@ -37,6 +37,7 @@ var PathTools = require("qbs.PathTools");
var Process = require("qbs.Process");
var TemporaryDir = require("qbs.TemporaryDir");
var TextFile = require("qbs.TextFile");
+var Utilities = require("qbs.Utilities");
function compilerName(qbs) {
switch (qbs.architecture) {
@@ -346,16 +347,7 @@ function applicationLinkerOutputArtifacts(product) {
product.targetName
+ (product.cpp.architecture === "mcs51" ? ".m51" : ".map"))
};
- var artifacts = [app, mem_map];
- if (product.cpp.generateLinkerMapFile) {
- artifacts.push({
- fileTags: ["map_file"],
- filePath: FileInfo.joinPaths(
- product.destinationDirectory,
- product.targetName + ".map")
- });
- }
- return artifacts;
+ return [app, mem_map];
}
function staticLibraryLinkerOutputArtifacts(product) {
@@ -660,9 +652,6 @@ function linkerFlags(project, product, input, outputs) {
// Output.
args.push("--output", outputs.application[0].filePath);
- if (product.cpp.generateMapFile)
- args.push("--list", outputs.mem_map[0].filePath);
-
// Library paths.
var libraryPaths = product.cpp.libraryPaths;
if (libraryPaths)
@@ -679,7 +668,7 @@ function linkerFlags(project, product, input, outputs) {
// Map file generation flag.
if (product.cpp.generateLinkerMapFile)
- args.push("--list", outputs.map_file[0].filePath);
+ args.push("--list", outputs.mem_map[0].filePath);
// Entry point flag.
if (product.cpp.entryPoint)
diff --git a/share/qbs/modules/cpp/keil.qbs b/share/qbs/modules/cpp/keil.qbs
index 1a1792118..aca00eb99 100644
--- a/share/qbs/modules/cpp/keil.qbs
+++ b/share/qbs/modules/cpp/keil.qbs
@@ -103,14 +103,7 @@ CppModule {
}
FileTagger {
- condition: qbs.architecture === "mcs51";
- patterns: ["*.a51", "*.A51"]
- fileTags: ["asm"]
- }
-
- FileTagger {
- condition: qbs.architecture === "arm";
- patterns: ["*.s", ".asm"]
+ patterns: ["*.s", "*.a51", ".asm"]
fileTags: ["asm"]
}
@@ -127,12 +120,7 @@ CppModule {
id: applicationLinker
multiplex: true
inputs: ["obj", "linkerscript"]
- outputFileTags: {
- var tags = ["application", "mem_map"];
- if (product.moduleProperty("cpp", "generateLinkerMapFile"))
- tags.push("map_file");
- return tags;
- }
+ outputFileTags: ["application", "mem_map"]
outputArtifacts: KEIL.applicationLinkerOutputArtifacts(product)
prepare: KEIL.prepareLinker.apply(KEIL, arguments)
}
diff --git a/share/qbs/modules/cpp/sdcc.js b/share/qbs/modules/cpp/sdcc.js
index 0d656ef17..02b40bd47 100644
--- a/share/qbs/modules/cpp/sdcc.js
+++ b/share/qbs/modules/cpp/sdcc.js
@@ -277,16 +277,7 @@ function applicationLinkerOutputArtifacts(product) {
product.destinationDirectory,
product.targetName + ".map")
};
- var artifacts = [app, lk_cmd, mem_summary, mem_map];
- if (product.cpp.generateLinkerMapFile) {
- artifacts.push({
- fileTags: ["map_file"],
- filePath: FileInfo.joinPaths(
- product.destinationDirectory,
- product.targetName + ".map")
- });
- }
- return artifacts;
+ return [app, lk_cmd, mem_summary, mem_map]
}
function staticLibraryLinkerOutputArtifacts(product) {
diff --git a/share/qbs/modules/cpp/sdcc.qbs b/share/qbs/modules/cpp/sdcc.qbs
index e4a040439..bf44b6f8e 100644
--- a/share/qbs/modules/cpp/sdcc.qbs
+++ b/share/qbs/modules/cpp/sdcc.qbs
@@ -101,7 +101,7 @@ CppModule {
inputs: ["asm"]
outputFileTags: ["obj", "asm_adb", "asm_lst", "asm_src", "asm_sym", "rst_data"]
outputArtifacts: SDCC.compilerOutputArtifacts(input)
- prepare: SDCC.prepareAssembler.apply(SDCC, arguments);
+ prepare: SDCC.prepareAssembler.apply(SDCC, arguments)
}
FileTagger {
@@ -130,14 +130,9 @@ CppModule {
multiplex: true
inputs: ["obj", "linkerscript"]
inputsFromDependencies: ["staticlibrary"]
- outputFileTags: {
- var tags = ["application", "lk_cmd", "mem_summary", "mem_map"];
- if (product.moduleProperty("cpp", "generateLinkerMapFile"))
- tags.push("map_file");
- return tags;
- }
+ outputFileTags: ["application", "lk_cmd", "mem_summary", "mem_map"]
outputArtifacts: SDCC.applicationLinkerOutputArtifacts(product)
- prepare:SDCC.prepareLinker.apply(SDCC, arguments)
+ prepare: SDCC.prepareLinker.apply(SDCC, arguments)
}
Rule {