OLD | NEW |
---|---|
1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 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/chrome_build.gni") | 5 import("//build/config/chrome_build.gni") |
6 import("//build/config/chromecast_build.gni") | 6 import("//build/config/chromecast_build.gni") |
7 import("//build/config/clang/clang.gni") | 7 import("//build/config/clang/clang.gni") |
8 import("//build/config/sanitizers/sanitizers.gni") | 8 import("//build/config/sanitizers/sanitizers.gni") |
9 import("//build/toolchain/toolchain.gni") | 9 import("//build/toolchain/toolchain.gni") |
10 | 10 |
(...skipping 209 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
220 rebase_path("//tools/memory/asan/blacklist_win.txt", | 220 rebase_path("//tools/memory/asan/blacklist_win.txt", |
221 root_build_dir) ] | 221 root_build_dir) ] |
222 } else { | 222 } else { |
223 # TODO(rnk): Remove this as discussed in http://crbug.com/427202. | 223 # TODO(rnk): Remove this as discussed in http://crbug.com/427202. |
224 cflags += | 224 cflags += |
225 [ "-fsanitize-blacklist=" + | 225 [ "-fsanitize-blacklist=" + |
226 rebase_path("//tools/memory/asan/blacklist.txt", root_build_dir) ] | 226 rebase_path("//tools/memory/asan/blacklist.txt", root_build_dir) ] |
227 } | 227 } |
228 | 228 |
229 if (is_win) { | 229 if (is_win) { |
230 assert(current_cpu == "x86", "WinASan is 32-bit only currently") | 230 if (current_cpu == "x64") { |
231 if (is_component_build) { | 231 # Windows 64-bit. |
232 libs = [ | 232 if (is_component_build) { |
233 "clang_rt.asan_dynamic-i386.lib", | 233 libs = [ |
234 "clang_rt.asan_dynamic_runtime_thunk-i386.lib", | 234 "clang_rt.asan_dynamic-x86_64.lib", |
235 ] | 235 "clang_rt.asan_dynamic_runtime_thunk-x86_64.lib", |
236 ] | |
237 } else { | |
238 # TODO(rnk): DLLs in the non-component build should link against | |
chrisha
2016/07/28 15:29:57
TODO(etienneb), given that you're now driving this
etienneb
2016/07/28 16:27:59
Done.
| |
239 # clang_rt.asan_dll_thunk-x86_64.lib instead. | |
240 libs = [ "clang_rt.asan-x86_64.lib" ] | |
241 } | |
236 } else { | 242 } else { |
237 # TODO(rnk): DLLs in the non-component build should link against | 243 assert(current_cpu == "x86", "WinASan unsupported architecture") |
238 # clang_rt.asan_dll_thunk-i386.lib instead. | 244 if (is_component_build) { |
239 libs = [ "clang_rt.asan-i386.lib" ] | 245 libs = [ |
246 "clang_rt.asan_dynamic-i386.lib", | |
247 "clang_rt.asan_dynamic_runtime_thunk-i386.lib", | |
248 ] | |
249 } else { | |
250 # TODO(rnk): DLLs in the non-component build should link against | |
251 # clang_rt.asan_dll_thunk-i386.lib instead. | |
252 libs = [ "clang_rt.asan-i386.lib" ] | |
253 } | |
240 } | 254 } |
241 } | 255 } |
242 } | 256 } |
243 } | 257 } |
244 | 258 |
245 config("cfi_flags") { | 259 config("cfi_flags") { |
246 cflags = [] | 260 cflags = [] |
247 if (is_cfi && !is_nacl) { | 261 if (is_cfi && !is_nacl) { |
248 cfi_blacklist_path = | 262 cfi_blacklist_path = |
249 rebase_path("//tools/cfi/blacklist.txt", root_build_dir) | 263 rebase_path("//tools/cfi/blacklist.txt", root_build_dir) |
(...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
432 # This allows to selectively disable ubsan_vptr, when needed. In particular, | 446 # This allows to selectively disable ubsan_vptr, when needed. In particular, |
433 # if some third_party code is required to be compiled without rtti, which | 447 # if some third_party code is required to be compiled without rtti, which |
434 # is a requirement for ubsan_vptr. | 448 # is a requirement for ubsan_vptr. |
435 config("default_sanitizer_flags_but_ubsan_vptr") { | 449 config("default_sanitizer_flags_but_ubsan_vptr") { |
436 configs = all_sanitizer_configs - [ ":ubsan_vptr_flags" ] | 450 configs = all_sanitizer_configs - [ ":ubsan_vptr_flags" ] |
437 } | 451 } |
438 | 452 |
439 config("default_sanitizer_flags_but_coverage") { | 453 config("default_sanitizer_flags_but_coverage") { |
440 configs = all_sanitizer_configs - [ ":coverage_flags" ] | 454 configs = all_sanitizer_configs - [ ":coverage_flags" ] |
441 } | 455 } |
OLD | NEW |