diff options
author | brettw <brettw@chromium.org> | 2015-08-31 15:17:39 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-08-31 22:18:18 +0000 |
commit | ba7a73dd61db639f42cc6283939f8b44cc4ecc6c (patch) | |
tree | 8a39315021584d7097ff63d478e9a94c045f9adc | |
parent | d1ffb22d3c2864efbad907cd690fef7b31b585b9 (diff) | |
download | chromium_src-ba7a73dd61db639f42cc6283939f8b44cc4ecc6c.zip chromium_src-ba7a73dd61db639f42cc6283939f8b44cc4ecc6c.tar.gz chromium_src-ba7a73dd61db639f42cc6283939f8b44cc4ecc6c.tar.bz2 |
Annotate GN executables and shared_libraries with sanitizer deps.
These are needed to link in asan/lsan/etc. mode. GYP injects these automatically but GN doesn't have automatic dependency injection.
All tests and components (which cover the vast majority of such targets in actual use) are templates which add these dependencies already, so most of the time it never comes up.
Only a few of these changes are actually necessary to link all tests run on the asan bot (which is also what engineers will typically build, since almost nobody will build all in asan mode). But to reduce confusion from linker errors in asan mode, I annotated all executables and shared libraries I could find with the sanitizer dependency.
I moved a config out of a target in yasm, and sorted a fews deps on other targets.
TBR=xhwang@chromium.org (widevine)
TBR=achuith@chromium.org (tools/perf, tools/telemetry)
Review URL: https://codereview.chromium.org/1318343003
Cr-Commit-Position: refs/heads/master@{#346490}
75 files changed, 215 insertions, 18 deletions
diff --git a/ash/BUILD.gn b/ash/BUILD.gn index 2f53cce..50f56ae 100644 --- a/ash/BUILD.gn +++ b/ash/BUILD.gn @@ -384,6 +384,7 @@ executable("ash_shell") { deps = [ ":ash_shell_lib", + "//build/config/sanitizers:deps", "//components/user_manager", ] diff --git a/base/BUILD.gn b/base/BUILD.gn index a4e5a5c..f46a0b1 100644 --- a/base/BUILD.gn +++ b/base/BUILD.gn @@ -1067,6 +1067,7 @@ if (is_ios || is_win || (is_linux && !is_chromeos)) { ] deps = [ ":base", + "//build/config/sanitizers:deps", "//third_party/icu:icuuc", ] } @@ -1077,6 +1078,7 @@ if (is_ios || is_win || (is_linux && !is_chromeos)) { ] deps = [ ":base", + "//build/config/sanitizers:deps", ] } } @@ -1190,6 +1192,9 @@ if (is_win) { "cfgmgr32.lib", "shell32.lib", ] + deps = [ + "//build/config/sanitizers:deps", + ] } } diff --git a/base/android/linker/BUILD.gn b/base/android/linker/BUILD.gn index 9c23a63..b91b7c6 100644 --- a/base/android/linker/BUILD.gn +++ b/base/android/linker/BUILD.gn @@ -22,6 +22,7 @@ shared_library("chromium_android_linker") { # '<(android_ndk_root)/crazy_linker.gyp:crazy_linker' # However, we use our own fork. See bug 384700. deps = [ + "//build/config/sanitizers:deps", "//third_party/android_crazy_linker", ] diff --git a/base/test/BUILD.gn b/base/test/BUILD.gn index a8a8bf2..75a77d2 100644 --- a/base/test/BUILD.gn +++ b/base/test/BUILD.gn @@ -208,6 +208,7 @@ if (is_linux) { ] deps = [ "//base", + "//build/config/sanitizers:deps", ] } } diff --git a/breakpad/BUILD.gn b/breakpad/BUILD.gn index cf66517..035ed5b 100644 --- a/breakpad/BUILD.gn +++ b/breakpad/BUILD.gn @@ -138,6 +138,7 @@ if (current_toolchain == host_toolchain && !is_win) { deps = [ ":stackwalk_common", + "//build/config/sanitizers:deps", ] defines = [ "BPLOG_MINIMUM_SEVERITY=SEVERITY_ERROR" ] @@ -157,6 +158,7 @@ if (current_toolchain == host_toolchain && !is_win) { deps = [ ":stackwalk_common", + "//build/config/sanitizers:deps", ] defines = [ "BPLOG_MINIMUM_SEVERITY=SEVERITY_ERROR" ] @@ -198,6 +200,10 @@ if (current_toolchain == host_toolchain && !is_win) { # There are some warnings in this code. configs -= [ "//build/config/compiler:chromium_code" ] configs += [ "//build/config/compiler:no_chromium_code" ] + + deps = [ + "//build/config/sanitizers:deps", + ] } } @@ -259,6 +265,10 @@ if (current_toolchain == host_toolchain && is_mac) { configs -= [ "//build/config/compiler:optimize" ] cflags += [ "-O0" ] } + + deps = [ + "//build/config/sanitizers:deps", + ] } executable("symupload") { @@ -273,6 +283,10 @@ if (current_toolchain == host_toolchain && is_mac) { configs -= [ "//build/config/compiler:chromium_code" ] configs += [ "//build/config/compiler:no_chromium_code" ] + + deps = [ + "//build/config/sanitizers:deps", + ] } } @@ -326,6 +340,7 @@ if (is_mac) { deps = [ ":utilities", + "//build/config/sanitizers:deps", ] } @@ -383,6 +398,10 @@ if (is_linux) { configs += [ ":tools_config" ] libs = [ "dl" ] + + deps = [ + "//build/config/sanitizers:deps", + ] } } @@ -443,6 +462,10 @@ if (is_linux || is_android) { defines = [ "HAVE_A_OUT_H" ] include_dirs = [ "src" ] + + deps = [ + "//build/config/sanitizers:deps", + ] } } @@ -628,6 +651,7 @@ if (is_linux) { ] deps = [ ":processor_support", + "//build/config/sanitizers:deps", ] include_dirs = [ "src" ] @@ -649,6 +673,7 @@ if (is_linux) { deps = [ ":client", + "//build/config/sanitizers:deps", ] include_dirs = [ "src" ] @@ -668,6 +693,7 @@ if (is_linux) { deps = [ ":client", + "//build/config/sanitizers:deps", ] } @@ -678,6 +704,7 @@ if (is_linux) { deps = [ ":client", + "//build/config/sanitizers:deps", ] include_dirs = [ "src" ] diff --git a/chrome/BUILD.gn b/chrome/BUILD.gn index f306bbef..b412904 100644 --- a/chrome/BUILD.gn +++ b/chrome/BUILD.gn @@ -27,7 +27,9 @@ if (!is_android) { ] defines = [] public_deps = [] - deps = [] + deps = [ + "//build/config/sanitizers:deps", + ] data = [ "$root_out_dir/resources.pak", @@ -201,6 +203,7 @@ shared_library("main_dll") { deps = [ ":browser_dependencies", "//base/allocator", + "//build/config/sanitizers:deps", ] if (is_win) { output_name = "chrome" @@ -302,6 +305,7 @@ if (is_multi_dll_chrome) { ":chrome_child_manifest", ":chrome_dll_version", "//base/allocator", + "//build/config/sanitizers:deps", "//chrome/browser/policy:path_parser", "//content/public/app:child", ] diff --git a/chrome/android/BUILD.gn b/chrome/android/BUILD.gn index 49e3598..99ecb178 100644 --- a/chrome/android/BUILD.gn +++ b/chrome/android/BUILD.gn @@ -247,6 +247,7 @@ shared_library("chrome_shell") { ] deps = [ ":chrome_shell_base", + "//build/config/sanitizers:deps", ] } @@ -627,6 +628,7 @@ jinja_template_resources("chrome_public_template_resources") { # GYP: //chrome/android/chrome_apk.gyp:libchrome_public shared_library("chrome_public") { deps = [ + "//build/config/sanitizers:deps", "//chrome:chrome_android_core", ] gypi_values = exec_script( diff --git a/chrome/chrome_watcher/BUILD.gn b/chrome/chrome_watcher/BUILD.gn index ac00808..e639861 100644 --- a/chrome/chrome_watcher/BUILD.gn +++ b/chrome/chrome_watcher/BUILD.gn @@ -34,6 +34,7 @@ shared_library("chrome_watcher") { ":client", "//chrome/installer/util", "//base", + "//build/config/sanitizers:deps", "//components/browser_watcher", ] ldflags = [ "/DEF:" + rebase_path("chrome_watcher.def", root_build_dir) ] diff --git a/chrome/installer/mini_installer/BUILD.gn b/chrome/installer/mini_installer/BUILD.gn index 4631b69..54aaea0 100644 --- a/chrome/installer/mini_installer/BUILD.gn +++ b/chrome/installer/mini_installer/BUILD.gn @@ -182,6 +182,7 @@ executable("mini_installer") { deps = [ ":archive", ":lib", + "//build/config/sanitizers:deps", "//build/win:default_exe_manifest", "//chrome/installer/setup", ] diff --git a/chrome/installer/setup/BUILD.gn b/chrome/installer/setup/BUILD.gn index bff865f..3f59861c9 100644 --- a/chrome/installer/setup/BUILD.gn +++ b/chrome/installer/setup/BUILD.gn @@ -22,6 +22,7 @@ if (is_win) { deps = [ ":lib", + "//build/config/sanitizers:deps", ] } diff --git a/chrome/installer/test/BUILD.gn b/chrome/installer/test/BUILD.gn index 97c3c66..2f5dfc2 100644 --- a/chrome/installer/test/BUILD.gn +++ b/chrome/installer/test/BUILD.gn @@ -16,6 +16,7 @@ executable("alternate_version_generator") { ":alternate_version_generator_lib", "//base", "//base/test:test_support", + "//build/config/sanitizers:deps", "//chrome/common:constants", "//chrome/installer/util", "//testing/gtest", diff --git a/chrome/test/chromedriver/BUILD.gn b/chrome/test/chromedriver/BUILD.gn index 20a1d82..6ef1817 100644 --- a/chrome/test/chromedriver/BUILD.gn +++ b/chrome/test/chromedriver/BUILD.gn @@ -184,6 +184,7 @@ executable("chromedriver") { deps = [ ":lib", + "//build/config/sanitizers:deps", ] } diff --git a/chrome/tools/convert_dict/BUILD.gn b/chrome/tools/convert_dict/BUILD.gn index 108eb19..e55a144 100644 --- a/chrome/tools/convert_dict/BUILD.gn +++ b/chrome/tools/convert_dict/BUILD.gn @@ -32,6 +32,7 @@ executable("convert_dict") { ":lib", "//base", "//base:i18n", + "//build/config/sanitizers:deps", "//third_party/hunspell", ] } diff --git a/chrome/tools/profile_reset/BUILD.gn b/chrome/tools/profile_reset/BUILD.gn index b1c488f..1cebad1 100644 --- a/chrome/tools/profile_reset/BUILD.gn +++ b/chrome/tools/profile_reset/BUILD.gn @@ -11,6 +11,7 @@ executable("jtl_compiler") { deps = [ ":jtl_compiler_lib", "//base", + "//build/config/sanitizers:deps", "//crypto", ] } diff --git a/chrome/tools/service_discovery_sniffer/BUILD.gn b/chrome/tools/service_discovery_sniffer/BUILD.gn index 91c3bee..8fc3195 100644 --- a/chrome/tools/service_discovery_sniffer/BUILD.gn +++ b/chrome/tools/service_discovery_sniffer/BUILD.gn @@ -15,6 +15,7 @@ executable("service_discovery_sniffer") { "//base", "//base/allocator", "//base/test:test_support", + "//build/config/sanitizers:deps", "//chrome/utility", "//net", ] diff --git a/chrome_elf/BUILD.gn b/chrome_elf/BUILD.gn index 2a15a55..64f5b7b 100644 --- a/chrome_elf/BUILD.gn +++ b/chrome_elf/BUILD.gn @@ -33,6 +33,7 @@ shared_library("chrome_elf") { ":chrome_elf_manifest", ":lib", ":chrome_elf_resources", + "//build/config/sanitizers:deps", ] configs += [ "//build/config/win:windowed" ] configs -= [ "//build/config/win:console" ] @@ -100,6 +101,7 @@ if (is_component_build) { ] deps = [ ":lib", + "//build/config/sanitizers:deps", ] configs += [ "//build/config/win:windowed" ] ldflags = [ "/DEF:" + rebase_path("chrome_redirects.def") ] @@ -122,12 +124,13 @@ source_set("dll_hash") { } executable("dll_hash_main") { - deps = [ - ":dll_hash", - ] sources = [ "dll_hash/dll_hash_main.cc", ] + deps = [ + ":dll_hash", + "//build/config/sanitizers:deps", + ] } static_library("blacklist") { @@ -182,8 +185,9 @@ shared_library("blacklist_test_main_dll") { "blacklist/test/blacklist_test_main_dll.cc", ] deps = [ - "//base", ":blacklist", + "//base", + "//build/config/sanitizers:deps", ] ldflags = [ "/DEF:" + rebase_path("blacklist/test/blacklist_test_main_dll.def", @@ -196,6 +200,9 @@ shared_library("blacklist_test_dll_1") { ] ldflags = [ "/DEF:" + rebase_path("blacklist/test/blacklist_test_dll_1.def", root_build_dir) ] + deps = [ + "//build/config/sanitizers:deps", + ] } shared_library("blacklist_test_dll_2") { @@ -204,10 +211,16 @@ shared_library("blacklist_test_dll_2") { ] ldflags = [ "/DEF:" + rebase_path("blacklist/test/blacklist_test_dll_2.def", root_build_dir) ] + deps = [ + "//build/config/sanitizers:deps", + ] } shared_library("blacklist_test_dll_3") { sources = [ "blacklist/test/blacklist_test_dll_3.cc", ] + deps = [ + "//build/config/sanitizers:deps", + ] } diff --git a/chromecast/BUILD.gn b/chromecast/BUILD.gn index feb33a5..6969244 100644 --- a/chromecast/BUILD.gn +++ b/chromecast/BUILD.gn @@ -66,6 +66,7 @@ executable("cast_shell") { deps = [ ":cast_shell_common", ":cast_shell_media", + "//build/config/sanitizers:deps", "//chromecast/app", "//content/public/app:both", ] diff --git a/chromecast/media/base/BUILD.gn b/chromecast/media/base/BUILD.gn index c5ca903..ba1e593 100644 --- a/chromecast/media/base/BUILD.gn +++ b/chromecast/media/base/BUILD.gn @@ -60,6 +60,7 @@ shared_library("libcast_media_default") { configs += [ "//chromecast:config" ] deps = [ + "//build/config/sanitizers:deps", "//chromecast/media/cma/backend", "//chromecast/public", "//chromecast/public/media", diff --git a/components/nacl/BUILD.gn b/components/nacl/BUILD.gn index 02f0f06..e5a4ad0 100644 --- a/components/nacl/BUILD.gn +++ b/components/nacl/BUILD.gn @@ -188,6 +188,7 @@ if (enable_nacl) { ":nacl_linux", ":nacl_switches", "//base", + "//build/config/sanitizers:deps", "//content/public/common", "//crypto", "//ipc", diff --git a/components/resource_provider/BUILD.gn b/components/resource_provider/BUILD.gn index 06a4720..aae1a75 100644 --- a/components/resource_provider/BUILD.gn +++ b/components/resource_provider/BUILD.gn @@ -33,6 +33,7 @@ if (is_android) { ":jni_headers", ":lib", "//base", + "//build/config/sanitizers:deps", "//components/resource_provider/public/interfaces", "//mojo/environment:chromium", "//third_party/mojo/src/mojo/public/c/system:for_shared_library", diff --git a/components/test_runner/BUILD.gn b/components/test_runner/BUILD.gn index 30d7fb2..dfd4ba8 100644 --- a/components/test_runner/BUILD.gn +++ b/components/test_runner/BUILD.gn @@ -179,5 +179,9 @@ if (is_mac || is_win) { if (is_mac) { libs = [ "AppKit.framework" ] } + + deps = [ + "//build/config/sanitizers:deps", + ] } } diff --git a/components/wifi/BUILD.gn b/components/wifi/BUILD.gn index 9b6038b..e1e73fc 100644 --- a/components/wifi/BUILD.gn +++ b/components/wifi/BUILD.gn @@ -55,6 +55,7 @@ executable("wifi_test") { deps = [ ":wifi", "//base", + "//build/config/sanitizers:deps", "//components/onc", ] } diff --git a/content/BUILD.gn b/content/BUILD.gn index 7909e7f..d9c1999 100644 --- a/content/BUILD.gn +++ b/content/BUILD.gn @@ -55,6 +55,9 @@ if (is_component_build) { shared_library("content") { public_deps = content_shared_components + [ "//content/public/app:both_sources" ] + deps = [ + "//build/config/sanitizers:deps", + ] } } else { group("content") { diff --git a/content/shell/BUILD.gn b/content/shell/BUILD.gn index 91e8d28..947e8bf 100644 --- a/content/shell/BUILD.gn +++ b/content/shell/BUILD.gn @@ -416,6 +416,7 @@ if (!is_android && !is_mac) { ":content_shell_lib", ":pak", "//base/allocator", + "//build/config/sanitizers:deps", "//build/win:default_exe_manifest", ] @@ -457,6 +458,7 @@ if (is_win) { deps = [ "//base", + "//build/config/sanitizers:deps", "//components/crash/tools:crash_service", ] diff --git a/content/shell/android/BUILD.gn b/content/shell/android/BUILD.gn index dc2e2a8..2a4ef28 100644 --- a/content/shell/android/BUILD.gn +++ b/content/shell/android/BUILD.gn @@ -21,6 +21,7 @@ shared_library("libcontent_shell_content_view") { testonly = true deps = [ ":content_shell_jni_headers", + "//build/config/sanitizers:deps", "//content/shell:content_shell_lib", "//content/shell:pak", "//components/crash/browser", @@ -217,6 +218,7 @@ if (current_cpu != "x64" && current_cpu != "arm64") { deps = [ ":linker_test_jni_headers", + "//build/config/sanitizers:deps", "//content/shell:content_shell_lib", # Required to include "content/public/browser/android/compositor.h" diff --git a/courgette/BUILD.gn b/courgette/BUILD.gn index 8826ba2..1ebd2ee 100644 --- a/courgette/BUILD.gn +++ b/courgette/BUILD.gn @@ -75,6 +75,7 @@ executable("courgette") { deps = [ ":courgette_lib", "//base", + "//build/config/sanitizers:deps", ] } @@ -86,6 +87,7 @@ executable("courgette_minimal_tool") { deps = [ ":courgette_lib", "//base", + "//build/config/sanitizers:deps", ] } diff --git a/dbus/BUILD.gn b/dbus/BUILD.gn index a133e72..ee154a8 100644 --- a/dbus/BUILD.gn +++ b/dbus/BUILD.gn @@ -124,6 +124,7 @@ executable("dbus_test_server") { ":dbus", "//base", "//base/test:test_support", + "//build/config/sanitizers:deps", ] configs += [ "//build/config/linux:dbus" ] diff --git a/extensions/shell/BUILD.gn b/extensions/shell/BUILD.gn index c8e1958..06bf717 100644 --- a/extensions/shell/BUILD.gn +++ b/extensions/shell/BUILD.gn @@ -145,6 +145,7 @@ if (!(is_chromeos && !use_ozone)) { "//extensions/shell") deps = [ ":app_shell_lib", + "//build/config/sanitizers:deps", "//extensions:shell_and_test_pak", ] diff --git a/gin/BUILD.gn b/gin/BUILD.gn index 4f32c69..4535074 100644 --- a/gin/BUILD.gn +++ b/gin/BUILD.gn @@ -130,6 +130,7 @@ executable("gin_shell") { ":gin", "//base", "//base:i18n", + "//build/config/sanitizers:deps", "//v8", ] } diff --git a/google_apis/gcm/BUILD.gn b/google_apis/gcm/BUILD.gn index f41c4a3..30ab4a6 100644 --- a/google_apis/gcm/BUILD.gn +++ b/google_apis/gcm/BUILD.gn @@ -116,6 +116,7 @@ executable("mcs_probe") { ":gcm", ":test_support", "//base", + "//build/config/sanitizers:deps", "//net", "//net:test_support", "//third_party/protobuf:protobuf_lite", diff --git a/gpu/gles2_conform_support/BUILD.gn b/gpu/gles2_conform_support/BUILD.gn index a0874a7..860c0c2 100644 --- a/gpu/gles2_conform_support/BUILD.gn +++ b/gpu/gles2_conform_support/BUILD.gn @@ -26,10 +26,11 @@ executable("gles2_conform_support") { ] deps = [ "//base", - "//gpu/gles2_conform_support/egl", "//base/third_party/dynamic_annotations", - "//ui/gl", + "//build/config/sanitizers:deps", "//gpu/command_buffer/client:gles2_c_lib_nocheck", + "//gpu/gles2_conform_support/egl", + "//ui/gl", ] if (is_linux) { sources += [ @@ -73,9 +74,10 @@ if (internal_gles2_conform_tests) { ] deps = [ ":generate_gles2_conform_embedded_data", + "//build/config/sanitizers:deps", + "//gpu/command_buffer/client:gles2_c_libnocheck", "//gpu/gles2_conform_support/egl", "//gpu/gles2_conform_support/native:windowless", - "//gpu/command_buffer/client:gles2_c_libnocheck", ] configs += [ "//build/compiler:no_incompatible_pointer_warnings" ] if (is_linux) { diff --git a/gpu/skia_runner/BUILD.gn b/gpu/skia_runner/BUILD.gn index cd34057..9040d5b 100644 --- a/gpu/skia_runner/BUILD.gn +++ b/gpu/skia_runner/BUILD.gn @@ -14,6 +14,7 @@ executable("skia_runner") { deps = [ "//base", + "//build/config/sanitizers:deps", "//gpu/command_buffer/common:gles2_utils", "//gpu/command_buffer/client:gles2_implementation", "//gpu/command_buffer/client:gl_in_process_context", diff --git a/gpu/tools/compositor_model_bench/BUILD.gn b/gpu/tools/compositor_model_bench/BUILD.gn index 8eadc6b..b074ee7 100644 --- a/gpu/tools/compositor_model_bench/BUILD.gn +++ b/gpu/tools/compositor_model_bench/BUILD.gn @@ -22,6 +22,7 @@ if (is_linux && !is_chromeos && target_cpu != "arm" && use_x11) { deps = [ "//base", + "//build/config/sanitizers:deps", "//ui/gl", ] } diff --git a/mandoline/app/android/BUILD.gn b/mandoline/app/android/BUILD.gn index e88920a..4afc198 100644 --- a/mandoline/app/android/BUILD.gn +++ b/mandoline/app/android/BUILD.gn @@ -20,6 +20,7 @@ executable("mandoline_runner") { deps = [ ":jni_headers", "//base", + "//build/config/sanitizers:deps", "//mandoline/ui/desktop_ui/public/interfaces", "//mojo/common", "//mojo/environment:chromium", diff --git a/media/cast/BUILD.gn b/media/cast/BUILD.gn index 6fb4b75..1505436 100644 --- a/media/cast/BUILD.gn +++ b/media/cast/BUILD.gn @@ -369,6 +369,7 @@ executable("generate_barcode_video") { deps = [ ":test_support", "//base", + "//build/config/sanitizers:deps", "//media", ] } @@ -382,6 +383,7 @@ executable("generate_timecode_audio") { deps = [ ":test_support", "//base", + "//build/config/sanitizers:deps", "//media", ] } @@ -395,6 +397,7 @@ executable("udp_proxy") { deps = [ ":test_support", "//base", + "//build/config/sanitizers:deps", "//net", ] } diff --git a/media/cdm/ppapi/BUILD.gn b/media/cdm/ppapi/BUILD.gn index b9ca2fc..1fdebd1 100644 --- a/media/cdm/ppapi/BUILD.gn +++ b/media/cdm/ppapi/BUILD.gn @@ -30,6 +30,7 @@ shared_library("clearkeycdm") { deps = [ "//base", + "//build/config/sanitizers:deps", "//media", # For media::AudioTimestampHelper "//media:shared_memory_support", # For media::AudioBus. "//url", diff --git a/mojo/android/BUILD.gn b/mojo/android/BUILD.gn index 78ddc27..9519458 100644 --- a/mojo/android/BUILD.gn +++ b/mojo/android/BUILD.gn @@ -125,6 +125,7 @@ shared_library("mojo_java_unittests") { ":system_java_jni_headers", "//base", "//base/test/:test_support", + "//build/config/sanitizers:deps", "//mojo/message_pump", "//third_party/mojo/src/mojo/edk/system", "//third_party/mojo/src/mojo/public/cpp/bindings/tests:mojo_public_bindings_test_utils", diff --git a/mojo/runner/BUILD.gn b/mojo/runner/BUILD.gn index f275432..5a1f967 100644 --- a/mojo/runner/BUILD.gn +++ b/mojo/runner/BUILD.gn @@ -64,6 +64,7 @@ source_set("mojo_runner_lib") { executable("mojo_runner") { deps = [ ":mojo_runner_lib", + "//build/config/sanitizers:deps", ] if (is_android) { @@ -75,8 +76,6 @@ executable("mojo_runner") { # It means dynamic symbols must be preserved and exported. ldflags = [ "-Wl,--export-dynamic" ] } - - deps += [ "//build/config/sanitizers:deps" ] } source_set("in_process_native_runner") { @@ -257,6 +256,7 @@ if (is_android) { ":lib", ":run_android_application_function", "//base", + "//build/config/sanitizers:deps", ] } diff --git a/mojo/services/network/BUILD.gn b/mojo/services/network/BUILD.gn index ba43810..4dec4880 100644 --- a/mojo/services/network/BUILD.gn +++ b/mojo/services/network/BUILD.gn @@ -29,6 +29,7 @@ if (is_android) { deps = [ ":sources", "//base", + "//build/config/sanitizers:deps", "//net", ] } diff --git a/net/BUILD.gn b/net/BUILD.gn index 1e149ba..0b0b435 100644 --- a/net/BUILD.gn +++ b/net/BUILD.gn @@ -560,9 +560,10 @@ executable("dump_cache") { configs += [ "//build/config/compiler:no_size_t_to_int_warning" ] deps = [ - "//base", ":net", ":test_support", + "//base", + "//build/config/sanitizers:deps", ] } @@ -862,6 +863,7 @@ if (!is_ios && !is_android) { ":net", ":test_support", "//base", + "//build/config/sanitizers:deps", ] } @@ -876,6 +878,7 @@ if (!is_ios && !is_android) { deps = [ ":net", "//base", + "//build/config/sanitizers:deps", ] } @@ -890,6 +893,7 @@ if (!is_ios && !is_android) { deps = [ ":net", "//base", + "//build/config/sanitizers:deps", ] } @@ -902,6 +906,7 @@ if (!is_ios && !is_android) { deps = [ ":net", "//base", + "//build/config/sanitizers:deps", ] } @@ -917,6 +922,7 @@ if (!is_ios && !is_android) { ":net", "//base", "//base:i18n", + "//build/config/sanitizers:deps", "//url", ] } @@ -930,8 +936,9 @@ if (!is_ios && !is_android) { # TODO(jschuh): crbug.com/167187 fix size_t to int truncations. configs += [ "//build/config/compiler:no_size_t_to_int_warning" ] deps = [ - "//base", ":net", + "//base", + "//build/config/sanitizers:deps", ] } @@ -944,8 +951,9 @@ if (!is_ios && !is_android) { # TODO(jschuh): crbug.com/167187 fix size_t to int truncations. configs += [ "//build/config/compiler:no_size_t_to_int_warning" ] deps = [ - "//base", ":net", + "//base", + "//build/config/sanitizers:deps", ] } @@ -958,8 +966,9 @@ if (!is_ios && !is_android) { # TODO(jschuh): crbug.com/167187 fix size_t to int truncations. configs += [ "//build/config/compiler:no_size_t_to_int_warning" ] deps = [ - "//base", ":net", + "//base", + "//build/config/sanitizers:deps", ] } @@ -973,6 +982,7 @@ if (!is_ios && !is_android) { ":net", ":net_with_v8", "//base", + "//build/config/sanitizers:deps", ] if (is_desktop_linux) { @@ -994,6 +1004,7 @@ if (!is_ios && !is_android) { ":test_support", "//base", "//base/test:test_support", + "//build/config/sanitizers:deps", "//testing/gtest", ] } @@ -1010,6 +1021,7 @@ if (!is_ios && !is_android) { ":net", ":test_support", "//base", + "//build/config/sanitizers:deps", ] } @@ -1023,6 +1035,7 @@ if (!is_ios && !is_android) { deps = [ "//base", "//base:i18n", + "//build/config/sanitizers:deps", "//net/tools/tld_cleanup", ] } @@ -1101,6 +1114,7 @@ if (is_linux) { ":flip_in_mem_edsm_server_base", ":net", ":test_support", + "//build/config/sanitizers:deps", "//testing/gtest", "//testing/gmock", "//third_party/boringssl", @@ -1117,6 +1131,7 @@ if (is_linux) { ":flip_in_mem_edsm_server_base", ":net", "//base", + "//build/config/sanitizers:deps", ] } @@ -1162,6 +1177,7 @@ if (is_linux) { ":net", ":simple_quic_tools", "//base", + "//build/config/sanitizers:deps", "//third_party/boringssl", ] } @@ -1177,6 +1193,7 @@ if (is_linux) { ":net", ":simple_quic_tools", "//base", + "//build/config/sanitizers:deps", "//third_party/boringssl", ] } @@ -1216,6 +1233,7 @@ if (is_android || is_linux) { deps = [ ":net", "//base", + "//build/config/sanitizers:deps", ] } } @@ -1268,6 +1286,7 @@ if (!is_ios) { ":net", ":simple_quic_tools", "//base", + "//build/config/sanitizers:deps", "//url", ] } @@ -1279,6 +1298,7 @@ if (!is_ios) { ":net", ":simple_quic_tools", "//base", + "//build/config/sanitizers:deps", "//third_party/boringssl", "//third_party/protobuf:protobuf_lite", ] @@ -1636,6 +1656,7 @@ executable("net_perftests") { "//base", "//base:i18n", "//base/test:test_support_perf", + "//build/config/sanitizers:deps", "//testing/gtest", "//url", ] diff --git a/ppapi/BUILD.gn b/ppapi/BUILD.gn index 6523b7d..28b89ed 100644 --- a/ppapi/BUILD.gn +++ b/ppapi/BUILD.gn @@ -39,10 +39,11 @@ shared_library("ppapi_tests") { include_dirs = [ "lib/gl/include" ] deps = [ - "//ppapi/cpp", - "//ppapi/shared_impl", ":copy_test_files", ":copy_test_files2", + "//build/config/sanitizers:deps", + "//ppapi/cpp", + "//ppapi/shared_impl", ] } @@ -53,6 +54,7 @@ shared_library("power_saver_test_plugin") { ] deps = [ + "//build/config/sanitizers:deps", "//ppapi/cpp", "//ppapi/shared_impl", ] @@ -137,6 +139,7 @@ executable("pepper_hash_for_uma") { deps = [ "//base", + "//build/config/sanitizers:deps", ] } diff --git a/remoting/host/BUILD.gn b/remoting/host/BUILD.gn index 73cd018..339e1e6 100644 --- a/remoting/host/BUILD.gn +++ b/remoting/host/BUILD.gn @@ -410,6 +410,7 @@ if (is_mac) { # TODO(GYP) Mac build of remoting host. ] deps = [ + "//build/config/sanitizers:deps", "//remoting/host/setup", ] @@ -469,6 +470,7 @@ if (is_mac) { # TODO(GYP) Mac build of remoting host. deps = [ ":remoting_me2me_host_static", ":credits", + "//build/config/sanitizers:deps", ] } } diff --git a/remoting/host/it2me/BUILD.gn b/remoting/host/it2me/BUILD.gn index 076c21b..ad47b90 100644 --- a/remoting/host/it2me/BUILD.gn +++ b/remoting/host/it2me/BUILD.gn @@ -42,6 +42,7 @@ if (!is_win && enable_remoting_host) { deps = [ ":common", + "//build/config/sanitizers:deps", "//remoting/host", "//remoting/host/native_messaging", "//remoting/proto", diff --git a/remoting/test/BUILD.gn b/remoting/test/BUILD.gn index 1ec2e0f..1c3dda5 100644 --- a/remoting/test/BUILD.gn +++ b/remoting/test/BUILD.gn @@ -90,6 +90,7 @@ executable("chromoting_test_driver") { deps = [ ":test_support", "//base/test:test_support", + "//build/config/sanitizers:deps", "//testing/gtest", ] } @@ -127,6 +128,7 @@ executable("ar_sample_test_driver") { deps = [ ":ar_test_driver_common", "//base/test:test_support", + "//build/config/sanitizers:deps", "//testing/gtest", ] } diff --git a/remoting/tools/javascript_key_tester/pnacl/BUILD.gn b/remoting/tools/javascript_key_tester/pnacl/BUILD.gn index 6ce4081..e500e02 100644 --- a/remoting/tools/javascript_key_tester/pnacl/BUILD.gn +++ b/remoting/tools/javascript_key_tester/pnacl/BUILD.gn @@ -11,6 +11,7 @@ executable("remoting_key_tester_newlib") { ] deps = [ + "//build/config/sanitizers:deps", "//ppapi/native_client:ppapi_lib", "//ppapi/cpp", ] diff --git a/rlz/BUILD.gn b/rlz/BUILD.gn index bc02810..fd5862d 100644 --- a/rlz/BUILD.gn +++ b/rlz/BUILD.gn @@ -127,6 +127,7 @@ executable("rlz_id") { ] deps = [ ":rlz_lib", + "//build/config/sanitizers:deps", ] } @@ -138,6 +139,7 @@ if (is_win) { ] deps = [ ":rlz_lib", + "//build/config/sanitizers:deps", "//third_party/zlib", ] } diff --git a/sandbox/linux/BUILD.gn b/sandbox/linux/BUILD.gn index 1499739..1e143e5 100644 --- a/sandbox/linux/BUILD.gn +++ b/sandbox/linux/BUILD.gn @@ -198,6 +198,7 @@ shared_library("sandbox_linux_jni_unittests") { testonly = true deps = [ ":sandbox_linux_unittests_sources", + "//build/config/sanitizers:deps", ] if (is_android) { deps += [ "//testing/android/native_test:native_test_native_code" ] @@ -285,6 +286,10 @@ if (is_linux) { # TODO fix this and re-enable this warning. "-Wno-sign-compare", ] + + deps = [ + "//build/config/sanitizers:deps", + ] } } diff --git a/sandbox/win/BUILD.gn b/sandbox/win/BUILD.gn index ade3e99..be60efb 100644 --- a/sandbox/win/BUILD.gn +++ b/sandbox/win/BUILD.gn @@ -299,4 +299,8 @@ shared_library("pocdll") { ] defines = [ "POCDLL_EXPORTS" ] + + deps = [ + "//build/config/sanitizers:deps", + ] } diff --git a/skia/BUILD.gn b/skia/BUILD.gn index 4182c45..6a4af4c 100644 --- a/skia/BUILD.gn +++ b/skia/BUILD.gn @@ -655,6 +655,7 @@ if (is_linux && !is_chromeos) { deps = [ ":skia", "//base", + "//build/config/sanitizers:deps", ] } @@ -668,6 +669,7 @@ if (is_linux && !is_chromeos) { ":skia", "//base", "//base/test:test_support", + "//build/config/sanitizers:deps", ] } } diff --git a/storage/browser/BUILD.gn b/storage/browser/BUILD.gn index 3c669fa..3594d96 100644 --- a/storage/browser/BUILD.gn +++ b/storage/browser/BUILD.gn @@ -206,6 +206,7 @@ executable("dump_file_system") { deps = [ ":browser", "//base", + "//build/config/sanitizers:deps", "//storage/common", ] } diff --git a/sync/BUILD.gn b/sync/BUILD.gn index bfa75c4..60bfd1b 100644 --- a/sync/BUILD.gn +++ b/sync/BUILD.gn @@ -800,11 +800,12 @@ if (!is_ios) { ] deps = [ + ":test_support_sync_testserver", "//base", "//base/test:test_support", + "//build/config/sanitizers:deps", "//net:test_support", "//testing/gtest", - ":test_support_sync_testserver", ] } } diff --git a/third_party/android_platform/BUILD.gn b/third_party/android_platform/BUILD.gn index 6cc6651..123c264 100644 --- a/third_party/android_platform/BUILD.gn +++ b/third_party/android_platform/BUILD.gn @@ -24,6 +24,7 @@ if (current_toolchain == host_toolchain) { executable("android_relocation_packer") { deps = [ ":android_lib_relocation_packer", + "//build/config/sanitizers:deps", "//third_party/elfutils:libelf", ] sources = gypi_values.relocation_packer_main_source diff --git a/third_party/android_protobuf/BUILD.gn b/third_party/android_protobuf/BUILD.gn index 2a07fc2..266ca83 100644 --- a/third_party/android_protobuf/BUILD.gn +++ b/third_party/android_protobuf/BUILD.gn @@ -9,6 +9,7 @@ if (current_toolchain == host_toolchain) { configs += [ "//build/config/compiler:no_chromium_code" ] deps = [ + "//build/config/sanitizers:deps", "//third_party/zlib", ] diff --git a/third_party/cld_2/BUILD.gn b/third_party/cld_2/BUILD.gn index 3edb31d..9b05615 100644 --- a/third_party/cld_2/BUILD.gn +++ b/third_party/cld_2/BUILD.gn @@ -149,6 +149,7 @@ if (!is_win) { deps = [ ":cld2_data", ":cld2_dynamic", + "//build/config/sanitizers:deps", ] configs -= [ "//build/config/compiler:chromium_code" ] diff --git a/third_party/codesighs/BUILD.gn b/third_party/codesighs/BUILD.gn index 0fbba46..a1ffdb7 100644 --- a/third_party/codesighs/BUILD.gn +++ b/third_party/codesighs/BUILD.gn @@ -11,6 +11,10 @@ executable("codesighs") { configs -= [ "//build/config/compiler:chromium_code" ] configs += [ "//build/config/compiler:no_chromium_code" ] + + deps = [ + "//build/config/sanitizers:deps", + ] } executable("maptsvdifftool") { @@ -20,6 +24,10 @@ executable("maptsvdifftool") { configs -= [ "//build/config/compiler:chromium_code" ] configs += [ "//build/config/compiler:no_chromium_code" ] + + deps = [ + "//build/config/sanitizers:deps", + ] } if (is_win) { @@ -32,6 +40,10 @@ if (is_win) { configs -= [ "//build/config/compiler:chromium_code" ] configs += [ "//build/config/compiler:no_chromium_code" ] + + deps = [ + "//build/config/sanitizers:deps", + ] } executable("msdump2symdb") { @@ -41,6 +53,10 @@ if (is_win) { configs -= [ "//build/config/compiler:chromium_code" ] configs += [ "//build/config/compiler:no_chromium_code" ] + + deps = [ + "//build/config/sanitizers:deps", + ] } } else { executable("nm2tsv") { @@ -50,5 +66,9 @@ if (is_win) { configs -= [ "//build/config/compiler:chromium_code" ] configs += [ "//build/config/compiler:no_chromium_code" ] + + deps = [ + "//build/config/sanitizers:deps", + ] } } diff --git a/third_party/freetype2/BUILD.gn b/third_party/freetype2/BUILD.gn index fe3d921..0c91cd4 100644 --- a/third_party/freetype2/BUILD.gn +++ b/third_party/freetype2/BUILD.gn @@ -70,4 +70,8 @@ shared_library("freetype2") { public_configs = [ ":freetype2_config" ] libs = [ "z" ] + + deps = [ + "//build/config/sanitizers:deps", + ] } diff --git a/third_party/iaccessible2/BUILD.gn b/third_party/iaccessible2/BUILD.gn index ce1e8c3..051fca1 100644 --- a/third_party/iaccessible2/BUILD.gn +++ b/third_party/iaccessible2/BUILD.gn @@ -39,5 +39,6 @@ shared_library("IAccessible2Proxy") { deps = [ ":iaccessible2", + "//build/config/sanitizers:deps", ] } diff --git a/third_party/mesa/BUILD.gn b/third_party/mesa/BUILD.gn index 3f27efc..58cb60c 100644 --- a/third_party/mesa/BUILD.gn +++ b/third_party/mesa/BUILD.gn @@ -723,6 +723,7 @@ if (!is_android) { # TODO(GYP) enable for Android. ":mesa_headers", ":mesa", ":mesa_libglslcommon", + "//build/config/sanitizers:deps", ] if (is_win) { diff --git a/third_party/opus/BUILD.gn b/third_party/opus/BUILD.gn index 57196e5..dd74d25 100644 --- a/third_party/opus/BUILD.gn +++ b/third_party/opus/BUILD.gn @@ -169,6 +169,7 @@ executable("opus_compare") { deps = [ ":opus", + "//build/config/sanitizers:deps", ] } @@ -185,6 +186,7 @@ executable("opus_demo") { deps = [ ":opus", + "//build/config/sanitizers:deps", ] } diff --git a/third_party/protobuf/BUILD.gn b/third_party/protobuf/BUILD.gn index 2c8d346..f0bfbc6 100644 --- a/third_party/protobuf/BUILD.gn +++ b/third_party/protobuf/BUILD.gn @@ -260,6 +260,7 @@ if (current_toolchain == host_toolchain) { deps = [ ":protobuf_full", + "//build/config/sanitizers:deps", ] deps += [ "//build/config/sanitizers:deps" ] } diff --git a/third_party/qcms/BUILD.gn b/third_party/qcms/BUILD.gn index 395d175..b894231 100644 --- a/third_party/qcms/BUILD.gn +++ b/third_party/qcms/BUILD.gn @@ -47,6 +47,7 @@ if (current_cpu == "x86" || current_cpu == "x64") { ] deps = [ + "//build/config/sanitizers:deps", "//third_party/qcms", ] diff --git a/third_party/sqlite/BUILD.gn b/third_party/sqlite/BUILD.gn index d253173..ac14a2c 100644 --- a/third_party/sqlite/BUILD.gn +++ b/third_party/sqlite/BUILD.gn @@ -115,6 +115,7 @@ if (!use_system_sqlite) { deps = [ ":sqlite", + "//build/config/sanitizers:deps", "//third_party/icu", ] } diff --git a/third_party/widevine/cdm/BUILD.gn b/third_party/widevine/cdm/BUILD.gn index 50978d2..5235569 100644 --- a/third_party/widevine/cdm/BUILD.gn +++ b/third_party/widevine/cdm/BUILD.gn @@ -87,6 +87,7 @@ if (widevine_cdm_binary_files != []) { deps = [ ":version_h", "//base", + "//build/config/sanitizers:deps", ] if (is_mac) { diff --git a/tools/android/forwarder2/BUILD.gn b/tools/android/forwarder2/BUILD.gn index 519dfd8..942be60 100644 --- a/tools/android/forwarder2/BUILD.gn +++ b/tools/android/forwarder2/BUILD.gn @@ -42,6 +42,7 @@ if (current_toolchain == default_toolchain) { ] deps = [ "//base", + "//build/config/sanitizers:deps", "//tools/android/common", ] datadeps = [ @@ -85,6 +86,7 @@ if (current_toolchain != default_toolchain) { ] deps = [ "//base", + "//build/config/sanitizers:deps", "//tools/android/common", ] } diff --git a/tools/android/md5sum/BUILD.gn b/tools/android/md5sum/BUILD.gn index f762615..6559904 100644 --- a/tools/android/md5sum/BUILD.gn +++ b/tools/android/md5sum/BUILD.gn @@ -20,6 +20,7 @@ executable("md5sum_bin") { ] deps = [ "//base", + "//build/config/sanitizers:deps", ] # TODO(GYP) diff --git a/tools/gn/BUILD.gn b/tools/gn/BUILD.gn index cdf6e63..c44407a 100644 --- a/tools/gn/BUILD.gn +++ b/tools/gn/BUILD.gn @@ -229,6 +229,7 @@ executable("gn") { ":gn_lib", ":last_commit_position", "//base", + "//build/config/sanitizers:deps", ] } @@ -316,5 +317,6 @@ executable("generate_test_gn_data") { ] deps = [ "//base", + "//build/config/sanitizers:deps", ] } diff --git a/tools/imagediff/BUILD.gn b/tools/imagediff/BUILD.gn index 7b31672..7688cfe 100644 --- a/tools/imagediff/BUILD.gn +++ b/tools/imagediff/BUILD.gn @@ -14,6 +14,7 @@ executable("imagediff") { deps = [ "//base", + "//build/config/sanitizers:deps", "//third_party/libpng", "//third_party/zlib", ] diff --git a/tools/perf/clear_system_cache/BUILD.gn b/tools/perf/clear_system_cache/BUILD.gn index 34cfad3..ab29ad4 100644 --- a/tools/perf/clear_system_cache/BUILD.gn +++ b/tools/perf/clear_system_cache/BUILD.gn @@ -14,6 +14,7 @@ if (is_linux && !is_chromeos) { deps = [ "//base", "//base/test:test_support", + "//build/config/sanitizers:deps", ] } } diff --git a/tools/telemetry/BUILD.gn b/tools/telemetry/BUILD.gn index a27f334..9c7e989 100644 --- a/tools/telemetry/BUILD.gn +++ b/tools/telemetry/BUILD.gn @@ -6,4 +6,8 @@ executable("bitmaptools") { sources = [ "telemetry/internal/image_processing/bitmaptools.cc", ] + + deps = [ + "//build/config/sanitizers:deps", + ] } diff --git a/ui/app_list/BUILD.gn b/ui/app_list/BUILD.gn index 02e6126..1dcb168 100644 --- a/ui/app_list/BUILD.gn +++ b/ui/app_list/BUILD.gn @@ -241,6 +241,7 @@ if (is_linux && !is_chromeos) { ":app_list", ":test_support", "//base", + "//build/config/sanitizers:deps", "//content", "//content/public/browser", "//skia", diff --git a/ui/aura/BUILD.gn b/ui/aura/BUILD.gn index 607b75b..2aa15ec 100644 --- a/ui/aura/BUILD.gn +++ b/ui/aura/BUILD.gn @@ -229,6 +229,7 @@ executable("demo") { ":aura", ":test_support", "//base", + "//build/config/sanitizers:deps", "//base:i18n", "//skia", "//third_party/icu", @@ -258,6 +259,7 @@ executable("bench") { ":test_support", "//base", "//base:i18n", + "//build/config/sanitizers:deps", "//cc", "//gpu/command_buffer/client:gles2_interface", "//skia", diff --git a/ui/ozone/demo/BUILD.gn b/ui/ozone/demo/BUILD.gn index 0af98f2..f0ba120 100644 --- a/ui/ozone/demo/BUILD.gn +++ b/ui/ozone/demo/BUILD.gn @@ -24,6 +24,7 @@ executable("ozone_demo") { deps = [ "//base", + "//build/config/sanitizers:deps", "//skia", "//ui/events/ozone:events_ozone_layout", "//ui/gfx/geometry", diff --git a/ui/ozone/platform/egltest/BUILD.gn b/ui/ozone/platform/egltest/BUILD.gn index 8166cb3..dacb8ed 100644 --- a/ui/ozone/platform/egltest/BUILD.gn +++ b/ui/ozone/platform/egltest/BUILD.gn @@ -60,5 +60,9 @@ if (is_linux && ozone_platform_ozonex) { ] configs += [ "//build/config/linux:x11" ] + + deps = [ + "//build/config/sanitizers:deps", + ] } } diff --git a/ui/views/examples/BUILD.gn b/ui/views/examples/BUILD.gn index 87d543c..b25d3f6 100644 --- a/ui/views/examples/BUILD.gn +++ b/ui/views/examples/BUILD.gn @@ -103,6 +103,7 @@ executable("views_examples_exe") { deps = [ ":views_examples_lib", "//base", + "//build/config/sanitizers:deps", "//base:i18n", "//ui/base", "//ui/compositor", @@ -159,6 +160,7 @@ executable("views_examples_with_content_exe") { deps = [ ":views_examples_with_content_lib", "//base", + "//build/config/sanitizers:deps", "//content", "//content:startup_helper_win", "//ui/views_content_client", diff --git a/win8/BUILD.gn b/win8/BUILD.gn index fe2a830..d65f997 100644 --- a/win8/BUILD.gn +++ b/win8/BUILD.gn @@ -54,13 +54,14 @@ source_set("test_registrar_constants") { executable("test_registrar") { deps = [ + ":test_registrar_constants", "//base", + "//build/config/sanitizers:deps", # Chrome is the default viewer process currently used by the tests. # TODO(robertshield): Investigate building a standalone metro viewer # process. "//chrome", - ":test_registrar_constants", ] sources = [ "test/test_registrar.cc", |