1 # Copyright (c) 2014 The WebRTC project authors. All Rights Reserved.
3 # Use of this source code is governed by a BSD-style license
4 # that can be found in the LICENSE file in the root of the source
5 # tree. An additional intellectual property rights grant can be found
6 # in the file PATENTS. All contributing project authors may
7 # be found in the AUTHORS file in the root of the source tree.
9 # This is a similar target to the one in Chromium's base.gyp. It's needed to get
10 # the same sanitizer settings as Chromium uses (i.e. ASan, LSan, TSan...).
14 'target_name': 'sanitizer_options',
15 'type': 'static_library',
16 'toolsets': ['host', 'target'],
18 # Every target is going to depend on sanitizer_options, so allow
19 # this one to depend on itself.
20 'prune_self_dependency': 1,
21 # Do not let 'none' targets depend on this one, they don't need to.
25 '<(DEPTH)/tools/sanitizer_options/sanitizer_options.cc',
30 # Some targets may want to opt-out from ASan, TSan and MSan and link
31 # without the corresponding runtime libraries. We drop the libc++
32 # dependency and omit the compiler flags to avoid bringing instrumented
33 # code to those targets.
35 ['use_custom_libcxx==1', {
37 '<(DEPTH)/third_party/libc++/libc++.gyp:libcxx_proxy',
42 'tsan_suppressions.cc',
50 '-fsanitize-memory-track-origins',
52 'direct_dependent_settings': {
54 '-Wl,-u_sanitizer_options_link_helper',