diff options
author | Joerg Bornemann <joerg.bornemann@digia.com> | 2013-11-27 10:37:41 +0100 |
---|---|---|
committer | Christian Kandeler <christian.kandeler@digia.com> | 2013-11-27 12:17:31 +0100 |
commit | 4b9858ab8ff94e093af26fcbcb6e15eb6bc2275b (patch) | |
tree | 8445e1046877d8570b2088163b754adf26b85082 | |
parent | bd721ffc92ad2b47cacc3cac77fee11e6f3b12f5 (diff) |
fix stdoutFilterFunction for MSVC PCHs
For some weird reason the MSVC compiler outputs the header file to be
precompiled twice. We filter now all occurrences of the input file
name from stdout.
Change-Id: I4d0e60af02cc00e836eea278dbfdaf11f48c3432
Reviewed-by: Christian Kandeler <christian.kandeler@digia.com>
-rw-r--r-- | share/qbs/modules/cpp/msvc.js | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/share/qbs/modules/cpp/msvc.js b/share/qbs/modules/cpp/msvc.js index 01986c16e..9c2aefe19 100644 --- a/share/qbs/modules/cpp/msvc.js +++ b/share/qbs/modules/cpp/msvc.js @@ -111,7 +111,8 @@ function prepareCompiler(product, input, outputs, platformDefines, defines, incl cmd.responseFileUsagePrefix = '@'; // cl.exe outputs the cpp file name. We filter that out. cmd.stdoutFilterFunction = "function(output) {"; - cmd.stdoutFilterFunction += "return output.replace('" + FileInfo.fileName(input.fileName) + "\\r\\n', '');"; + cmd.stdoutFilterFunction += "return output.replace(/" + + FileInfo.fileName(input.fileName) + "\\r\\n/g, '');"; cmd.stdoutFilterFunction += "}"; return cmd; } |