aboutsummaryrefslogtreecommitdiffstats
path: root/share/qbs/modules/cpp/msvc.js
diff options
context:
space:
mode:
authorJoerg Bornemann <joerg.bornemann@digia.com>2013-06-28 14:53:26 +0200
committerChristian Kandeler <christian.kandeler@digia.com>2013-07-02 14:56:36 +0200
commit60cac7544407653b16ecffa2a8d1ae6afe45a671 (patch)
tree88b9f1dfe101e9ff5258fe7697c7de522fea7305 /share/qbs/modules/cpp/msvc.js
parent79d2335c7741b33a231096f73938c85e5187c3ee (diff)
introduce cpp.compilerWrapper
Task-number: QBS-312 Change-Id: I516443a16d2d485f31bcfc1d646e9b38044a47b6 Reviewed-by: Christian Kandeler <christian.kandeler@digia.com>
Diffstat (limited to 'share/qbs/modules/cpp/msvc.js')
-rw-r--r--share/qbs/modules/cpp/msvc.js9
1 files changed, 8 insertions, 1 deletions
diff --git a/share/qbs/modules/cpp/msvc.js b/share/qbs/modules/cpp/msvc.js
index 9e2b69a0e..d2af108af 100644
--- a/share/qbs/modules/cpp/msvc.js
+++ b/share/qbs/modules/cpp/msvc.js
@@ -92,7 +92,14 @@ function prepareCompiler(product, input, outputs, platformDefines, defines, incl
args = args.concat(cFlags);
}
- var cmd = new Command(ModUtils.moduleProperty(product, "compilerPath"), args)
+ var compilerPath = ModUtils.moduleProperty(product, "compilerPath");
+ var wrapperArgs = ModUtils.moduleProperty(product, "compilerWrapper");
+ if (wrapperArgs && wrapperArgs.length > 0) {
+ args.unshift(compilerPath);
+ compilerPath = wrapperArgs.shift();
+ args = wrapperArgs.concat(args);
+ }
+ var cmd = new Command(compilerPath, args)
cmd.description = (pchOutput ? 'pre' : '') + 'compiling ' + FileInfo.fileName(input.fileName)
cmd.highlight = "compiler";
cmd.workingDirectory = FileInfo.path(objOutput.fileName)