diff --git a/BUILD.gn b/BUILD.gn index 1e44a857..7d2f0a12 100644 --- a/BUILD.gn +++ b/BUILD.gn @@ -16,6 +16,11 @@ import("build/crashpad_buildconfig.gni") import("build/test.gni") import("util/net/tls.gni") +if (crashpad_is_in_chromium) { + # Prevent Chromium source assignment filters from being inherited. + set_sources_assignment_filter([]) +} + config("crashpad_config") { include_dirs = [ "." ] } diff --git a/build/crashpad_buildconfig.gni b/build/crashpad_buildconfig.gni index 7540fb28..d919a8b4 100644 --- a/build/crashpad_buildconfig.gni +++ b/build/crashpad_buildconfig.gni @@ -51,8 +51,8 @@ if (crashpad_is_in_chromium) { import("../../../mini_chromium/mini_chromium/build/compiler.gni") import("../../../mini_chromium/mini_chromium/build/platform.gni") } else { - # Both standalone and in Fuchsia tree use mini_chromium, and it's mapped into - # the same location in both cases. + # Both standalone and in Fuchsia tree use mini_chromium, and it's mapped + # into the same location in both cases. import("../third_party/mini_chromium/mini_chromium/build/compiler.gni") import("../third_party/mini_chromium/mini_chromium/build/platform.gni") } diff --git a/client/BUILD.gn b/client/BUILD.gn index 32b47fd5..a74ddc3f 100644 --- a/client/BUILD.gn +++ b/client/BUILD.gn @@ -14,6 +14,11 @@ import("../build/crashpad_buildconfig.gni") +if (crashpad_is_in_chromium) { + # Prevent Chromium source assignment filters from being inherited. + set_sources_assignment_filter([]) +} + static_library("client") { sources = [ "annotation.cc", @@ -51,7 +56,6 @@ static_library("client") { } if (crashpad_is_linux || crashpad_is_android) { - set_sources_assignment_filter([]) sources += [ "crashpad_client_linux.cc", "simulate_crash_linux.h", diff --git a/compat/BUILD.gn b/compat/BUILD.gn index 9c22acfc..ba9d78cd 100644 --- a/compat/BUILD.gn +++ b/compat/BUILD.gn @@ -14,6 +14,11 @@ import("../build/crashpad_buildconfig.gni") +if (crashpad_is_in_chromium) { + # Prevent Chromium source assignment filters from being inherited. + set_sources_assignment_filter([]) +} + config("compat_config") { include_dirs = [] diff --git a/handler/BUILD.gn b/handler/BUILD.gn index 51ff2cf2..472c1477 100644 --- a/handler/BUILD.gn +++ b/handler/BUILD.gn @@ -14,6 +14,11 @@ import("../build/crashpad_buildconfig.gni") +if (crashpad_is_in_chromium) { + # Prevent Chromium source assignment filters from being inherited. + set_sources_assignment_filter([]) +} + static_library("handler") { sources = [ "crash_report_upload_thread.cc", @@ -40,7 +45,6 @@ static_library("handler") { } if (crashpad_is_linux || crashpad_is_android) { - set_sources_assignment_filter([]) sources += [ "linux/capture_snapshot.cc", "linux/capture_snapshot.h", @@ -169,7 +173,6 @@ if (crashpad_is_android) { } crashpad_executable("crashpad_handler_trampoline") { - set_sources_assignment_filter([]) output_name = "libcrashpad_handler_trampoline.so" sources = [ "linux/handler_trampoline.cc" ] diff --git a/minidump/BUILD.gn b/minidump/BUILD.gn index 88227646..804f39f7 100644 --- a/minidump/BUILD.gn +++ b/minidump/BUILD.gn @@ -14,6 +14,11 @@ import("../build/crashpad_buildconfig.gni") +if (crashpad_is_in_chromium) { + # Prevent Chromium source assignment filters from being inherited. + set_sources_assignment_filter([]) +} + static_library("minidump") { sources = [ "minidump_annotation_writer.cc", diff --git a/test/BUILD.gn b/test/BUILD.gn index 7b052f0a..69ba5b44 100644 --- a/test/BUILD.gn +++ b/test/BUILD.gn @@ -14,6 +14,11 @@ import("../build/crashpad_buildconfig.gni") +if (crashpad_is_in_chromium) { + # Prevent Chromium source assignment filters from being inherited. + set_sources_assignment_filter([]) +} + static_library("test") { testonly = true @@ -84,7 +89,6 @@ static_library("test") { } if (crashpad_is_linux || crashpad_is_android) { - set_sources_assignment_filter([]) sources += [ "linux/fake_ptrace_connection.cc", "linux/fake_ptrace_connection.h", diff --git a/test/ios/BUILD.gn b/test/ios/BUILD.gn index 59dd35d5..cbf8ef89 100644 --- a/test/ios/BUILD.gn +++ b/test/ios/BUILD.gn @@ -16,6 +16,9 @@ import("../../build/crashpad_buildconfig.gni") if (crashpad_is_in_chromium) { import("//build/config/ios/rules.gni") + + # Prevent Chromium source assignment filters from being inherited. + set_sources_assignment_filter([]) } else if (crashpad_is_standalone) { import("//third_party/mini_chromium/mini_chromium/build/ios/rules.gni") } diff --git a/test/ios/host/BUILD.gn b/test/ios/host/BUILD.gn index 20f25003..0a14f179 100644 --- a/test/ios/host/BUILD.gn +++ b/test/ios/host/BUILD.gn @@ -16,6 +16,9 @@ import("../../../build/crashpad_buildconfig.gni") if (crashpad_is_in_chromium) { import("//build/config/ios/rules.gni") + + # Prevent Chromium source assignment filters from being inherited. + set_sources_assignment_filter([]) } else if (crashpad_is_standalone) { import("//third_party/mini_chromium/mini_chromium/build/ios/rules.gni") } diff --git a/tools/BUILD.gn b/tools/BUILD.gn index 7da109bc..592e0ad5 100644 --- a/tools/BUILD.gn +++ b/tools/BUILD.gn @@ -14,6 +14,11 @@ import("../build/crashpad_buildconfig.gni") +if (crashpad_is_in_chromium) { + # Prevent Chromium source assignment filters from being inherited. + set_sources_assignment_filter([]) +} + source_set("tool_support") { sources = [ "tool_support.cc",