aboutsummaryrefslogtreecommitdiffstats
path: root/share/qbs/modules/cpp/msvc.js
diff options
context:
space:
mode:
authorJoerg Bornemann <joerg.bornemann@digia.com>2013-06-04 09:52:54 +0200
committerJoerg Bornemann <joerg.bornemann@digia.com>2013-06-04 12:28:51 +0200
commit4638fd7e19f75940ad7050d9bbef5a5f4ee1e2a2 (patch)
tree85306e50b67cdd51e1cf9b08c56e4bf096df238b /share/qbs/modules/cpp/msvc.js
parentb9bd24f752df07a0b411aa360c8d049d1e37adec (diff)
MSVC: do not invoke shell to copy files
Otherwise we'd have to quote files with special characters that are interpreted by the shell. Task-number: QBS-298 Change-Id: If0e0bb0224ab696730842aabac4e36e335f14e3c 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.js8
1 files changed, 6 insertions, 2 deletions
diff --git a/share/qbs/modules/cpp/msvc.js b/share/qbs/modules/cpp/msvc.js
index fc4569661..29d49fa2a 100644
--- a/share/qbs/modules/cpp/msvc.js
+++ b/share/qbs/modules/cpp/msvc.js
@@ -194,8 +194,12 @@ function prepareLinker(product, inputs, outputs, libraryPaths, dynamicLibraries,
if (generateManifestFiles) {
var outputNativeFilePath = FileInfo.toWindowsSeparators(primaryOutput.fileName);
- cmd = new Command("cmd.exe", ["/c", "copy", linkerOutputNativeFilePath,
- outputNativeFilePath, ">NUL"]);
+ cmd = new JavaScriptCommand();
+ cmd.src = linkerOutputNativeFilePath;
+ cmd.dst = outputNativeFilePath;
+ cmd.sourceCode = function() {
+ File.copy(src, dst);
+ }
commands.push(cmd);
args = [
'/nologo', '/manifest', manifestFileName,