| Index: build/config/BUILD.gn
|
| diff --git a/build/config/BUILD.gn b/build/config/BUILD.gn
|
| index 5eb5e0a1a0223c123a1a890241aeddcd2ad42a81..f28f0cf8ee9e4ff9ee58656f62a080189a68083b 100644
|
| --- a/build/config/BUILD.gn
|
| +++ b/build/config/BUILD.gn
|
| @@ -136,13 +136,31 @@ config("feature_flags") {
|
| if (use_allocator != "tcmalloc") {
|
| defines += [ "NO_TCMALLOC" ]
|
| }
|
| - if (is_asan) {
|
| + if (is_asan || is_lsan || is_tsan || is_msan) {
|
| defines += [
|
| - "ADDRESS_SANITIZER",
|
| "MEMORY_TOOL_REPLACES_ALLOCATOR",
|
| "MEMORY_SANITIZER_INITIAL_SIZE",
|
| ]
|
| }
|
| + if (is_asan) {
|
| + defines += [ "ADDRESS_SANITIZER" ]
|
| + }
|
| + if (is_lsan) {
|
| + defines += [
|
| + "LEAK_SANITIZER",
|
| + "WTF_USE_LEAK_SANITIZER=1",
|
| + ]
|
| + }
|
| + if (is_tsan) {
|
| + defines += [
|
| + "THREAD_SANITIZER",
|
| + "DYNAMIC_ANNOTATIONS_EXTERNAL_IMPL=1",
|
| + "WTF_USE_DYNAMIC_ANNOTATIONS_NOIMPL=1",
|
| + ]
|
| + }
|
| + if (is_msan) {
|
| + defines += [ "MEMORY_SANITIZER" ]
|
| + }
|
| if (enable_webrtc) {
|
| defines += [ "ENABLE_WEBRTC=1" ]
|
| }
|
| @@ -209,6 +227,9 @@ config("feature_flags") {
|
| if (enable_hidpi) {
|
| defines += [ "ENABLE_HIDPI=1" ]
|
| }
|
| + if (enable_topchrome_md) {
|
| + defines += [ "ENABLE_TOPCHRME_MD=1" ]
|
| + }
|
| if (proprietary_codecs) {
|
| defines += [ "USE_PROPRIETARY_CODECS" ]
|
| }
|
| @@ -248,6 +269,9 @@ config("feature_flags") {
|
| } else {
|
| defines += [ "CHROMIUM_BUILD" ]
|
| }
|
| + if (enable_media_router) {
|
| + defines += [ "ENABLE_MEDIA_ROUTER=1" ]
|
| + }
|
| }
|
|
|
| # Debug/release ----------------------------------------------------------------
|
| @@ -284,7 +308,12 @@ config("release") {
|
| # Sanitizers.
|
| # TODO(GYP) The GYP build has "release_valgrind_build == 0" for this
|
| # condition. When Valgrind is set up, we need to do the same here.
|
| - if (!is_tsan) {
|
| + if (is_tsan) {
|
| + defines += [
|
| + "DYNAMIC_ANNOTATIONS_ENABLED=1",
|
| + "WTF_USE_DYNAMIC_ANNOTATIONS=1",
|
| + ]
|
| + } else {
|
| defines += [ "NVALGRIND" ]
|
| if (!is_nacl) {
|
| # NaCl always enables dynamic annotations. Currently this value is set to
|
|
|