diff options
author | Reid Kleckner <rnk@google.com> | 2016-03-25 09:53:10 -0700 |
---|---|---|
committer | Reid Kleckner <rnk@google.com> | 2016-03-25 16:56:06 +0000 |
commit | 9be8ca7b77549c46f9a51e991d25e1a509664fd5 (patch) | |
tree | 62856046a0cfa08b8297db22b99d32441f0b2316 | |
parent | 92c439fbcf4850b1ea8f90d80074e9150ab94f42 (diff) | |
download | chromium_src-9be8ca7b77549c46f9a51e991d25e1a509664fd5.zip chromium_src-9be8ca7b77549c46f9a51e991d25e1a509664fd5.tar.gz chromium_src-9be8ca7b77549c46f9a51e991d25e1a509664fd5.tar.bz2 |
Add -fms-compatibility-version=19 to the clang-cl self-host
Otherwise, we get errors about char16_t and char32_t during the stage 2
build.
Also, fix a bug where cflags, cxxflags, and ldflags all pointed to the
same list.
R=hans@chromium.org
BUG=597854
Review URL: https://codereview.chromium.org/1832093002 .
Cr-Commit-Position: refs/heads/master@{#383288}
-rwxr-xr-x | tools/clang/scripts/update.py | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/tools/clang/scripts/update.py b/tools/clang/scripts/update.py index 0e2028e..7b6ebcf 100755 --- a/tools/clang/scripts/update.py +++ b/tools/clang/scripts/update.py @@ -437,7 +437,9 @@ def UpdateClang(args): [cxx, '-print-file-name=libstdc++.so.6']).rstrip() os.environ['LD_LIBRARY_PATH'] = os.path.dirname(libstdcpp) - cflags = cxxflags = ldflags = [] + cflags = [] + cxxflags = [] + ldflags = [] base_cmake_args = ['-GNinja', '-DCMAKE_BUILD_TYPE=Release', @@ -476,6 +478,10 @@ def UpdateClang(args): # https://stackoverflow.com/questions/13050827 cc = cc.replace('\\', '/') cxx = cxx.replace('\\', '/') + # If we're using VS 2015, tell the stage 1 compiler to act like it. + if GetVSVersion().ShortName().startswith('2015'): + cflags += ['-fms-compatibility-version=19'] + cxxflags += ['-fms-compatibility-version=19'] else: cc = os.path.join(LLVM_BOOTSTRAP_INSTALL_DIR, 'bin', 'clang') cxx = os.path.join(LLVM_BOOTSTRAP_INSTALL_DIR, 'bin', 'clang++') |