| OLD | NEW |
| 1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. |
| 2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
| 3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
| 4 | 4 |
| 5 import("//build/config/clang/clang.gni") | 5 import("//build/config/clang/clang.gni") |
| 6 import("//build/config/compiler/compiler.gni") | 6 import("//build/config/compiler/compiler.gni") |
| 7 import("//build/config/sanitizers/sanitizers.gni") | 7 import("//build/config/sanitizers/sanitizers.gni") |
| 8 import("//build/config/win/visual_studio_version.gni") | 8 import("//build/config/win/visual_studio_version.gni") |
| 9 import("//build/toolchain/toolchain.gni") | 9 import("//build/toolchain/toolchain.gni") |
| 10 | 10 |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 46 # for precompiled headers where the same source file is compiled in both | 46 # for precompiled headers where the same source file is compiled in both |
| 47 # modes. | 47 # modes. |
| 48 cflags_c = [ "/TC" ] | 48 cflags_c = [ "/TC" ] |
| 49 cflags_cc = [ "/TP" ] | 49 cflags_cc = [ "/TP" ] |
| 50 | 50 |
| 51 cflags += [ | 51 cflags += [ |
| 52 # Tell the compiler to crash on failures. This is undocumented | 52 # Tell the compiler to crash on failures. This is undocumented |
| 53 # and unsupported but very handy. | 53 # and unsupported but very handy. |
| 54 "/d2FastFail", | 54 "/d2FastFail", |
| 55 | 55 |
| 56 # Work around crbug.com/526851, bug in VS 2015 RTM compiler. | |
| 57 "/Zc:sizedDealloc-", | |
| 58 | |
| 59 # Disable thread-safe statics to avoid overhead and because | 56 # Disable thread-safe statics to avoid overhead and because |
| 60 # they are disabled on other platforms. See crbug.com/587210 | 57 # they are disabled on other platforms. See crbug.com/587210 |
| 61 # and -fno-threadsafe-statics. | 58 # and -fno-threadsafe-statics. |
| 62 "/Zc:threadSafeInit-", | 59 "/Zc:threadSafeInit-", |
| 63 ] | 60 ] |
| 64 | 61 |
| 65 # Building with Clang on Windows is a work in progress and very | 62 # Building with Clang on Windows is a work in progress and very |
| 66 # experimental. See crbug.com/82385. | 63 # experimental. See crbug.com/82385. |
| 67 if (is_clang) { | 64 if (is_clang) { |
| 68 cflags += [ "-fmsc-version=1900" ] | 65 cflags += [ "-fmsc-version=1900" ] |
| (...skipping 354 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 423 | 420 |
| 424 # Internal stuff -------------------------------------------------------------- | 421 # Internal stuff -------------------------------------------------------------- |
| 425 | 422 |
| 426 # Config used by the MIDL template to disable warnings. | 423 # Config used by the MIDL template to disable warnings. |
| 427 config("midl_warnings") { | 424 config("midl_warnings") { |
| 428 if (is_clang) { | 425 if (is_clang) { |
| 429 # MIDL generates code like "#endif !_MIDL_USE_GUIDDEF_". | 426 # MIDL generates code like "#endif !_MIDL_USE_GUIDDEF_". |
| 430 cflags = [ "-Wno-extra-tokens" ] | 427 cflags = [ "-Wno-extra-tokens" ] |
| 431 } | 428 } |
| 432 } | 429 } |
| OLD | NEW |