aboutsummaryrefslogtreecommitdiffstats
path: root/share/qbs/imports/qbs/Probes
diff options
context:
space:
mode:
authorDenis Shienkov <denis.shienkov@gmail.com>2019-08-16 16:41:32 +0300
committerDenis Shienkov <denis.shienkov@gmail.com>2019-08-19 15:21:37 +0000
commit17f7e6a79e17fe19e0bf5c6f9189ca513406740d (patch)
tree68deaf1544942ea6b30c4d3110e17bdedcb2437e /share/qbs/imports/qbs/Probes
parent3865c5d052949f8ec6cc26545933edb6e17ceb00 (diff)
baremetal: Improve JS code in SDCC module a bit
* Move an architecture-specific code to a functions in the sdcc.js file. * Remove the redundant copy-paste code. * Align order for assembler, compiler, linker and archiver flags to the unified form, like: <inputs> <outputs> <defines> <includes> <flags> * Add some comments. * Fix handling of cLanguageVersion property. Change-Id: Id787b4455847ac5dde4a926d850e7c076edc34d2 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Diffstat (limited to 'share/qbs/imports/qbs/Probes')
-rw-r--r--share/qbs/imports/qbs/Probes/SdccProbe.qbs10
1 files changed, 5 insertions, 5 deletions
diff --git a/share/qbs/imports/qbs/Probes/SdccProbe.qbs b/share/qbs/imports/qbs/Probes/SdccProbe.qbs
index b5f7d384e..3595bb158 100644
--- a/share/qbs/imports/qbs/Probes/SdccProbe.qbs
+++ b/share/qbs/imports/qbs/Probes/SdccProbe.qbs
@@ -64,10 +64,10 @@ PathProbe {
var defaultPaths = SDCC.dumpDefaultPaths(compilerFilePath, architecture);
includePaths = defaultPaths.includePaths;
- versionMajor = parseInt(macros["__SDCC_VERSION_MAJOR"], 10);
- versionMinor = parseInt(macros["__SDCC_VERSION_MINOR"], 10);
- versionPatch = parseInt(macros["__SDCC_VERSION_PATCH"], 10);
-
- found = macros["SDCC"];
+ var version = SDCC.guessVersion(macros);
+ versionMajor = version.major;
+ versionMinor = version.minor;
+ versionPatch = version.patch;
+ found = version.found;
}
}