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/compiler/compiler.gni") | 5 import("//build/config/compiler/compiler.gni") |
6 import("//build/config/sanitizers/sanitizers.gni") | 6 import("//build/config/sanitizers/sanitizers.gni") |
7 import("//build/config/win/visual_studio_version.gni") | 7 import("//build/config/win/visual_studio_version.gni") |
8 | 8 |
9 assert(is_win) | 9 assert(is_win) |
10 | 10 |
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
96 | 96 |
97 # Clang runtime libraries, such as the sanitizer runtimes, live here. | 97 # Clang runtime libraries, such as the sanitizer runtimes, live here. |
98 lib_dirs = [ "//third_party/llvm-build/Release+Asserts/lib/clang/3.9.0/lib/w
indows" ] | 98 lib_dirs = [ "//third_party/llvm-build/Release+Asserts/lib/clang/3.9.0/lib/w
indows" ] |
99 } | 99 } |
100 | 100 |
101 if (is_syzyasan) { | 101 if (is_syzyasan) { |
102 # SyzyAsan needs /PROFILE turned on to produce appropriate pdbs. | 102 # SyzyAsan needs /PROFILE turned on to produce appropriate pdbs. |
103 assert(!is_win_fastlink, "/PROFILE and /DEBUG:FASTLINK are incompatible") | 103 assert(!is_win_fastlink, "/PROFILE and /DEBUG:FASTLINK are incompatible") |
104 ldflags = [ "/PROFILE" ] | 104 ldflags = [ "/PROFILE" ] |
105 } | 105 } |
106 | |
107 # arflags apply only to static_libraries. The normal linker configs are only | |
108 # set for executable and shared library targets so arflags must be set | |
109 # elsewhere. Since this is relatively contained, we just apply them in this | |
110 # more general config and they will only have an effect on static libraries. | |
111 arflags = [ | |
112 # "No public symbols found; archive member will be inaccessible." This | |
113 # means that one or more object files in the library can never be | |
114 # pulled in to targets that link to this library. It's just a warning that | |
115 # the source file is a no-op. | |
116 "/ignore:4221", | |
117 ] | |
118 } | 106 } |
119 | 107 |
120 config("vs_code_analysis") { | 108 config("vs_code_analysis") { |
121 if (use_vs_code_analysis) { | 109 if (use_vs_code_analysis) { |
122 # When use_vs_code_analysis is specified add the /analyze switch to enable | 110 # When use_vs_code_analysis is specified add the /analyze switch to enable |
123 # static analysis. Specifying /analyze:WX- says that /analyze warnings | 111 # static analysis. Specifying /analyze:WX- says that /analyze warnings |
124 # should not be treated as errors. | 112 # should not be treated as errors. |
125 cflags = [ "/analyze:WX-" ] | 113 cflags = [ "/analyze:WX-" ] |
126 | 114 |
127 # Also, disable various noisy warnings that have low value. | 115 # Also, disable various noisy warnings that have low value. |
(...skipping 271 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
399 | 387 |
400 # Internal stuff -------------------------------------------------------------- | 388 # Internal stuff -------------------------------------------------------------- |
401 | 389 |
402 # Config used by the MIDL template to disable warnings. | 390 # Config used by the MIDL template to disable warnings. |
403 config("midl_warnings") { | 391 config("midl_warnings") { |
404 if (is_clang) { | 392 if (is_clang) { |
405 # MIDL generates code like "#endif !_MIDL_USE_GUIDDEF_". | 393 # MIDL generates code like "#endif !_MIDL_USE_GUIDDEF_". |
406 cflags = [ "-Wno-extra-tokens" ] | 394 cflags = [ "-Wno-extra-tokens" ] |
407 } | 395 } |
408 } | 396 } |
OLD | NEW |