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 # Contains the dependencies needed for asan to link into executables and | 5 # Contains the dependencies needed for asan to link into executables and |
6 # shared_libraries. Unconditionally depend upon this target as it is empty if | 6 # shared_libraries. Unconditionally depend upon this target as it is empty if |
7 # |is_asan| is false. | 7 # |is_asan| is false. |
8 group("deps") { | 8 group("deps") { |
9 if (is_asan) { | 9 if (is_asan) { |
10 public_configs = [ ":sanitizer_options_link_helper" ] | 10 public_configs = [ ":sanitizer_options_link_helper" ] |
11 deps = [ | 11 deps = [ |
12 ":options_sources", | 12 ":options_sources", |
13 ] | 13 ] |
14 } | 14 } |
15 } | 15 } |
16 | 16 |
17 config("sanitizer_options_link_helper") { | 17 config("sanitizer_options_link_helper") { |
18 ldflags = [ | 18 ldflags = [ |
19 "-Wl,-u_sanitizer_options_link_helper", | 19 "-Wl,-u_sanitizer_options_link_helper", |
20 "-fsanitize=address", | 20 "-fsanitize=address", |
21 ] | 21 ] |
22 } | 22 } |
23 | 23 |
24 source_set("options_sources") { | 24 source_set("options_sources") { |
25 visibility = [ ":deps" ] | 25 visibility = [ |
| 26 ":deps", |
| 27 "//:gn_visibility", |
| 28 ] |
26 sources = [ | 29 sources = [ |
27 "//build/sanitizers/sanitizer_options.cc", | 30 "//build/sanitizers/sanitizer_options.cc", |
28 ] | 31 ] |
29 | 32 |
30 if (is_tsan) { | 33 if (is_tsan) { |
31 sources += [ "//build/sanitizers/tsan_suppressions.cc" ] | 34 sources += [ "//build/sanitizers/tsan_suppressions.cc" ] |
32 } | 35 } |
33 } | 36 } |
OLD | NEW |