Commit 0e80bba7 authored by Sylvain Defresne's avatar Sylvain Defresne Committed by Commit Bot

Explicit use of deprecated global sources assignment filter

Change all files that depends on the existence of the deprecated
global sources assignment filter to explicitly configure it by
importing the deprecated_default_sources_assignment_filter.gni
and calling set_sources_assignment_filter().

This is a preliminary step before removing the global assignment
in //build/config/BUILDCONFIG.gn and incremental migration of
those files from the deprecated feature.

To verify, used a patched version of gn:
https://gn-review.googlesource.com/c/gn/+/6401
And then ran:

    gn gen out/xxx | grep Filtering: | sort

with and without the patch for all configuration
(cross-compiling Windows on Linux).

This is a followup of https://crrev.com/c/2418443 that missed
some of the usages (as not all configuration were tested).

TBR=jochen

Bug: 1018739
Change-Id: I76d38ec4e3720d36de30bb7921148ca76b3d4d01
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2428894Reviewed-by: default avatarNico Weber <thakis@chromium.org>
Commit-Queue: Nico Weber <thakis@chromium.org>
Commit-Queue: Sylvain Defresne <sdefresne@chromium.org>
Auto-Submit: Sylvain Defresne <sdefresne@chromium.org>
Cr-Commit-Position: refs/heads/master@{#810362}
parent 1c738270
...@@ -6,6 +6,13 @@ import("//base/allocator/allocator.gni") ...@@ -6,6 +6,13 @@ import("//base/allocator/allocator.gni")
import("//build/buildflag_header.gni") import("//build/buildflag_header.gni")
import("//build/config/compiler/compiler.gni") import("//build/config/compiler/compiler.gni")
# This file depends on the legacy global sources assignment filter. It should
# be converted to check target platform before assigning source files to the
# sources variable. Remove this import and set_sources_assignment_filter call
# when the file has been converted. See https://crbug.com/1018739 for details.
import("//build/config/deprecated_default_sources_assignment_filter.gni")
set_sources_assignment_filter(deprecated_default_sources_assignment_filter)
declare_args() { declare_args() {
# Provide a way to force disable debugallocation in Debug builds, # Provide a way to force disable debugallocation in Debug builds,
# e.g. for profiling (it's more rare to profile Debug builds, # e.g. for profiling (it's more rare to profile Debug builds,
......
...@@ -4,6 +4,13 @@ ...@@ -4,6 +4,13 @@
import("//extensions/buildflags/buildflags.gni") import("//extensions/buildflags/buildflags.gni")
# This file depends on the legacy global sources assignment filter. It should
# be converted to check target platform before assigning source files to the
# sources variable. Remove this import and set_sources_assignment_filter call
# when the file has been converted. See https://crbug.com/1018739 for details.
import("//build/config/deprecated_default_sources_assignment_filter.gni")
set_sources_assignment_filter(deprecated_default_sources_assignment_filter)
assert(enable_extensions) assert(enable_extensions)
source_set("platform_apps") { source_set("platform_apps") {
......
...@@ -4,6 +4,13 @@ ...@@ -4,6 +4,13 @@
import("//extensions/buildflags/buildflags.gni") import("//extensions/buildflags/buildflags.gni")
# This file depends on the legacy global sources assignment filter. It should
# be converted to check target platform before assigning source files to the
# sources variable. Remove this import and set_sources_assignment_filter call
# when the file has been converted. See https://crbug.com/1018739 for details.
import("//build/config/deprecated_default_sources_assignment_filter.gni")
set_sources_assignment_filter(deprecated_default_sources_assignment_filter)
assert(enable_extensions) assert(enable_extensions)
source_set("extensions") { source_set("extensions") {
......
...@@ -5,6 +5,13 @@ ...@@ -5,6 +5,13 @@
import("//build/config/features.gni") import("//build/config/features.gni")
import("//components/safe_browsing/buildflags.gni") import("//components/safe_browsing/buildflags.gni")
# This file depends on the legacy global sources assignment filter. It should
# be converted to check target platform before assigning source files to the
# sources variable. Remove this import and set_sources_assignment_filter call
# when the file has been converted. See https://crbug.com/1018739 for details.
import("//build/config/deprecated_default_sources_assignment_filter.gni")
set_sources_assignment_filter(deprecated_default_sources_assignment_filter)
source_set("cpp") { source_set("cpp") {
deps = [ "//chrome/common/safe_browsing:archive_analyzer_results" ] deps = [ "//chrome/common/safe_browsing:archive_analyzer_results" ]
public_deps = [ "//chrome/services/file_util/public/mojom" ] public_deps = [ "//chrome/services/file_util/public/mojom" ]
......
...@@ -6,6 +6,13 @@ import("//chromecast/chromecast.gni") ...@@ -6,6 +6,13 @@ import("//chromecast/chromecast.gni")
import("//testing/test.gni") import("//testing/test.gni")
import("//tools/grit/grit_rule.gni") import("//tools/grit/grit_rule.gni")
# This file depends on the legacy global sources assignment filter. It should
# be converted to check target platform before assigning source files to the
# sources variable. Remove this import and set_sources_assignment_filter call
# when the file has been converted. See https://crbug.com/1018739 for details.
import("//build/config/deprecated_default_sources_assignment_filter.gni")
set_sources_assignment_filter(deprecated_default_sources_assignment_filter)
cast_source_set("app") { cast_source_set("app") {
sources = [ sources = [
"cast_main_delegate.cc", "cast_main_delegate.cc",
......
...@@ -10,6 +10,13 @@ if (is_android) { ...@@ -10,6 +10,13 @@ if (is_android) {
import("//build/config/android/rules.gni") import("//build/config/android/rules.gni")
} }
# This file depends on the legacy global sources assignment filter. It should
# be converted to check target platform before assigning source files to the
# sources variable. Remove this import and set_sources_assignment_filter call
# when the file has been converted. See https://crbug.com/1018739 for details.
import("//build/config/deprecated_default_sources_assignment_filter.gni")
set_sources_assignment_filter(deprecated_default_sources_assignment_filter)
declare_args() { declare_args() {
# Denotes the type of Cast product. This is #defined as CAST_PRODUCT_TYPE in # Denotes the type of Cast product. This is #defined as CAST_PRODUCT_TYPE in
# version.h. See //third_party/metrics_proto/cast_logs.proto for valid values. # version.h. See //third_party/metrics_proto/cast_logs.proto for valid values.
......
...@@ -5,15 +5,20 @@ ...@@ -5,15 +5,20 @@
import("//chromecast/chromecast.gni") import("//chromecast/chromecast.gni")
import("//testing/test.gni") import("//testing/test.gni")
# This file depends on the legacy global sources assignment filter. It should
# be converted to check target platform before assigning source files to the
# sources variable. Remove this import and set_sources_assignment_filter call
# when the file has been converted. See https://crbug.com/1018739 for details.
import("//build/config/deprecated_default_sources_assignment_filter.gni")
set_sources_assignment_filter(deprecated_default_sources_assignment_filter)
cast_source_set("build_info") { cast_source_set("build_info") {
sources = [ sources = [
"build_info.cc", "build_info.cc",
"build_info.h", "build_info.h",
] ]
deps = [ deps = [ "//chromecast/base:cast_version" ]
"//chromecast/base:cast_version",
]
} }
cast_source_set("crash_storage") { cast_source_set("crash_storage") {
......
...@@ -2,6 +2,13 @@ ...@@ -2,6 +2,13 @@
# Use of this source code is governed by a BSD-style license that can be # Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file. # found in the LICENSE file.
# This file depends on the legacy global sources assignment filter. It should
# be converted to check target platform before assigning source files to the
# sources variable. Remove this import and set_sources_assignment_filter call
# when the file has been converted. See https://crbug.com/1018739 for details.
import("//build/config/deprecated_default_sources_assignment_filter.gni")
set_sources_assignment_filter(deprecated_default_sources_assignment_filter)
static_library("renderer") { static_library("renderer") {
sources = [ sources = [
"print_render_frame_helper.cc", "print_render_frame_helper.cc",
......
...@@ -4,6 +4,13 @@ ...@@ -4,6 +4,13 @@
import("//components/spellcheck/spellcheck_build_features.gni") import("//components/spellcheck/spellcheck_build_features.gni")
# This file depends on the legacy global sources assignment filter. It should
# be converted to check target platform before assigning source files to the
# sources variable. Remove this import and set_sources_assignment_filter call
# when the file has been converted. See https://crbug.com/1018739 for details.
import("//build/config/deprecated_default_sources_assignment_filter.gni")
set_sources_assignment_filter(deprecated_default_sources_assignment_filter)
source_set("renderer") { source_set("renderer") {
sources = [ sources = [
"custom_dictionary_engine.cc", "custom_dictionary_engine.cc",
......
...@@ -9,6 +9,13 @@ import("//testing/test.gni") ...@@ -9,6 +9,13 @@ import("//testing/test.gni")
import("//ui/ozone/ozone.gni") import("//ui/ozone/ozone.gni")
import("features.gni") import("features.gni")
# This file depends on the legacy global sources assignment filter. It should
# be converted to check target platform before assigning source files to the
# sources variable. Remove this import and set_sources_assignment_filter call
# when the file has been converted. See https://crbug.com/1018739 for details.
import("//build/config/deprecated_default_sources_assignment_filter.gni")
set_sources_assignment_filter(deprecated_default_sources_assignment_filter)
# Generate a buildflag header for compile-time checking of Vulkan support. # Generate a buildflag header for compile-time checking of Vulkan support.
buildflag_header("buildflags") { buildflag_header("buildflags") {
header = "buildflags.h" header = "buildflags.h"
...@@ -26,8 +33,8 @@ if (enable_vulkan) { ...@@ -26,8 +33,8 @@ if (enable_vulkan) {
source_set("vulkan_function_pointers") { source_set("vulkan_function_pointers") {
visibility = [ visibility = [
":vulkan",
":vma_wrapper", ":vma_wrapper",
":vulkan",
] ]
sources = [ sources = [
......
...@@ -15,6 +15,13 @@ if (is_android) { ...@@ -15,6 +15,13 @@ if (is_android) {
import("//build/config/android/rules.gni") import("//build/config/android/rules.gni")
} }
# This file depends on the legacy global sources assignment filter. It should
# be converted to check target platform before assigning source files to the
# sources variable. Remove this import and set_sources_assignment_filter call
# when the file has been converted. See https://crbug.com/1018739 for details.
import("//build/config/deprecated_default_sources_assignment_filter.gni")
set_sources_assignment_filter(deprecated_default_sources_assignment_filter)
# Common configuration for targets in the media/midi directory. # Common configuration for targets in the media/midi directory.
config("midi_config") { config("midi_config") {
if (use_alsa && use_udev) { if (use_alsa && use_udev) {
......
...@@ -11,6 +11,13 @@ if (is_android) { ...@@ -11,6 +11,13 @@ if (is_android) {
import("//build/config/android/rules.gni") import("//build/config/android/rules.gni")
} }
# This file depends on the legacy global sources assignment filter. It should
# be converted to check target platform before assigning source files to the
# sources variable. Remove this import and set_sources_assignment_filter call
# when the file has been converted. See https://crbug.com/1018739 for details.
import("//build/config/deprecated_default_sources_assignment_filter.gni")
set_sources_assignment_filter(deprecated_default_sources_assignment_filter)
declare_args() { declare_args() {
compile_suid_client = is_linux || is_chromeos compile_suid_client = is_linux || is_chromeos
......
...@@ -4,6 +4,13 @@ ...@@ -4,6 +4,13 @@
import("//third_party/blink/renderer/core/core.gni") import("//third_party/blink/renderer/core/core.gni")
# This file depends on the legacy global sources assignment filter. It should
# be converted to check target platform before assigning source files to the
# sources variable. Remove this import and set_sources_assignment_filter call
# when the file has been converted. See https://crbug.com/1018739 for details.
import("//build/config/deprecated_default_sources_assignment_filter.gni")
set_sources_assignment_filter(deprecated_default_sources_assignment_filter)
blink_core_sources("editing") { blink_core_sources("editing") {
sources = [ sources = [
"bidi_adjustment.cc", "bidi_adjustment.cc",
......
...@@ -4,6 +4,13 @@ ...@@ -4,6 +4,13 @@
import("//third_party/blink/renderer/core/core.gni") import("//third_party/blink/renderer/core/core.gni")
# This file depends on the legacy global sources assignment filter. It should
# be converted to check target platform before assigning source files to the
# sources variable. Remove this import and set_sources_assignment_filter call
# when the file has been converted. See https://crbug.com/1018739 for details.
import("//build/config/deprecated_default_sources_assignment_filter.gni")
set_sources_assignment_filter(deprecated_default_sources_assignment_filter)
blink_core_sources("layout") { blink_core_sources("layout") {
sources = [ sources = [
"api/hit_test_action.h", "api/hit_test_action.h",
......
...@@ -5,6 +5,13 @@ ...@@ -5,6 +5,13 @@
import("//build/config/ui.gni") import("//build/config/ui.gni")
import("//testing/test.gni") import("//testing/test.gni")
# This file depends on the legacy global sources assignment filter. It should
# be converted to check target platform before assigning source files to the
# sources variable. Remove this import and set_sources_assignment_filter call
# when the file has been converted. See https://crbug.com/1018739 for details.
import("//build/config/deprecated_default_sources_assignment_filter.gni")
set_sources_assignment_filter(deprecated_default_sources_assignment_filter)
component("aura") { component("aura") {
public = [ public = [
"client/aura_constants.h", "client/aura_constants.h",
......
...@@ -4,6 +4,13 @@ ...@@ -4,6 +4,13 @@
import("//build/config/ui.gni") import("//build/config/ui.gni")
# This file depends on the legacy global sources assignment filter. It should
# be converted to check target platform before assigning source files to the
# sources variable. Remove this import and set_sources_assignment_filter call
# when the file has been converted. See https://crbug.com/1018739 for details.
import("//build/config/deprecated_default_sources_assignment_filter.gni")
set_sources_assignment_filter(deprecated_default_sources_assignment_filter)
component("aura_extra") { component("aura_extra") {
sources = [ sources = [
"aura_extra_export.h", "aura_extra_export.h",
......
...@@ -5,6 +5,13 @@ ...@@ -5,6 +5,13 @@
import("//build/config/features.gni") import("//build/config/features.gni")
import("//build/config/ui.gni") import("//build/config/ui.gni")
# This file depends on the legacy global sources assignment filter. It should
# be converted to check target platform before assigning source files to the
# sources variable. Remove this import and set_sources_assignment_filter call
# when the file has been converted. See https://crbug.com/1018739 for details.
import("//build/config/deprecated_default_sources_assignment_filter.gni")
set_sources_assignment_filter(deprecated_default_sources_assignment_filter)
assert(use_ozone) assert(use_ozone)
component("ozone") { component("ozone") {
......
...@@ -8,6 +8,13 @@ import("//components/vector_icons/vector_icons.gni") ...@@ -8,6 +8,13 @@ import("//components/vector_icons/vector_icons.gni")
import("//testing/test.gni") import("//testing/test.gni")
import("//ui/base/ui_features.gni") import("//ui/base/ui_features.gni")
# This file depends on the legacy global sources assignment filter. It should
# be converted to check target platform before assigning source files to the
# sources variable. Remove this import and set_sources_assignment_filter call
# when the file has been converted. See https://crbug.com/1018739 for details.
import("//build/config/deprecated_default_sources_assignment_filter.gni")
set_sources_assignment_filter(deprecated_default_sources_assignment_filter)
aggregate_vector_icons("message_center_vector_icons") { aggregate_vector_icons("message_center_vector_icons") {
icon_directory = "vector_icons" icon_directory = "vector_icons"
......
...@@ -28,6 +28,13 @@ if (is_android) { ...@@ -28,6 +28,13 @@ if (is_android) {
import("//v8/gni/v8.gni") import("//v8/gni/v8.gni")
} }
# This file depends on the legacy global sources assignment filter. It should
# be converted to check target platform before assigning source files to the
# sources variable. Remove this import and set_sources_assignment_filter call
# when the file has been converted. See https://crbug.com/1018739 for details.
import("//build/config/deprecated_default_sources_assignment_filter.gni")
set_sources_assignment_filter(deprecated_default_sources_assignment_filter)
source_set("android_descriptors") { source_set("android_descriptors") {
sources = [ "browser/android_descriptors.h" ] sources = [ "browser/android_descriptors.h" ]
public_deps = [ "//content/public/common:content_descriptors" ] public_deps = [ "//content/public/common:content_descriptors" ]
......
...@@ -14,6 +14,13 @@ if (is_android) { ...@@ -14,6 +14,13 @@ if (is_android) {
import("//build/config/android/config.gni") import("//build/config/android/config.gni")
} }
# This file depends on the legacy global sources assignment filter. It should
# be converted to check target platform before assigning source files to the
# sources variable. Remove this import and set_sources_assignment_filter call
# when the file has been converted. See https://crbug.com/1018739 for details.
import("//build/config/deprecated_default_sources_assignment_filter.gni")
set_sources_assignment_filter(deprecated_default_sources_assignment_filter)
static_library("weblayer_shell_lib") { static_library("weblayer_shell_lib") {
testonly = true testonly = true
sources = [ sources = [
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment