diff options
author | Allan Sandfeld Jensen <allan.jensen@qt.io> | 2020-12-09 10:12:38 +0100 |
---|---|---|
committer | Allan Sandfeld Jensen <allan.jensen@qt.io> | 2021-10-04 10:21:06 +0200 |
commit | 812e2db7c43a5773d8cd1a0e20bbfa1576413fc1 (patch) | |
tree | d1535467af462923f61420bb1fa4f5722a494c4b | |
parent | ef7f6c6ae7463d0e14bf15c57fb0ed5c2626c7c1 (diff) | |
download | qtwebengine-chromium-812e2db7c43a5773d8cd1a0e20bbfa1576413fc1.tar.gz |
Reinstate jumbo-builds
Reverts four patches disabling and removing jumbo builds.
It makes too big of a difference for us to drop.
Change-Id: Ib7dd65996f9e985480f49fab2d1781a5d08bf6fd
Reviewed-by: Michal Klocek <michal.klocek@qt.io>
192 files changed, 1120 insertions, 305 deletions
diff --git a/chromium/ash/keyboard/ui/BUILD.gn b/chromium/ash/keyboard/ui/BUILD.gn index 9ab4d1a7437..60ef4742c93 100644 --- a/chromium/ash/keyboard/ui/BUILD.gn +++ b/chromium/ash/keyboard/ui/BUILD.gn @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//mojo/public/tools/bindings/mojom.gni") import("//testing/test.gni") import("//third_party/google_input_tools/closure.gni") @@ -10,7 +11,7 @@ import("//tools/grit/grit_rule.gni") assert(is_chromeos) -component("ui") { +jumbo_component("ui") { sources = [ "container_behavior.cc", "container_behavior.h", diff --git a/chromium/base/BUILD.gn b/chromium/base/BUILD.gn index 8dde7e9caae..cb9dfb9702f 100644 --- a/chromium/base/BUILD.gn +++ b/chromium/base/BUILD.gn @@ -26,6 +26,7 @@ import("//build/config/chromecast_build.gni") import("//build/config/chromeos/ui_mode.gni") import("//build/config/compiler/compiler.gni") import("//build/config/dcheck_always_on.gni") +import("//build/config/jumbo.gni") import("//build/config/logging.gni") import("//build/config/nacl/config.gni") import("//build/config/profiling/profiling.gni") @@ -212,7 +213,14 @@ config("perfetto_config") { # to be linked in where they wouldn't have otherwise. This does not include # test code (test support and anything in the test directory) which should use # source_set as is recommended for GN targets). -component("base") { +jumbo_component("base") { + if (is_nacl || is_ios) { + # Link errors related to malloc functions if libbase for nacl is + # compiled with jumbo: https://crbug.com/775959. + # Same for ios: https://crbug.com/776313. + never_build_jumbo = true + } + sources = [ "allocator/allocator_check.cc", "allocator/allocator_check.h", diff --git a/chromium/base/util/type_safety/BUILD.gn b/chromium/base/util/type_safety/BUILD.gn index 760e3b0256e..c4bc96474a2 100644 --- a/chromium/base/util/type_safety/BUILD.gn +++ b/chromium/base/util/type_safety/BUILD.gn @@ -2,9 +2,10 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/nocompile.gni") -# Change this target's type to component if it starts to contain more than +# Change this target's type to jumbo_component if it starts to contain more than # just headers. Header-only targets cannot be compiled to libraries, so it must # remain a source_set for now. source_set("type_safety") { diff --git a/chromium/build/config/jumbo.gni b/chromium/build/config/jumbo.gni new file mode 100644 index 00000000000..dd8972423e5 --- /dev/null +++ b/chromium/build/config/jumbo.gni @@ -0,0 +1,296 @@ +# Copyright 2017 The Chromium Authors. All rights reserved. +# Use of this source code is governed by a BSD-style license that can be +# found in the LICENSE file. + +import("//build/config/nacl/config.gni") # To see if jumbo should be turned off +import("//build/toolchain/goma.gni") + +declare_args() { + # If true, use a jumbo build (files compiled together) to speed up + # compilation. + use_jumbo_build = false + + # A list of build targets to exclude from jumbo builds, for optimal + # round trip time when frequently changing a set of cpp files. The + # targets can be just the short name (in which case it matches any + # target with that name), a directory prefixed with the root + # specifier //, or a full build target label. + # + # Example: + # These would all exclude the "browser" target in a file + # content/browser/BUILD.gn, and potentially more. + # + # jumbo_build_excluded = [ "browser" ] + # jumbo_build_excluded = [ "//content/browser" ] + # jumbo_build_excluded = [ "//content/browser:browser" ] + jumbo_build_excluded = [] + + # How many files to group on average. Smaller numbers give more + # parallellism, higher numbers give less total CPU usage. Higher + # numbers also give longer single-file recompilation times. + # + # Recommendations: + # Higher numbers than 100 does not reduce wall clock compile times + # even for 4 cores or less so no reason to go higher than 100. + # Going from 50 to 100 with a 4 core CPU saves about 3% CPU time and + # 3% wall clock time in a tree with blink, v8 and content + # jumbofied. At the same time it increases the compile time for the + # largest jumbo chunks by 10-20% and reduces the chance to use all + # available CPU cores. So set the default to 50 to balance between + # high and low-core build performance. -1 means do the default which + # varies depending on whether goma is enabled. + jumbo_file_merge_limit = -1 +} + +# Normal builds benefit from lots of jumbification +jumbo_file_merge_default = 50 + +# Goma builds benefit from more parallelism +jumbo_file_merge_goma = 8 + +# Use one of the targets jumbo_source_set, jumbo_static_library, or +# jumbo_component to generate a target which merges sources if possible to +# compile much faster. +# +# Special values. +# +# target_type +# The kind of target to build. For example the string +# "static_library". +# +# always_build_jumbo +# If set and set to true, then use jumbo compile even when it is +# globally disabled. Otherwise it has no effect. +# +# never_build_jumbo +# If set and set to true, then do not jumbo compile even if it is +# globally enabled. Otherwise it has no effect. +# +# jumbo_excluded_sources +# If set to a list of files, those files will not be merged with +# the rest. This can be necessary if merging the files causes +# compilation issues and fixing the issues is impractical. +template("internal_jumbo_target") { + use_jumbo_build_for_target = use_jumbo_build + if (defined(invoker.always_build_jumbo) && invoker.always_build_jumbo) { + use_jumbo_build_for_target = true + } + if (defined(invoker.never_build_jumbo) && invoker.never_build_jumbo) { + use_jumbo_build_for_target = false + } + if (is_nacl_irt || is_nacl_nonsfi) { + # The code is barely compatible with the nacl toolchain anymore and we + # don't want to stress it further with jumbo compilation units. + use_jumbo_build_for_target = false + } + + foreach(excluded_target, jumbo_build_excluded) { + if (excluded_target == target_name || + excluded_target == get_label_info(":" + target_name, "dir") || + excluded_target == + get_label_info(":" + target_name, "label_no_toolchain")) { + use_jumbo_build_for_target = false + } + } + + excluded_sources = [] + if (defined(invoker.jumbo_excluded_sources)) { + excluded_sources = invoker.jumbo_excluded_sources + } + + if (defined(invoker.sources)) { + invoker_sources = invoker.sources + } else { + invoker_sources = [] + } + + gen_target_dir = invoker.target_gen_dir + + not_needed([ "gen_target_dir" ]) # Prevent "unused variable". + + if (use_jumbo_build_for_target) { + jumbo_files = [] + + # Split the sources list into chunks that are not excessively large + current_file_index = 0 + next_chunk_start = 0 + next_chunk_number = 1 + merge_limit = jumbo_file_merge_limit + if (merge_limit == -1) { + if (use_goma) { + merge_limit = jumbo_file_merge_goma + } else { + merge_limit = jumbo_file_merge_default + } + } + has_c_file = false + has_objective_c_file = false + sources_in_jumbo_files = [] + assert(merge_limit > 0) + foreach(source_file, invoker_sources) { + source_ext = get_path_info(source_file, "extension") + is_source_file = true + if (source_ext == "c") { + has_c_file = true + } else if (source_ext == "mm") { + has_objective_c_file = true + } else if (source_ext == "cc" || source_ext == "cpp") { + if (current_file_index == next_chunk_start) { + jumbo_files += [ "$gen_target_dir/" + target_name + "_jumbo_" + + next_chunk_number + ".cc" ] + next_chunk_number += 1 + next_chunk_start += merge_limit + } + current_file_index += 1 + } else { + is_source_file = false + } + if (is_source_file) { + sources_in_jumbo_files += [ source_file ] + } + } + + if (jumbo_files == [] || current_file_index == 1) { + # Empty sources list or a sources list with only header files or + # at most one non-header file. + use_jumbo_build_for_target = false + not_needed([ + "sources_in_jumbo_files", + "current_file_index", + "next_chunk_start", + "next_chunk_number", + ]) + } + + if (has_c_file) { + jumbo_files += [ "$gen_target_dir/" + target_name + "_jumbo_c.c" ] + } + if (has_objective_c_file) { + jumbo_files += [ "$gen_target_dir/" + target_name + "_jumbo_mm.mm" ] + } + } + + if (use_jumbo_build_for_target) { + merge_action_name = target_name + "__jumbo_merge" + sources_in_jumbo_files -= excluded_sources + + # Create an action that calls a script that merges all the source files. + action(merge_action_name) { + script = "//build/config/merge_for_jumbo.py" + response_file_contents = + rebase_path(sources_in_jumbo_files, root_build_dir) + outputs = jumbo_files + args = [ "--outputs" ] + rebase_path(outputs, root_build_dir) + + [ "--file-list={{response_file_name}}" ] + + # For the "gn analyze" step to work, gn needs to know about the + # original source files. They can't be in |sources| because then + # they will be compiled, so they have to be somewhere else where + # gn analyze looks. One alternative is the |data| list but that + # will affect test packaging with known bad effects on + # distributed testing. Putting them in this action's input list + # is the least bad place. + inputs = [] + foreach(f, invoker_sources - excluded_sources) { + # Avoid generated files and non non-source files. + in_source_tree = string_replace(rebase_path(f), + rebase_path(root_out_dir), + "dummy") == rebase_path(f) + is_source_file = get_path_info(f, "extension") == "cc" || + get_path_info(f, "extension") == "cpp" || + get_path_info(f, "extension") == "c" || + get_path_info(f, "extension") == "mm" + if (in_source_tree && is_source_file) { + inputs += [ f ] + } + } + } + } else { + # If the list subtraction triggers a gn error, + # jumbo_excluded_sources lists a file that is not in sources. + sources_after_exclusion = invoker_sources - excluded_sources + not_needed([ "sources_after_exclusion" ]) + } + + target_type = invoker.target_type + + # Perform the actual operation, either on the original sources or + # the sources post-jumbo merging. + target(target_type, target_name) { + deps = [] + if (defined(invoker.deps)) { + deps += invoker.deps + } + + # Take everything else not handled above from the invoker. + variables_to_not_forward = [ "deps" ] + if (use_jumbo_build_for_target) { + deps += [ ":" + merge_action_name ] + variables_to_not_forward += [ "sources" ] + assert(jumbo_files != []) + sources = invoker_sources - sources_in_jumbo_files + jumbo_files + + # Change include_dirs to make sure that the jumbo file can find its + # #included files. + variables_to_not_forward += [ "include_dirs" ] + include_dirs = [] + if (defined(invoker.include_dirs)) { + include_dirs = invoker.include_dirs + } + include_dirs += [ root_build_dir ] + } + forward_variables_from(invoker, "*", variables_to_not_forward) + } +} + +# See documentation above by "internal_jumbo_target". +template("jumbo_source_set") { + internal_jumbo_target(target_name) { + target_type = "source_set" + forward_variables_from(invoker, "*") + } +} + +set_defaults("jumbo_source_set") { + # This sets the default list of configs when the jumbo_source_set target + # is defined. The default_compiler_configs comes from BUILDCONFIG.gn and + # is the list normally applied to static libraries and source sets. + configs = default_compiler_configs +} + +# See documentation above by "internal_jumbo_target". +template("jumbo_static_library") { + internal_jumbo_target(target_name) { + target_type = "static_library" + forward_variables_from(invoker, "*") + } +} + +set_defaults("jumbo_static_library") { + # This sets the default list of configs when the jumbo_static_library target + # is defined. The default_compiler_configs comes from BUILDCONFIG.gn and + # is the list normally applied to static libraries and source sets. + configs = default_compiler_configs +} + +# See documentation above by "internal_jumbo_target". +template("jumbo_component") { + internal_jumbo_target(target_name) { + target_type = "component" + forward_variables_from(invoker, "*") + } +} + +set_defaults("jumbo_component") { + # This sets the default list of configs when the jumbo_component + # target is defined. This code is a clone of set_defaults for the + # ordinary "component" template. + if (is_component_build) { + configs = default_shared_library_configs + if (is_android) { + configs -= [ "//build/config/android:hide_all_but_jni_onload" ] + } + } else { + configs = default_compiler_configs + } +} diff --git a/chromium/build/config/merge_for_jumbo.py b/chromium/build/config/merge_for_jumbo.py new file mode 100755 index 00000000000..6d037a80eb6 --- /dev/null +++ b/chromium/build/config/merge_for_jumbo.py @@ -0,0 +1,145 @@ +#!/usr/bin/env python +# +# Copyright 2016 The Chromium Authors. All rights reserved. +# Use of this source code is governed by a BSD-style license that can be +# found in the LICENSE file. + +"""This script creates a "jumbo" file which merges all incoming files +for compiling. + +""" + +from __future__ import print_function +from __future__ import unicode_literals + +import argparse +import hashlib +import io +import os + +def cut_ranges(boundaries): + # Given an increasing sequence of boundary indices, generate a sequence of + # non-overlapping ranges. The total range is inclusive of the first index + # and exclusive of the last index from the given sequence. + for start, stop in zip(boundaries, boundaries[1:]): + yield range(start, stop) + + +def generate_chunk_stops(inputs, output_count, smart_merge=True): + # Note: In the comments below, unique numeric labels are assigned to files. + # Consider them as the sorted rank of the hash of each file path. + # Simple jumbo chunking generates uniformly sized chunks with the ceiling of: + # (output_index + 1) * input_count / output_count + input_count = len(inputs) + stops = [((i + 1) * input_count + output_count - 1) // output_count + for i in range(output_count)] + # This is disruptive at times because file insertions and removals can + # invalidate many chunks as all files are offset by one. + # For example, say we have 12 files in 4 uniformly sized chunks: + # 9, 4, 0; 7, 1, 11; 5, 10, 2; 6, 3, 8 + # If we delete the first file we get: + # 4, 0, 7; 1, 11, 5; 10, 2, 6; 3, 8 + # All of the chunks have new sets of inputs. + + # With path-aware chunking, we start with the uniformly sized chunks: + # 9, 4, 0; 7, 1, 11; 5, 10, 2; 6, 3, 8 + # First we find the smallest rank in each of the chunks. Their indices are + # stored in the |centers| list and in this example the ranks would be: + # 0, 1, 2, 3 + # Then we find the largest rank between the centers. Their indices are stored + # in the |stops| list and in this example the ranks would be: + # 7, 11, 6 + # These files mark the boundaries between chunks and these boundary files are + # often maintained even as files are added or deleted. + # In this example, 7, 11, and 6 are the first files in each chunk: + # 9, 4, 0; 7, 1; 11, 5, 10, 2; 6, 3, 8 + # If we delete the first file and repeat the process we get: + # 4, 0; 7, 1; 11, 5, 10, 2; 6, 3, 8 + # Only the first chunk has a new set of inputs. + if smart_merge: + # Starting with the simple chunks, every file is assigned a rank. + # This requires a hash function that is stable across runs. + hasher = lambda n: hashlib.md5(inputs[n].encode()).hexdigest() + # In each chunk there is a key file with lowest rank; mark them. + # Note that they will not easily change. + centers = [min(indices, key=hasher) for indices in cut_ranges([0] + stops)] + # Between each pair of key files there is a file with highest rank. + # Mark these to be used as border files. They also will not easily change. + # Forget the inital chunks and create new chunks by splitting the list at + # every border file. + stops = [max(indices, key=hasher) for indices in cut_ranges(centers)] + stops.append(input_count) + return stops + + +def write_jumbo_files(inputs, outputs, written_input_set, written_output_set): + chunk_stops = generate_chunk_stops(inputs, len(outputs)) + + written_inputs = 0 + for output_index, output_file in enumerate(outputs): + written_output_set.add(output_file) + if os.path.isfile(output_file): + with open(output_file, "r") as current: + current_jumbo_file = current.read() + else: + current_jumbo_file = None + + out = io.StringIO() + out.write("/* This is a Jumbo file. Don't edit. */\n\n") + out.write("/* Generated with merge_for_jumbo.py. */\n\n") + input_limit = chunk_stops[output_index] + while written_inputs < input_limit: + filename = inputs[written_inputs] + written_inputs += 1 + out.write("#include \"%s\"\n" % filename) + written_input_set.add(filename) + new_jumbo_file = out.getvalue() + out.close() + + if new_jumbo_file != current_jumbo_file: + with open(output_file, "w") as out: + out.write(new_jumbo_file) + + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument("--outputs", nargs="+", required=True, + help='List of output files to split input into') + parser.add_argument("--file-list", required=True) + parser.add_argument("--verbose", action="store_true") + args = parser.parse_args() + + lines = [] + # If written with gn |write_file| each file is on its own line. + with open(args.file_list) as file_list_file: + lines = [line.strip() for line in file_list_file if line.strip()] + # If written with gn |response_file_contents| the files are space separated. + all_inputs = [] + for line in lines: + all_inputs.extend(line.split()) + + written_output_set = set() # Just for double checking + written_input_set = set() # Just for double checking + for language_ext in (".cc", ".c", ".mm",): + if language_ext == ".cc": + ext_pattern = (".cc", ".cpp") + else: + ext_pattern = tuple([language_ext]) + + outputs = [x for x in args.outputs if x.endswith(ext_pattern)] + inputs = [x for x in all_inputs if x.endswith(ext_pattern)] + + if not outputs: + assert not inputs + continue + + write_jumbo_files(inputs, outputs, written_input_set, written_output_set) + + assert set(args.outputs) == written_output_set, "Did not fill all outputs" + assert set(all_inputs) == written_input_set, "Did not use all inputs" + if args.verbose: + print("Generated %s (%d files) based on %s" % ( + str(args.outputs), len(written_input_set), args.file_list)) + +if __name__ == "__main__": + main() diff --git a/chromium/cc/cc.gni b/chromium/cc/cc.gni index 4f1ba6ad82e..36b576f2aa1 100644 --- a/chromium/cc/cc.gni +++ b/chromium/cc/cc.gni @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//testing/test.gni") cc_remove_configs = [] @@ -17,7 +18,7 @@ if (!is_debug) { } template("cc_component") { - component(target_name) { + jumbo_component(target_name) { forward_variables_from(invoker, "*", [ "configs" ]) if (defined(invoker.configs)) { configs += invoker.configs @@ -28,7 +29,7 @@ template("cc_component") { } template("cc_test_static_library") { - static_library(target_name) { + jumbo_static_library(target_name) { forward_variables_from(invoker, "*", [ "configs" ]) if (defined(invoker.configs)) { configs += invoker.configs diff --git a/chromium/components/autofill/content/browser/BUILD.gn b/chromium/components/autofill/content/browser/BUILD.gn index 2cb8cb1f316..3904978613e 100644 --- a/chromium/components/autofill/content/browser/BUILD.gn +++ b/chromium/components/autofill/content/browser/BUILD.gn @@ -2,9 +2,10 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//third_party/protobuf/proto_library.gni") -static_library("browser") { +jumbo_static_library("browser") { sources = [ "autofill_log_router_factory.cc", "autofill_log_router_factory.h", diff --git a/chromium/components/autofill/content/browser/webauthn/BUILD.gn b/chromium/components/autofill/content/browser/webauthn/BUILD.gn index c1759f36cd9..bd8977e1308 100644 --- a/chromium/components/autofill/content/browser/webauthn/BUILD.gn +++ b/chromium/components/autofill/content/browser/webauthn/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -static_library("webauthn") { +import("//build/config/jumbo.gni") + +jumbo_static_library("webauthn") { if (is_component_build) { check_includes = false } diff --git a/chromium/components/autofill/content/renderer/BUILD.gn b/chromium/components/autofill/content/renderer/BUILD.gn index 84f03d8aec7..16498b7e7d8 100644 --- a/chromium/components/autofill/content/renderer/BUILD.gn +++ b/chromium/components/autofill/content/renderer/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -static_library("renderer") { +import("//build/config/jumbo.gni") + +jumbo_static_library("renderer") { sources = [ "autofill_agent.cc", "autofill_agent.h", @@ -59,7 +61,7 @@ static_library("renderer") { configs += [ "//build/config/compiler:no_size_t_to_int_warning" ] } -static_library("test_support") { +jumbo_static_library("test_support") { testonly = true sources = [ "focus_test_utils.cc", diff --git a/chromium/components/autofill/core/browser/BUILD.gn b/chromium/components/autofill/core/browser/BUILD.gn index f47429dd1ac..439a6738fdc 100644 --- a/chromium/components/autofill/core/browser/BUILD.gn +++ b/chromium/components/autofill/core/browser/BUILD.gn @@ -3,6 +3,7 @@ # found in the LICENSE file. import("//build/config/chrome_build.gni") +import("//build/config/jumbo.gni") import("//build/util/version.gni") import("//testing/libfuzzer/fuzzer_test.gni") import("//tools/grit/grit_rule.gni") @@ -29,7 +30,7 @@ action("default_regex_patterns_cc") { outputs = [ "$target_gen_dir/pattern_provider/default_regex_patterns.cc" ] } -static_library("browser") { +jumbo_static_library("browser") { sources = [ "address_normalization_manager.cc", "address_normalization_manager.h", @@ -484,7 +485,7 @@ static_library("browser") { configs += [ "//build/config/compiler:no_size_t_to_int_warning" ] } -static_library("test_support") { +jumbo_static_library("test_support") { testonly = true sources = [ "autofill_form_test_utils.cc", diff --git a/chromium/components/autofill/core/common/BUILD.gn b/chromium/components/autofill/core/common/BUILD.gn index 637d7e77754..fa03af7f4fc 100644 --- a/chromium/components/autofill/core/common/BUILD.gn +++ b/chromium/components/autofill/core/common/BUILD.gn @@ -1,8 +1,9 @@ # Copyright 2014 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") -static_library("common") { +jumbo_static_library("common") { sources = [ "autofill_clock.cc", "autofill_clock.h", diff --git a/chromium/components/autofill_assistant/browser/BUILD.gn b/chromium/components/autofill_assistant/browser/BUILD.gn index 7498c5f33dd..83914581af3 100644 --- a/chromium/components/autofill_assistant/browser/BUILD.gn +++ b/chromium/components/autofill_assistant/browser/BUILD.gn @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD - style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//third_party/protobuf/proto_library.gni") if (is_android) { @@ -20,7 +21,7 @@ proto_library("proto") { ] } -static_library("browser") { +jumbo_static_library("browser") { sources = [ "actions/action.cc", "actions/action.h", diff --git a/chromium/components/cast_certificate/BUILD.gn b/chromium/components/cast_certificate/BUILD.gn index 2e67a689662..2eba37a5348 100644 --- a/chromium/components/cast_certificate/BUILD.gn +++ b/chromium/components/cast_certificate/BUILD.gn @@ -2,6 +2,8 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") + declare_args() { # Allow use of custom Cast root certificate for authentication. cast_allow_developer_certificate = false @@ -14,7 +16,7 @@ config("certificate_config") { } } -source_set("cast_certificate_reader") { +jumbo_source_set("cast_certificate_reader") { sources = [ "cast_cert_reader.cc", "cast_cert_reader.h", @@ -25,7 +27,7 @@ source_set("cast_certificate_reader") { ] } -static_library("cast_certificate") { +jumbo_static_library("cast_certificate") { sources = [ "cast_cert_validator.cc", "cast_cert_validator.h", @@ -53,7 +55,7 @@ static_library("cast_certificate") { } } -static_library("test_support") { +jumbo_static_library("test_support") { testonly = true sources = [ "cast_cert_test_helpers.cc", @@ -69,7 +71,7 @@ static_library("test_support") { ] } -source_set("unit_tests") { +jumbo_source_set("unit_tests") { testonly = true sources = [ "cast_cert_validator_unittest.cc", diff --git a/chromium/components/cdm/browser/BUILD.gn b/chromium/components/cdm/browser/BUILD.gn index 1b1c7858b2a..c38eb34ea80 100644 --- a/chromium/components/cdm/browser/BUILD.gn +++ b/chromium/components/cdm/browser/BUILD.gn @@ -2,10 +2,11 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//media/media_options.gni") if (enable_media_drm_storage) { - source_set("browser") { + jumbo_source_set("browser") { sources = [ "media_drm_storage_impl.cc", "media_drm_storage_impl.h", @@ -37,7 +38,7 @@ if (enable_media_drm_storage) { } } - source_set("unit_tests") { + jumbo_source_set("unit_tests") { testonly = true sources = [ "media_drm_storage_impl_unittest.cc" ] deps = [ diff --git a/chromium/components/cdm/common/BUILD.gn b/chromium/components/cdm/common/BUILD.gn index 5944fb78ad7..dce0d77bcdb 100644 --- a/chromium/components/cdm/common/BUILD.gn +++ b/chromium/components/cdm/common/BUILD.gn @@ -1,10 +1,11 @@ # Copyright 2014 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//third_party/widevine/cdm/widevine.gni") -static_library("common") { +jumbo_static_library("common") { sources = [ "cdm_message_generator.cc", "cdm_message_generator.h", diff --git a/chromium/components/cdm/renderer/BUILD.gn b/chromium/components/cdm/renderer/BUILD.gn index cdd7d8edaf3..38091aba684 100644 --- a/chromium/components/cdm/renderer/BUILD.gn +++ b/chromium/components/cdm/renderer/BUILD.gn @@ -2,9 +2,10 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//third_party/widevine/cdm/widevine.gni") -static_library("renderer") { +jumbo_static_library("renderer") { sources = [ "external_clear_key_key_system_properties.cc", "external_clear_key_key_system_properties.h", diff --git a/chromium/components/content_settings/core/browser/BUILD.gn b/chromium/components/content_settings/core/browser/BUILD.gn index 764c726b988..d41e0d398ad 100644 --- a/chromium/components/content_settings/core/browser/BUILD.gn +++ b/chromium/components/content_settings/core/browser/BUILD.gn @@ -3,9 +3,10 @@ # found in the LICENSE file. import("//build/config/features.gni") +import("//build/config/jumbo.gni") import("//ppapi/buildflags/buildflags.gni") -static_library("browser") { +jumbo_static_library("browser") { sources = [ "content_settings_default_provider.cc", "content_settings_default_provider.h", @@ -89,7 +90,7 @@ static_library("browser") { ] } -source_set("unit_tests") { +jumbo_source_set("unit_tests") { testonly = true sources = [ "content_settings_pref_unittest.cc", diff --git a/chromium/components/content_settings/core/common/BUILD.gn b/chromium/components/content_settings/core/common/BUILD.gn index 84bf57a2f77..394460a6d03 100644 --- a/chromium/components/content_settings/core/common/BUILD.gn +++ b/chromium/components/content_settings/core/common/BUILD.gn @@ -2,10 +2,11 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//mojo/public/tools/bindings/mojom.gni") import("//testing/libfuzzer/fuzzer_test.gni") -static_library("common") { +jumbo_static_library("common") { sources = [ "content_settings.cc", "content_settings.h", @@ -43,7 +44,7 @@ static_library("common") { ] } -source_set("unit_tests") { +jumbo_source_set("unit_tests") { testonly = true sources = [ "content_settings_pattern_parser_unittest.cc", diff --git a/chromium/components/content_settings/core/test/BUILD.gn b/chromium/components/content_settings/core/test/BUILD.gn index 46e2fd8cfff..64fb832ac5a 100644 --- a/chromium/components/content_settings/core/test/BUILD.gn +++ b/chromium/components/content_settings/core/test/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -static_library("test_support") { +import("//build/config/jumbo.gni") + +jumbo_static_library("test_support") { testonly = true sources = [ "content_settings_mock_provider.cc", diff --git a/chromium/components/domain_reliability/BUILD.gn b/chromium/components/domain_reliability/BUILD.gn index 175e908c274..12086792260 100644 --- a/chromium/components/domain_reliability/BUILD.gn +++ b/chromium/components/domain_reliability/BUILD.gn @@ -2,6 +2,8 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") + action("bake_in_configs") { visibility = [ ":*" ] script = "bake_in_configs.py" @@ -43,7 +45,7 @@ action("bake_in_configs") { ] } -component("domain_reliability") { +jumbo_component("domain_reliability") { sources = [ "baked_in_configs.h", "beacon.cc", @@ -85,7 +87,7 @@ component("domain_reliability") { ] } -source_set("unit_tests") { +jumbo_source_set("unit_tests") { testonly = true sources = [ "config_unittest.cc", diff --git a/chromium/components/feature_engagement/internal/BUILD.gn b/chromium/components/feature_engagement/internal/BUILD.gn index 1aedb7269e3..8a559eceaff 100644 --- a/chromium/components/feature_engagement/internal/BUILD.gn +++ b/chromium/components/feature_engagement/internal/BUILD.gn @@ -2,12 +2,14 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") + if (is_android) { import("//build/config/android/config.gni") import("//build/config/android/rules.gni") } -static_library("internal") { +jumbo_static_library("internal") { visibility = [ ":*", "//components/feature_engagement", @@ -84,7 +86,7 @@ static_library("internal") { } } -source_set("unit_tests") { +jumbo_source_set("unit_tests") { testonly = true visibility = [ "//components/feature_engagement:unit_tests" ] diff --git a/chromium/components/feature_engagement/internal/test/BUILD.gn b/chromium/components/feature_engagement/internal/test/BUILD.gn index 961c1f6066b..5c9e7a1c2be 100644 --- a/chromium/components/feature_engagement/internal/test/BUILD.gn +++ b/chromium/components/feature_engagement/internal/test/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -source_set("test_support") { +import("//build/config/jumbo.gni") + +jumbo_source_set("test_support") { testonly = true visibility = [ "//components/feature_engagement/internal:unit_tests" ] diff --git a/chromium/components/feature_engagement/public/BUILD.gn b/chromium/components/feature_engagement/public/BUILD.gn index f458072d849..02f1edb8c1e 100644 --- a/chromium/components/feature_engagement/public/BUILD.gn +++ b/chromium/components/feature_engagement/public/BUILD.gn @@ -2,12 +2,14 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") + if (is_android) { import("//build/config/android/config.gni") import("//build/config/android/rules.gni") } -source_set("public") { +jumbo_source_set("public") { sources = [ "configuration.cc", "configuration.h", @@ -40,7 +42,7 @@ source_set("public") { } } -source_set("unit_tests") { +jumbo_source_set("unit_tests") { testonly = true visibility = [ "//components/feature_engagement:unit_tests" ] diff --git a/chromium/components/lookalikes/core/BUILD.gn b/chromium/components/lookalikes/core/BUILD.gn index c46ad6f7e1d..602dc1105b5 100644 --- a/chromium/components/lookalikes/core/BUILD.gn +++ b/chromium/components/lookalikes/core/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -static_library("core") { +import("//build/config/jumbo.gni") + +jumbo_static_library("core") { sources = [ "lookalike_url_ui_util.cc", "lookalike_url_ui_util.h", @@ -31,7 +33,7 @@ static_library("core") { ] } -source_set("unit_tests") { +jumbo_source_set("unit_tests") { testonly = true sources = [ "lookalike_url_util_unittest.cc" ] diff --git a/chromium/components/metrics/BUILD.gn b/chromium/components/metrics/BUILD.gn index 4978a1dc3a1..eece9507182 100644 --- a/chromium/components/metrics/BUILD.gn +++ b/chromium/components/metrics/BUILD.gn @@ -3,13 +3,30 @@ # found in the LICENSE file. import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//testing/test.gni") if (is_android) { import("//build/config/android/rules.gni") } -static_library("metrics") { +jumbo_static_library("demographic_metrics_provider") { + sources = [ + "demographic_metrics_provider.cc", + "demographic_metrics_provider.h", + ] + + public_deps = [ "//third_party/metrics_proto" ] + + deps = [ + ":metrics", + "//base", + "//components/sync/base", + "//components/sync/driver", + ] +} + +jumbo_static_library("metrics") { sources = [ "android_metrics_provider.cc", "android_metrics_provider.h", @@ -253,7 +270,7 @@ source_set("library_support") { ] } -static_library("net") { +jumbo_static_library("net") { sources = [ "net/cellular_logic_helper.cc", "net/cellular_logic_helper.h", @@ -370,7 +387,7 @@ source_set("call_stack_profile_collector") { ] } -static_library("test_support") { +jumbo_static_library("test_support") { testonly = true sources = [ "test/test_enabled_state_provider.cc", diff --git a/chromium/components/omnibox/browser/BUILD.gn b/chromium/components/omnibox/browser/BUILD.gn index 43035485af8..00f11337b03 100644 --- a/chromium/components/omnibox/browser/BUILD.gn +++ b/chromium/components/omnibox/browser/BUILD.gn @@ -3,6 +3,7 @@ # found in the LICENSE file. import("//build/buildflag_header.gni") +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//components/vector_icons/vector_icons.gni") import("//device/vr/buildflags/buildflags.gni") @@ -81,7 +82,7 @@ static_library("vector_icons") { ] } -static_library("browser") { +jumbo_static_library("browser") { sources = [ "actions/omnibox_action.cc", "actions/omnibox_action.h", @@ -422,7 +423,7 @@ proto_library("in_memory_url_index_cache_proto") { sources = [ "in_memory_url_index_cache.proto" ] } -static_library("test_support") { +jumbo_static_library("test_support") { testonly = true sources = [ "fake_autocomplete_provider_client.cc", diff --git a/chromium/components/password_manager/content/browser/BUILD.gn b/chromium/components/password_manager/content/browser/BUILD.gn index b56fd7e5fe6..2a6c0ee268b 100644 --- a/chromium/components/password_manager/content/browser/BUILD.gn +++ b/chromium/components/password_manager/content/browser/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -static_library("browser") { +import("//build/config/jumbo.gni") + +jumbo_static_library("browser") { sources = [ "bad_message.cc", "bad_message.h", diff --git a/chromium/components/password_manager/core/browser/BUILD.gn b/chromium/components/password_manager/core/browser/BUILD.gn index 191727cca74..e97b2def51e 100644 --- a/chromium/components/password_manager/core/browser/BUILD.gn +++ b/chromium/components/password_manager/core/browser/BUILD.gn @@ -3,6 +3,7 @@ # found in the LICENSE file. import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//testing/libfuzzer/fuzzer_test.gni") import("//third_party/libprotobuf-mutator/fuzzable_proto_library.gni") @@ -17,7 +18,7 @@ config("password_reuse_detection_config") { } } -static_library("browser") { +jumbo_static_library("browser") { sources = [ "android_affiliation/affiliated_match_helper.cc", "android_affiliation/affiliated_match_helper.h", @@ -449,7 +450,7 @@ fuzzable_proto_library("proto") { sources = [ "android_affiliation/affiliation_api.proto" ] } -static_library("password_hash_data") { +jumbo_static_library("password_hash_data") { sources = [ "password_hash_data.cc", "password_hash_data.h", @@ -475,7 +476,7 @@ static_library("hash_password_manager") { ] } -static_library("test_support") { +jumbo_static_library("test_support") { testonly = true sources = [ "android_affiliation/fake_affiliation_api.cc", diff --git a/chromium/components/password_manager/core/browser/leak_detection/BUILD.gn b/chromium/components/password_manager/core/browser/leak_detection/BUILD.gn index c72439b557c..47a62febd02 100644 --- a/chromium/components/password_manager/core/browser/leak_detection/BUILD.gn +++ b/chromium/components/password_manager/core/browser/leak_detection/BUILD.gn @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//third_party/libprotobuf-mutator/fuzzable_proto_library.gni") fuzzable_proto_library("proto") { @@ -21,7 +22,7 @@ source_set("leak_detection_interface_headers") { ] } -source_set("leak_detection") { +jumbo_source_set("leak_detection") { sources = [ "authenticated_leak_check.cc", "authenticated_leak_check.h", @@ -59,7 +60,7 @@ source_set("leak_detection") { ] } -source_set("test_support") { +jumbo_source_set("test_support") { testonly = true sources = [ "mock_leak_detection_check_factory.cc", @@ -77,7 +78,7 @@ source_set("test_support") { ] } -source_set("unit_tests") { +jumbo_source_set("unit_tests") { testonly = true sources = [ "authenticated_leak_check_unittest.cc", diff --git a/chromium/components/password_manager/core/common/BUILD.gn b/chromium/components/password_manager/core/common/BUILD.gn index f636d815ccd..311d8e0f4c3 100644 --- a/chromium/components/password_manager/core/common/BUILD.gn +++ b/chromium/components/password_manager/core/common/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -static_library("common") { +import("//build/config/jumbo.gni") + +jumbo_static_library("common") { sources = [ "credential_manager_types.cc", "credential_manager_types.h", diff --git a/chromium/components/payments/content/BUILD.gn b/chromium/components/payments/content/BUILD.gn index 382995bdd98..d39678cf82e 100644 --- a/chromium/components/payments/content/BUILD.gn +++ b/chromium/components/payments/content/BUILD.gn @@ -3,8 +3,9 @@ # found in the LICENSE file. import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") -static_library("content") { +jumbo_static_library("content") { sources = [ "android_app_communication.cc", "android_app_communication.h", @@ -129,7 +130,7 @@ static_library("content") { } # Files used by content and utility. -static_library("content_common") { +jumbo_static_library("content_common") { sources = [ "web_app_manifest.cc", "web_app_manifest.h", @@ -141,7 +142,7 @@ static_library("content_common") { ] } -static_library("utils") { +jumbo_static_library("utils") { sources = [ "developer_console_logger.cc", "developer_console_logger.h", @@ -188,7 +189,7 @@ static_library("utils") { ] } -source_set("unit_tests") { +jumbo_source_set("unit_tests") { testonly = true sources = [ "android_app_communication_test_support.h", diff --git a/chromium/components/payments/content/icon/BUILD.gn b/chromium/components/payments/content/icon/BUILD.gn index a5d3326f4c3..b031c0b8bd1 100644 --- a/chromium/components/payments/content/icon/BUILD.gn +++ b/chromium/components/payments/content/icon/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -static_library("icon") { +import("//build/config/jumbo.gni") + +jumbo_static_library("icon") { sources = [ "icon_size.cc", "icon_size.h", diff --git a/chromium/components/payments/core/BUILD.gn b/chromium/components/payments/core/BUILD.gn index b53b94aec9a..b1aa17feb9a 100644 --- a/chromium/components/payments/core/BUILD.gn +++ b/chromium/components/payments/core/BUILD.gn @@ -3,8 +3,9 @@ # found in the LICENSE file. import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") -static_library("core") { +jumbo_static_library("core") { sources = [ "android_app_description.cc", "android_app_description.h", @@ -106,7 +107,7 @@ static_library("core") { ] } -static_library("error_strings") { +jumbo_static_library("error_strings") { sources = [ "error_strings.cc", "error_strings.h", @@ -122,14 +123,14 @@ static_library("error_strings") { } } -static_library("method_strings") { +jumbo_static_library("method_strings") { sources = [ "method_strings.cc", "method_strings.h", ] } -static_library("test_support") { +jumbo_static_library("test_support") { testonly = true sources = [ "payments_test_util.cc", @@ -155,7 +156,7 @@ static_library("test_support") { ] } -source_set("unit_tests") { +jumbo_source_set("unit_tests") { testonly = true sources = [ "android_app_description_tools_unittest.cc", diff --git a/chromium/components/policy/content/BUILD.gn b/chromium/components/policy/content/BUILD.gn index 2709062c39b..4be7dc11ba0 100644 --- a/chromium/components/policy/content/BUILD.gn +++ b/chromium/components/policy/content/BUILD.gn @@ -3,10 +3,11 @@ # found in the LICENSE file. import("//build/config/features.gni") +import("//build/config/jumbo.gni") assert(!is_ios, "Policy Throttle should not be referenced on iOS") -source_set("safe_sites_navigation_throttle") { +jumbo_source_set("safe_sites_navigation_throttle") { sources = [ "safe_search_service.cc", "safe_search_service.h", @@ -25,7 +26,7 @@ source_set("safe_sites_navigation_throttle") { ] } -source_set("content") { +jumbo_source_set("content") { sources = [ "policy_blocklist_navigation_throttle.cc", "policy_blocklist_navigation_throttle.h", diff --git a/chromium/components/policy/core/browser/BUILD.gn b/chromium/components/policy/core/browser/BUILD.gn index 0e8afdd3711..84dee424263 100644 --- a/chromium/components/policy/core/browser/BUILD.gn +++ b/chromium/components/policy/core/browser/BUILD.gn @@ -3,6 +3,7 @@ # found in the LICENSE file. import("//build/config/features.gni") +import("//build/config/jumbo.gni") group("browser") { if (is_component_build) { @@ -12,7 +13,7 @@ group("browser") { } } -source_set("internal") { +jumbo_source_set("internal") { visibility = [ "//components/policy/*" ] sources = [ "browser_policy_connector.cc", @@ -87,7 +88,7 @@ source_set("internal") { ] } -static_library("test_support") { +jumbo_static_library("test_support") { testonly = true sources = [ "configuration_policy_pref_store_test.cc", diff --git a/chromium/components/policy/core/common/BUILD.gn b/chromium/components/policy/core/common/BUILD.gn index 10290f8679e..e80b996374f 100644 --- a/chromium/components/policy/core/common/BUILD.gn +++ b/chromium/components/policy/core/common/BUILD.gn @@ -4,6 +4,7 @@ import("//build/config/chromeos/ui_mode.gni") import("//build/config/features.gni") +import("//build/config/jumbo.gni") import("//testing/libfuzzer/fuzzer_test.gni") group("common") { @@ -14,7 +15,7 @@ group("common") { } } -source_set("internal") { +jumbo_source_set("internal") { visibility = [ "//components/policy/*" ] configs += [ "//components/policy:component_implementation" ] @@ -317,7 +318,7 @@ source_set("internal") { } } -static_library("test_support") { +jumbo_static_library("test_support") { testonly = true sources = [ "cloud/mock_cloud_external_data_manager.cc", diff --git a/chromium/components/safe_browsing/content/browser/BUILD.gn b/chromium/components/safe_browsing/content/browser/BUILD.gn index 07f1106c731..c5063cb07da 100644 --- a/chromium/components/safe_browsing/content/browser/BUILD.gn +++ b/chromium/components/safe_browsing/content/browser/BUILD.gn @@ -3,8 +3,9 @@ # found in the LICENSE file. import("//build/config/features.gni") +import("//build/config/jumbo.gni") -source_set("browser") { +jumbo_source_set("browser") { sources = [ "browser_url_loader_throttle.cc", "browser_url_loader_throttle.h", diff --git a/chromium/components/safe_browsing/core/browser/BUILD.gn b/chromium/components/safe_browsing/core/browser/BUILD.gn index d76248ac19e..50e5882c5cf 100644 --- a/chromium/components/safe_browsing/core/browser/BUILD.gn +++ b/chromium/components/safe_browsing/core/browser/BUILD.gn @@ -3,8 +3,9 @@ # found in the LICENSE file. import("//build/config/features.gni") +import("//build/config/jumbo.gni") -source_set("browser") { +jumbo_source_set("browser") { sources = [ "safe_browsing_url_checker_impl.cc", "safe_browsing_url_checker_impl.h", diff --git a/chromium/components/security_state/content/BUILD.gn b/chromium/components/security_state/content/BUILD.gn index cb1077bff25..5f1da23e360 100644 --- a/chromium/components/security_state/content/BUILD.gn +++ b/chromium/components/security_state/content/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -static_library("content") { +import("//build/config/jumbo.gni") + +jumbo_static_library("content") { sources = [ "content_utils.cc", "content_utils.h", @@ -27,7 +29,7 @@ static_library("content") { ] } -source_set("unit_tests") { +jumbo_source_set("unit_tests") { testonly = true sources = [ "content_utils_unittest.cc" ] diff --git a/chromium/components/security_state/core/BUILD.gn b/chromium/components/security_state/core/BUILD.gn index c76ee426ba2..2b94065bcaa 100644 --- a/chromium/components/security_state/core/BUILD.gn +++ b/chromium/components/security_state/core/BUILD.gn @@ -2,12 +2,14 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") + if (is_android) { import("//build/config/android/config.gni") import("//build/config/android/rules.gni") } -static_library("core") { +jumbo_static_library("core") { sources = [ "insecure_input_event_data.h", "security_state.cc", @@ -35,7 +37,7 @@ if (is_android) { } } -source_set("unit_tests") { +jumbo_source_set("unit_tests") { testonly = true sources = [ "security_state_unittest.cc" ] diff --git a/chromium/components/sync/BUILD.gn b/chromium/components/sync/BUILD.gn index 8207fd988c4..72ec168df17 100644 --- a/chromium/components/sync/BUILD.gn +++ b/chromium/components/sync/BUILD.gn @@ -4,6 +4,7 @@ import("//build/config/chromeos/ui_mode.gni") import("//build/config/features.gni") +import("//build/config/jumbo.gni") import("//testing/test.gni") group("sync") { diff --git a/chromium/components/sync/base/BUILD.gn b/chromium/components/sync/base/BUILD.gn index 5877f47853b..5c48a48dc7d 100644 --- a/chromium/components/sync/base/BUILD.gn +++ b/chromium/components/sync/base/BUILD.gn @@ -4,13 +4,14 @@ import("//build/config/chromeos/ui_mode.gni") import("//build/config/features.gni") +import("//build/config/jumbo.gni") declare_args() { # Controls the product part of the user agent calculated in sync_util.cc. sync_user_agent_product = "Chrome" } -static_library("base") { +jumbo_static_library("base") { sources = [ "bind_to_task_runner.h", "client_tag_hash.cc", diff --git a/chromium/components/sync/driver/BUILD.gn b/chromium/components/sync/driver/BUILD.gn index 80ab10a408c..38b82709dab 100644 --- a/chromium/components/sync/driver/BUILD.gn +++ b/chromium/components/sync/driver/BUILD.gn @@ -4,8 +4,9 @@ import("//build/config/chromeos/ui_mode.gni") import("//build/config/features.gni") +import("//build/config/jumbo.gni") -static_library("driver") { +jumbo_static_library("driver") { sources = [ "active_devices_provider.h", "backend_migrator.cc", diff --git a/chromium/components/sync/js/BUILD.gn b/chromium/components/sync/js/BUILD.gn index 71ff7e8f2ec..53422e2b3bc 100644 --- a/chromium/components/sync/js/BUILD.gn +++ b/chromium/components/sync/js/BUILD.gn @@ -3,8 +3,9 @@ # found in the LICENSE file. import("//build/config/features.gni") +import("//build/config/jumbo.gni") -static_library("js") { +jumbo_static_library("js") { sources = [ "js_backend.h", "js_controller.h", diff --git a/chromium/components/sync/protocol/BUILD.gn b/chromium/components/sync/protocol/BUILD.gn index 64fd7082d5b..e3f1801d25e 100644 --- a/chromium/components/sync/protocol/BUILD.gn +++ b/chromium/components/sync/protocol/BUILD.gn @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//third_party/protobuf/proto_library.gni") import("protocol_sources.gni") @@ -15,7 +16,7 @@ proto_library("protocol") { # it being listed in public_deps of upper directories (even though it doesn't # fit the definition of public_deps). Consider using a group() to expose this # together with the "protocol" target and simplify things. -static_library("util") { +jumbo_static_library("util") { sources = [ "proto_enum_conversions.cc", "proto_enum_conversions.h", diff --git a/chromium/components/sync_device_info/BUILD.gn b/chromium/components/sync_device_info/BUILD.gn index 59c674cc649..56649899e48 100644 --- a/chromium/components/sync_device_info/BUILD.gn +++ b/chromium/components/sync_device_info/BUILD.gn @@ -4,8 +4,9 @@ import("//build/config/chromeos/ui_mode.gni") import("//build/config/features.gni") +import("//build/config/jumbo.gni") -static_library("sync_device_info") { +jumbo_static_library("sync_device_info") { sources = [ "device_count_metrics_provider.cc", "device_count_metrics_provider.h", diff --git a/chromium/components/sync_user_events/BUILD.gn b/chromium/components/sync_user_events/BUILD.gn index b19d743b5ee..1a42b228e5c 100644 --- a/chromium/components/sync_user_events/BUILD.gn +++ b/chromium/components/sync_user_events/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -static_library("sync_user_events") { +import("//build/config/jumbo.gni") + +jumbo_static_library("sync_user_events") { sources = [ "global_id_mapper.h", "no_op_user_event_service.cc", diff --git a/chromium/components/url_formatter/BUILD.gn b/chromium/components/url_formatter/BUILD.gn index 1992b274c29..a62d41dde0a 100644 --- a/chromium/components/url_formatter/BUILD.gn +++ b/chromium/components/url_formatter/BUILD.gn @@ -2,11 +2,13 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") + if (is_android) { import("//build/config/android/rules.gni") } -static_library("skeleton_generator") { +jumbo_static_library("skeleton_generator") { sources = [ "spoof_checks/skeleton_generator.cc", "spoof_checks/skeleton_generator.h", @@ -17,7 +19,7 @@ static_library("skeleton_generator") { ] } -static_library("url_formatter") { +jumbo_static_library("url_formatter") { sources = [ "elide_url.cc", "elide_url.h", @@ -67,7 +69,7 @@ if (is_android) { } } -source_set("unit_tests") { +jumbo_source_set("unit_tests") { testonly = true sources = [ "elide_url_unittest.cc", diff --git a/chromium/components/viz/common/BUILD.gn b/chromium/components/viz/common/BUILD.gn index 6869f9dedb6..1c02e8eeb02 100644 --- a/chromium/components/viz/common/BUILD.gn +++ b/chromium/components/viz/common/BUILD.gn @@ -359,6 +359,8 @@ viz_component("common") { } viz_source_set("unit_tests") { + # Not ready for jumbo compilation. Too much repeated test code. + never_build_jumbo = true testonly = true sources = [ "display/overlay_strategy_unittest.cc", diff --git a/chromium/components/viz/service/BUILD.gn b/chromium/components/viz/service/BUILD.gn index 838a44f26f0..597f86bcf8b 100644 --- a/chromium/components/viz/service/BUILD.gn +++ b/chromium/components/viz/service/BUILD.gn @@ -522,6 +522,8 @@ viz_source_set("gpu_service_dependencies") { } viz_source_set("unit_tests") { + # Not ready for jumbo compilation. Too much repeated test code. + never_build_jumbo = true testonly = true sources = [ "debugger/viz_debugger_unittest.cc", @@ -669,6 +671,8 @@ viz_source_set("unit_tests") { } viz_source_set("perf_tests") { + # Not ready for jumbo compilation. Too much repeated test code. + never_build_jumbo = true testonly = true sources = [ "display/bsp_tree_perftest.cc", diff --git a/chromium/components/viz/viz.gni b/chromium/components/viz/viz.gni index 7f3d160442b..22d05d97bd7 100644 --- a/chromium/components/viz/viz.gni +++ b/chromium/components/viz/viz.gni @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//gpu/vulkan/features.gni") import("//skia/features.gni") import("//testing/test.gni") @@ -29,7 +30,7 @@ if (!is_debug) { } template("viz_source_set") { - source_set(target_name) { + jumbo_source_set(target_name) { forward_variables_from(invoker, "*", [ "configs" ]) if (defined(invoker.configs)) { configs += invoker.configs @@ -40,7 +41,7 @@ template("viz_source_set") { } template("viz_component") { - component(target_name) { + jumbo_component(target_name) { forward_variables_from(invoker, "*", [ "configs" ]) if (defined(invoker.configs)) { configs += invoker.configs @@ -51,7 +52,7 @@ template("viz_component") { } template("viz_static_library") { - static_library(target_name) { + jumbo_static_library(target_name) { forward_variables_from(invoker, "*", [ "configs" ]) if (defined(invoker.configs)) { configs += invoker.configs diff --git a/chromium/components/wifi/BUILD.gn b/chromium/components/wifi/BUILD.gn index a5f1d3d07e5..b424914b12f 100644 --- a/chromium/components/wifi/BUILD.gn +++ b/chromium/components/wifi/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -component("wifi") { +import("//build/config/jumbo.gni") + +jumbo_component("wifi") { sources = [ "network_properties.cc", "network_properties.h", @@ -38,7 +40,7 @@ component("wifi") { } } -static_library("test_support") { +jumbo_static_library("test_support") { sources = [ "fake_wifi_service.cc", "fake_wifi_service.h", diff --git a/chromium/content/browser/BUILD.gn b/chromium/content/browser/BUILD.gn index df70a130b92..4e4afdd4281 100644 --- a/chromium/content/browser/BUILD.gn +++ b/chromium/content/browser/BUILD.gn @@ -6,6 +6,7 @@ import("//build/buildflag_header.gni") import("//build/config/chromeos/ui_mode.gni") import("//build/config/chromeos/ui_mode.gni") import("//build/config/features.gni") +import("//build/config/jumbo.gni") import("//build/config/linux/pangocairo/pangocairo.gni") import("//build/config/ozone.gni") import("//build/config/ui.gni") @@ -23,7 +24,7 @@ import("//printing/buildflags/buildflags.gni") import("//third_party/blink/public/public_features.gni") import("//tools/ipc_fuzzer/ipc_fuzzer.gni") -static_library("browser") { +jumbo_static_library("browser") { # Only the public target should depend on this. All other targets (even # internal content ones) should depend on the public one. visibility = [ diff --git a/chromium/content/gpu/BUILD.gn b/chromium/content/gpu/BUILD.gn index e777cefe7f4..941e9419000 100644 --- a/chromium/content/gpu/BUILD.gn +++ b/chromium/content/gpu/BUILD.gn @@ -3,6 +3,7 @@ # found in the LICENSE file. import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//gpu/vulkan/features.gni") import("//media/media_options.gni") @@ -19,9 +20,9 @@ group("gpu") { } if (is_component_build) { - link_target_type = "source_set" + link_target_type = "jumbo_source_set" } else { - link_target_type = "static_library" + link_target_type = "jumbo_static_library" } target(link_target_type, "gpu_sources") { diff --git a/chromium/content/public/browser/BUILD.gn b/chromium/content/public/browser/BUILD.gn index 996cb480c37..ccbb7a20419 100644 --- a/chromium/content/public/browser/BUILD.gn +++ b/chromium/content/public/browser/BUILD.gn @@ -3,6 +3,7 @@ # found in the LICENSE file. import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//device/vr/buildflags/buildflags.gni") import("//media/media_options.gni") @@ -23,7 +24,7 @@ group("browser") { } } -source_set("browser_sources") { +jumbo_source_set("browser_sources") { # External code should depend on via ":browser" above. visibility = [ "//content/*" ] sources = [ diff --git a/chromium/content/public/child/BUILD.gn b/chromium/content/public/child/BUILD.gn index 1f62f066738..d21a09ec8e1 100644 --- a/chromium/content/public/child/BUILD.gn +++ b/chromium/content/public/child/BUILD.gn @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//ppapi/buildflags/buildflags.gni") # See //content/BUILD.gn for how this works. @@ -19,7 +20,7 @@ group("child") { } } -source_set("child_sources") { +jumbo_source_set("child_sources") { # External code should depend in via ":child" above. visibility = [ "//content/*" ] diff --git a/chromium/content/public/common/BUILD.gn b/chromium/content/public/common/BUILD.gn index 3e51504127d..818226296ad 100644 --- a/chromium/content/public/common/BUILD.gn +++ b/chromium/content/public/common/BUILD.gn @@ -6,6 +6,7 @@ import("//build/buildflag_header.gni") import("//build/config/chromecast_build.gni") import("//build/config/chromeos/ui_mode.gni") import("//build/config/features.gni") +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//content/public/common/zygote/features.gni") import("//media/media_options.gni") @@ -91,7 +92,7 @@ source_set("static_features") { } } -source_set("common_sources") { +jumbo_source_set("common_sources") { # External code should depend on via ":common" above. visibility = [ "//content/*" ] diff --git a/chromium/content/public/renderer/BUILD.gn b/chromium/content/public/renderer/BUILD.gn index bbd91406de7..1e9a0dc1530 100644 --- a/chromium/content/public/renderer/BUILD.gn +++ b/chromium/content/public/renderer/BUILD.gn @@ -3,6 +3,7 @@ # found in the LICENSE file. import("//build/config/features.gni") +import("//build/config/jumbo.gni") import("//media/media_options.gni") import("//ppapi/buildflags/buildflags.gni") @@ -16,9 +17,9 @@ group("renderer") { } if (is_component_build) { - link_target_type = "source_set" + link_target_type = "jumbo_source_set" } else { - link_target_type = "static_library" + link_target_type = "jumbo_static_library" } target(link_target_type, "renderer_sources") { # External code should depend on via ":renderer" above. diff --git a/chromium/content/renderer/BUILD.gn b/chromium/content/renderer/BUILD.gn index d2116797bdb..ef97569719a 100644 --- a/chromium/content/renderer/BUILD.gn +++ b/chromium/content/renderer/BUILD.gn @@ -5,6 +5,7 @@ import("//build/config/chromecast_build.gni") import("//build/config/chromeos/ui_mode.gni") import("//build/config/features.gni") +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//content/common/features.gni") import("//media/media_options.gni") @@ -14,9 +15,9 @@ import("//third_party/webrtc/webrtc.gni") import("//tools/ipc_fuzzer/ipc_fuzzer.gni") if (is_component_build) { - link_target_type = "source_set" + link_target_type = "jumbo_source_set" } else { - link_target_type = "static_library" + link_target_type = "jumbo_static_library" } target(link_target_type, "renderer") { diff --git a/chromium/content/test/BUILD.gn b/chromium/content/test/BUILD.gn index 0fb2308cb64..bf1fab03cac 100644 --- a/chromium/content/test/BUILD.gn +++ b/chromium/content/test/BUILD.gn @@ -8,6 +8,7 @@ import("//build/config/chromeos/ui_mode.gni") import("//build/config/compiler/compiler.gni") import("//build/config/crypto.gni") import("//build/config/features.gni") +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//build/nocompile.gni") import("//components/viz/common/debugger/viz_debugger.gni") @@ -32,7 +33,7 @@ if (is_android) { # Use a static library here because many test binaries depend on this but don't # require many files from it. This makes linking more efficient. -static_library("test_support") { +jumbo_static_library("test_support") { testonly = true # See comment at the top of //content/BUILD.gn for why this is disabled in @@ -783,7 +784,7 @@ group("telemetry_gpu_integration_test_support") { # browsertest_support can be used by targets that run content_shell based # browser tests. -static_library("browsertest_support") { +jumbo_static_library("browsertest_support") { testonly = true # See comment at the top of //content/BUILD.gn for why this is disabled in diff --git a/chromium/content/utility/BUILD.gn b/chromium/content/utility/BUILD.gn index d899cd26737..c79b0c5fd6d 100644 --- a/chromium/content/utility/BUILD.gn +++ b/chromium/content/utility/BUILD.gn @@ -3,12 +3,13 @@ # found in the LICENSE file. import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//chromeos/assistant/assistant.gni") import("//device/vr/buildflags/buildflags.gni") import("//media/media_options.gni") import("//printing/buildflags/buildflags.gni") -source_set("utility") { +jumbo_source_set("utility") { # Only the public target should depend on this. All other targets (even # internal content ones other than test) should depend on the public one. visibility = [ diff --git a/chromium/docs/clang_tidy.md b/chromium/docs/clang_tidy.md index 24e9ff28ca4..28b03be1073 100644 --- a/chromium/docs/clang_tidy.md +++ b/chromium/docs/clang_tidy.md @@ -207,7 +207,8 @@ a problem, consider building clang-tidy from the same revision the current toolchain is using, rather than filing a bug against the toolchain component. Running clang-tidy is (hopefully) simple. -1. Build chrome normally. +1. Build chrome normally.\* Note that [Jumbo builds](jumbo.md) are not + supported. ``` ninja -C out/Release chrome ``` @@ -247,6 +248,14 @@ Copy-Paste Friendly (though you'll still need to stub in the variables): 'chrome/browser/.*' ``` +\*It's not clear which, if any, `gn` flags outside of `use_jumbo_build` may +cause issues for `clang-tidy`. I've had no problems building a component release +build, both with and without goma. if you run into issues, let us know! +||||||| fa98118a45f +\*It's not clear which, if any, `gn` flags may cause issues for +`clang-tidy`. I've had no problems building a component release build, +both with and without goma. if you run into issues, let us know! + Note that the source file regex must match how the build specified the file. This means that on Windows, you must use (escaped) backslashes even from a bash shell. diff --git a/chromium/docs/clang_tool_refactoring.md b/chromium/docs/clang_tool_refactoring.md index 62ec4418d58..3702c3f48dd 100644 --- a/chromium/docs/clang_tool_refactoring.md +++ b/chromium/docs/clang_tool_refactoring.md @@ -15,6 +15,8 @@ with a traditional find-and-replace regexp: ## Caveats +* Clang tools do not work with jumbo builds. + * Invocations of a clang tool runs on on only one build config at a time. For example, running the tool across a `target_os="win"` build won't update code that is guarded by `OS_POSIX`. Performing a global refactoring will often diff --git a/chromium/docs/linux/build_instructions.md b/chromium/docs/linux/build_instructions.md index 576d87a5622..17416229188 100644 --- a/chromium/docs/linux/build_instructions.md +++ b/chromium/docs/linux/build_instructions.md @@ -146,6 +146,15 @@ please follow [Goma for Chromium contributors](https://chromium.googlesource.com If you are a Google employee, see [go/building-chrome](https://goto.google.com/building-chrome) instead. +#### Jumbo/Unity builds + +Jumbo builds merge many translation units ("source files") and compile them +together. Since a large portion of Chromium's code is in shared header files, +this dramatically reduces the total amount of work needed. Check out the +[Jumbo / Unity builds](jumbo.md) for more information. + +Enable jumbo builds by setting the GN arg `use_jumbo_build=true`. + #### Disable NaCl By default, the build includes support for diff --git a/chromium/docs/mac_build_instructions.md b/chromium/docs/mac_build_instructions.md index 33f78ca0d61..4a30bcc3180 100644 --- a/chromium/docs/mac_build_instructions.md +++ b/chromium/docs/mac_build_instructions.md @@ -150,6 +150,15 @@ in your args.gn to disable debug symbols altogether. This makes both full rebuilds and linking faster (at the cost of not getting symbolized backtraces in gdb). +#### Jumbo/Unity builds + +Jumbo builds merge many translation units ("source files") and compile them +together. Since a large portion of Chromium's code is in shared header files, +this dramatically reduces the total amount of work needed. Check out the +[Jumbo / Unity builds](jumbo.md) for more information. + +Enable jumbo builds by setting the GN arg `use_jumbo_build=true`. + #### CCache You might also want to [install ccache](ccache_mac.md) to speed up the build. diff --git a/chromium/docs/windows_build_instructions.md b/chromium/docs/windows_build_instructions.md index be30a8eb4ed..3cd27dea280 100644 --- a/chromium/docs/windows_build_instructions.md +++ b/chromium/docs/windows_build_instructions.md @@ -199,6 +199,7 @@ in the editor that appears when you create your output directory (`gn args out/Default`) or on the gn gen command line (`gn gen out/Default --args="is_component_build = true is_debug = true"`). Some helpful settings to consider using include: +* `use_jumbo_build = true` - [Jumbo/unity](jumbo.md) builds. * `is_component_build = true` - this uses more, smaller DLLs, and incremental linking. * `enable_nacl = false` - this disables Native Client which is usually not diff --git a/chromium/extensions/BUILD.gn b/chromium/extensions/BUILD.gn index 707574eeba1..b288ccd177e 100644 --- a/chromium/extensions/BUILD.gn +++ b/chromium/extensions/BUILD.gn @@ -3,6 +3,7 @@ import("//build/config/chromecast_build.gni") import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//extensions/buildflags/buildflags.gni") import("//testing/test.gni") import("//tools/grit/grit_rule.gni") @@ -60,7 +61,7 @@ grit("extensions_renderer_resources") { ] } -static_library("test_support") { +jumbo_static_library("test_support") { testonly = true sources = [ "browser/api/declarative/test_rules_registry.cc", diff --git a/chromium/extensions/browser/BUILD.gn b/chromium/extensions/browser/BUILD.gn index a8469c678a9..cf007f5db24 100644 --- a/chromium/extensions/browser/BUILD.gn +++ b/chromium/extensions/browser/BUILD.gn @@ -4,6 +4,7 @@ import("//build/config/chromeos/ui_mode.gni") import("//build/config/features.gni") +import("//build/config/jumbo.gni") import("//extensions/buildflags/buildflags.gni") assert(enable_extensions) @@ -49,7 +50,7 @@ source_set("browser_context_keyed_service_factories") { } } -source_set("browser_sources") { +jumbo_source_set("browser_sources") { visibility = [ "./*" ] sources = [ @@ -711,7 +712,7 @@ source_set("browser_tests") { } } -source_set("test_support") { +jumbo_source_set("test_support") { testonly = true sources = [ "api/declarative_net_request/test_utils.cc", @@ -765,7 +766,7 @@ source_set("test_support") { } } -source_set("value_store_test_support") { +jumbo_source_set("value_store_test_support") { testonly = true sources = [ "value_store/value_store_unittest.cc", diff --git a/chromium/extensions/common/BUILD.gn b/chromium/extensions/common/BUILD.gn index 37bfde66710..c663859f23d 100644 --- a/chromium/extensions/common/BUILD.gn +++ b/chromium/extensions/common/BUILD.gn @@ -4,6 +4,7 @@ import("//build/config/chromeos/ui_mode.gni") import("//build/config/features.gni") +import("//build/config/jumbo.gni") import("//components/nacl/features.gni") import("//extensions/buildflags/buildflags.gni") import("//mojo/public/tools/bindings/mojom.gni") @@ -150,7 +151,7 @@ if (enable_extensions) { # This must be a static library because extensions common depends on # GetTrustedICAPublicKey in extensions/browser which isn't always linked # in. TODO(brettw): This reverse dependency should be fixed. - static_library("common") { + jumbo_static_library("common") { sources = [ "activation_sequence.h", "alias.h", diff --git a/chromium/extensions/renderer/BUILD.gn b/chromium/extensions/renderer/BUILD.gn index 5921292985d..fb2b31e51e0 100644 --- a/chromium/extensions/renderer/BUILD.gn +++ b/chromium/extensions/renderer/BUILD.gn @@ -3,11 +3,12 @@ # found in the LICENSE file. import("//build/config/features.gni") +import("//build/config/jumbo.gni") import("//extensions/buildflags/buildflags.gni") assert(enable_extensions) -source_set("renderer") { +jumbo_source_set("renderer") { sources = [ "activity_log_converter_strategy.cc", "activity_log_converter_strategy.h", @@ -281,7 +282,7 @@ source_set("renderer") { } } -static_library("unit_test_support") { +jumbo_static_library("unit_test_support") { # Sources that are shared between chrome-based renderer unit tests and # top-level extensions renderer unit tests. testonly = true diff --git a/chromium/gpu/BUILD.gn b/chromium/gpu/BUILD.gn index dc713e723c9..19110ed69ec 100644 --- a/chromium/gpu/BUILD.gn +++ b/chromium/gpu/BUILD.gn @@ -3,6 +3,7 @@ # found in the LICENSE file. import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//gpu/vulkan/features.gni") import("//testing/libfuzzer/fuzzer_test.gni") @@ -168,7 +169,7 @@ if (!use_static_angle) { } } # if (!use_static_angle) -static_library("test_support") { +jumbo_static_library("test_support") { testonly = true sources = [ "command_buffer/client/client_test_helper.cc", diff --git a/chromium/gpu/command_buffer/client/BUILD.gn b/chromium/gpu/command_buffer/client/BUILD.gn index eec19c86b28..de71a65627e 100644 --- a/chromium/gpu/command_buffer/client/BUILD.gn +++ b/chromium/gpu/command_buffer/client/BUILD.gn @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//ui/gl/features.gni") if (!is_nacl) { @@ -48,7 +49,7 @@ group("webgpu") { } } -source_set("client_sources") { +jumbo_source_set("client_sources") { # External code should depend on this via //gpu/client above rather than # depending on this directly or the component build will break. visibility = [ "//gpu/*" ] @@ -223,7 +224,7 @@ source_set("webgpu_interface") { } # Library emulates GLES2 using command_buffers. -component("gles2_implementation") { +jumbo_component("gles2_implementation") { sources = gles2_implementation_source_files defines = [ "GLES2_IMPL_IMPLEMENTATION" ] @@ -323,7 +324,7 @@ source_set("webgpu_sources") { } # Library emulates GLES2 using command_buffers. -component("gles2_implementation_no_check") { +jumbo_component("gles2_implementation_no_check") { sources = gles2_implementation_source_files defines = [ @@ -369,7 +370,7 @@ component("gles2_c_lib") { # Same as gles2_c_lib except with no parameter checking. Required for # OpenGL ES 2.0 conformance tests. -component("gles2_c_lib_nocheck") { +jumbo_component("gles2_c_lib_nocheck") { sources = gles2_c_lib_source_files defines = [ diff --git a/chromium/gpu/command_buffer/common/BUILD.gn b/chromium/gpu/command_buffer/common/BUILD.gn index 16fca625f01..0bd0a9a5e5e 100644 --- a/chromium/gpu/command_buffer/common/BUILD.gn +++ b/chromium/gpu/command_buffer/common/BUILD.gn @@ -7,6 +7,7 @@ # non-component build. This needs to match the GYP build which was likely an # attempt to make larger components to help with loading. +import("//build/config/jumbo.gni") import("//ui/gl/features.gni") group("common") { @@ -47,7 +48,7 @@ group("webgpu") { # Minimal set of definitions which don't have GPU dependencies outside of this # directory. -source_set("common_base_sources") { +jumbo_source_set("common_base_sources") { visibility = [ "//gpu/*" ] sources = [ "command_buffer_id.h", @@ -67,7 +68,7 @@ source_set("common_base_sources") { configs += [ "//gpu:gpu_implementation" ] } -source_set("common_sources") { +jumbo_source_set("common_sources") { visibility = [ "//gpu/*" ] sources = [ diff --git a/chromium/gpu/command_buffer/service/BUILD.gn b/chromium/gpu/command_buffer/service/BUILD.gn index 65b09454024..9a7a5ba74e0 100644 --- a/chromium/gpu/command_buffer/service/BUILD.gn +++ b/chromium/gpu/command_buffer/service/BUILD.gn @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//gpu/vulkan/features.gni") import("//skia/features.gni") @@ -25,9 +26,9 @@ group("gles2") { } if (is_component_build) { - link_target_type = "source_set" + link_target_type = "jumbo_source_set" } else { - link_target_type = "static_library" + link_target_type = "jumbo_static_library" } target(link_target_type, "service_sources") { # External code should depend on this via //gpu/command_buffer/service above @@ -495,7 +496,7 @@ proto_library("disk_cache_proto") { } if (is_android) { - static_library("android_texture_owner_test_support") { + jumbo_static_library("android_texture_owner_test_support") { testonly = true sources = [ "mock_abstract_texture.cc", diff --git a/chromium/gpu/config/BUILD.gn b/chromium/gpu/config/BUILD.gn index 0934432eb55..02fe2e3ff92 100644 --- a/chromium/gpu/config/BUILD.gn +++ b/chromium/gpu/config/BUILD.gn @@ -5,6 +5,7 @@ import("//build/config/chrome_build.gni") import("//build/config/chromecast_build.gni") import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//build/config/python.gni") import("//build/config/ui.gni") import("//gpu/vulkan/features.gni") @@ -113,7 +114,7 @@ if (enable_vulkan) { } } -source_set("config_sources") { +jumbo_source_set("config_sources") { # External code should depend on this via //gpu/config above rather than # depending on this directly or the component build will break. visibility = [ "//gpu/*" ] diff --git a/chromium/gpu/ipc/service/BUILD.gn b/chromium/gpu/ipc/service/BUILD.gn index 3fcf3d7a050..0cb1bf6efd6 100644 --- a/chromium/gpu/ipc/service/BUILD.gn +++ b/chromium/gpu/ipc/service/BUILD.gn @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//gpu/vulkan/features.gni") import("//testing/test.gni") @@ -13,7 +14,7 @@ declare_args() { subpixel_font_rendering_disabled = false } -component("service") { +jumbo_component("service") { output_name = "gpu_ipc_service" sources = [ "command_buffer_stub.cc", diff --git a/chromium/media/base/BUILD.gn b/chromium/media/base/BUILD.gn index eb2295b777f..6610d070add 100644 --- a/chromium/media/base/BUILD.gn +++ b/chromium/media/base/BUILD.gn @@ -5,6 +5,7 @@ import("//build/config/android/config.gni") import("//build/config/arm.gni") import("//build/config/features.gni") +import("//build/config/jumbo.gni") import("//build/config/linux/pkg_config.gni") import("//build/config/ozone.gni") import("//build/config/ui.gni") @@ -15,7 +16,7 @@ if (is_android) { import("//build/config/android/rules.gni") } -source_set("base") { +jumbo_source_set("base") { # Do not expand the visibility here without double-checking with OWNERS, this # is a roll-up target which is part of the //media component. Most other DEPs # should be using //media and not directly DEP this roll-up target. diff --git a/chromium/media/base/android/BUILD.gn b/chromium/media/base/android/BUILD.gn index b98b73ad331..f222b91f357 100644 --- a/chromium/media/base/android/BUILD.gn +++ b/chromium/media/base/android/BUILD.gn @@ -4,6 +4,7 @@ import("//build/config/android/config.gni") import("//build/config/arm.gni") +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//media/media_options.gni") @@ -13,7 +14,7 @@ if (is_android) { # This is bundled into //media, so all dependencies should be on //media. # APK targets that depend on this indirectly, should also # depend on :media_java to get the corresponding Java classes. - source_set("android") { + jumbo_source_set("android") { visibility = [ "//media", "//media/filters", diff --git a/chromium/media/base/ipc/BUILD.gn b/chromium/media/base/ipc/BUILD.gn index c1112cbb9bf..a846bec9e1a 100644 --- a/chromium/media/base/ipc/BUILD.gn +++ b/chromium/media/base/ipc/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -source_set("ipc") { +import("//build/config/jumbo.gni") + +jumbo_source_set("ipc") { sources = [ "media_param_traits.cc", "media_param_traits.h", diff --git a/chromium/media/base/mac/BUILD.gn b/chromium/media/base/mac/BUILD.gn index 9dd95bbc171..56f07001f6d 100644 --- a/chromium/media/base/mac/BUILD.gn +++ b/chromium/media/base/mac/BUILD.gn @@ -2,9 +2,11 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") + assert(is_apple) -source_set("mac") { +jumbo_source_set("mac") { # Note: This source_set is depended on only by //media. In the component # build, if other component targets also depend on it, multiple copies of # the ObjC classes declared in the files below will cause warnings at diff --git a/chromium/media/base/win/BUILD.gn b/chromium/media/base/win/BUILD.gn index 97dfcd06aa6..6329e3be2f8 100644 --- a/chromium/media/base/win/BUILD.gn +++ b/chromium/media/base/win/BUILD.gn @@ -2,6 +2,8 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") + assert(is_win) config("delay_load_mf") { @@ -13,7 +15,7 @@ config("delay_load_mf") { ] } -component("media_foundation_util") { +jumbo_component("media_foundation_util") { defines = [ "MF_INITIALIZER_IMPLEMENTATION" ] sources = [ "dxgi_device_manager.cc", diff --git a/chromium/media/capture/BUILD.gn b/chromium/media/capture/BUILD.gn index e96ba09d212..e24336971c0 100644 --- a/chromium/media/capture/BUILD.gn +++ b/chromium/media/capture/BUILD.gn @@ -4,6 +4,7 @@ import("//build/config/chromeos/ui_mode.gni") import("//build/config/features.gni") +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//media/media_options.gni") import("//testing/test.gni") @@ -28,7 +29,7 @@ component("capture_switches") { } # Things needed by //media/capture/mojom/video_capture_types.mojom. -component("capture_base") { +jumbo_component("capture_base") { defines = [ "CAPTURE_IMPLEMENTATION" ] sources = [ "capture_export.h", @@ -51,7 +52,7 @@ component("capture_base") { } # Target which allows breakout of Android BUILD.gn files. -source_set("capture_device_specific") { +jumbo_source_set("capture_device_specific") { visibility = [ ":capture_lib", "//media/capture/content/android", @@ -109,7 +110,7 @@ source_set("capture_device_specific") { ] } -component("capture_lib") { +jumbo_component("capture_lib") { defines = [ "CAPTURE_IMPLEMENTATION" ] sources = [ "video/create_video_capture_device_factory.cc", diff --git a/chromium/media/cast/BUILD.gn b/chromium/media/cast/BUILD.gn index 10e53d02d9d..eb8f55a057d 100644 --- a/chromium/media/cast/BUILD.gn +++ b/chromium/media/cast/BUILD.gn @@ -5,6 +5,7 @@ import("//build/config/android/config.gni") import("//build/config/chromeos/ui_mode.gni") import("//build/config/features.gni") +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//testing/test.gni") import("//third_party/protobuf/proto_library.gni") @@ -14,7 +15,7 @@ proto_library("logging_proto") { } # Common code shared by all cast components. -source_set("common") { +jumbo_source_set("common") { sources = [ "cast_config.cc", "cast_config.h", @@ -65,7 +66,7 @@ source_set("common") { ] } -source_set("net") { +jumbo_source_set("net") { sources = [ "net/cast_transport.h", "net/cast_transport_config.cc", @@ -117,7 +118,7 @@ source_set("net") { public_deps = [ ":common" ] } -source_set("sender") { +jumbo_source_set("sender") { sources = [ "cast_sender.h", "cast_sender_impl.cc", @@ -182,7 +183,7 @@ source_set("sender") { } } -source_set("test_receiver") { +jumbo_source_set("test_receiver") { sources = [ "test/receiver/audio_decoder.cc", "test/receiver/audio_decoder.h", diff --git a/chromium/media/filters/BUILD.gn b/chromium/media/filters/BUILD.gn index 9f7dc8c0036..620a730bbf0 100644 --- a/chromium/media/filters/BUILD.gn +++ b/chromium/media/filters/BUILD.gn @@ -2,10 +2,11 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//media/gpu/args.gni") import("//media/media_options.gni") -source_set("filters") { +jumbo_source_set("filters") { # Do not expand the visibility here without double-checking with OWNERS, this # is a roll-up target which is part of the //media component. Most other DEPs # should be using //media and not directly DEP this roll-up target. diff --git a/chromium/media/media_options.gni b/chromium/media/media_options.gni index b5e9170a287..50336fcd01a 100644 --- a/chromium/media/media_options.gni +++ b/chromium/media/media_options.gni @@ -7,6 +7,7 @@ import("//build/config/chromecast_build.gni") import("//build/config/chromeos/args.gni") import("//build/config/chromeos/ui_mode.gni") import("//build/config/features.gni") +import("//build/config/jumbo.gni") import("//media/gpu/args.gni") import("//testing/libfuzzer/fuzzer_test.gni") import("//third_party/libgav1/options.gni") @@ -74,7 +75,7 @@ declare_args() { # Enable logging override, e.g. enable DVLOGs through level 2 at build time. # On Chromecast, these are logged as INFO. # On Fuchsia, these are logged as VLOGs. - enable_logging_override = is_chromecast || is_fuchsia + enable_logging_override = !use_jumbo_build && (is_chromecast || is_fuchsia) enable_dav1d_decoder = !is_ios @@ -90,6 +91,9 @@ declare_args() { # enable_hls_sample_aes can only be true if enable_mse_mpeg2ts_stream_parser is. assert(enable_mse_mpeg2ts_stream_parser || !enable_hls_sample_aes) +# Logging override must not be enabled in jumbo builds. +assert(!use_jumbo_build || !enable_logging_override) + # Use a second declare_args() to pick up possible overrides of |use_cras|. declare_args() { # Enables runtime selection of PulseAudio library. diff --git a/chromium/media/mojo/clients/BUILD.gn b/chromium/media/mojo/clients/BUILD.gn index a95b2688bee..58fd013669e 100644 --- a/chromium/media/mojo/clients/BUILD.gn +++ b/chromium/media/mojo/clients/BUILD.gn @@ -2,8 +2,10 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") + # Implementations of media C++ interfaces using corresponding mojo services. -source_set("clients") { +jumbo_source_set("clients") { visibility = [ "//chromecast/*", diff --git a/chromium/media/mojo/common/BUILD.gn b/chromium/media/mojo/common/BUILD.gn index a570c550931..0b8e73fdb8b 100644 --- a/chromium/media/mojo/common/BUILD.gn +++ b/chromium/media/mojo/common/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -source_set("common") { +import("//build/config/jumbo.gni") + +jumbo_source_set("common") { sources = [ "audio_data_s16_converter.cc", "audio_data_s16_converter.h", diff --git a/chromium/media/mojo/services/BUILD.gn b/chromium/media/mojo/services/BUILD.gn index 2e80cb73ae4..4d679551c16 100644 --- a/chromium/media/mojo/services/BUILD.gn +++ b/chromium/media/mojo/services/BUILD.gn @@ -4,10 +4,11 @@ import("//build/config/chromecast_build.gni") import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//media/media_options.gni") import("//testing/test.gni") -component("services") { +jumbo_component("services") { output_name = "media_mojo_services" sources = [ "deferred_destroy_unique_receiver_set.h", diff --git a/chromium/mojo/public/tools/bindings/mojom.gni b/chromium/mojo/public/tools/bindings/mojom.gni index 3df85f1a192..efc60c71a08 100644 --- a/chromium/mojo/public/tools/bindings/mojom.gni +++ b/chromium/mojo/public/tools/bindings/mojom.gni @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/python.gni") import("//third_party/closure_compiler/closure_args.gni") import("//third_party/closure_compiler/compile_js.gni") @@ -918,7 +919,7 @@ template("mojom") { } shared_cpp_sources_target_name = "${target_name}_shared_cpp_sources" - source_set(shared_cpp_sources_target_name) { + jumbo_source_set(shared_cpp_sources_target_name) { if (defined(invoker.testonly)) { testonly = invoker.testonly } @@ -1480,7 +1481,7 @@ template("mojom") { sources_target_name = output_target_name } - target(sources_target_type, sources_target_name) { + target("jumbo_" + sources_target_type, sources_target_name) { if (defined(output_name_override)) { output_name = output_name_override } diff --git a/chromium/ppapi/cpp/BUILD.gn b/chromium/ppapi/cpp/BUILD.gn index 8f0bbcab03b..9adec152ca2 100644 --- a/chromium/ppapi/cpp/BUILD.gn +++ b/chromium/ppapi/cpp/BUILD.gn @@ -2,6 +2,8 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") + if (is_nacl) { import("//build/config/nacl/config.gni") } @@ -9,7 +11,7 @@ if (is_nacl) { if (is_nacl && is_nacl_glibc) { cpp_target_type = "shared_library" } else { - cpp_target_type = "static_library" + cpp_target_type = "jumbo_static_library" } # Link to this target to get the PPAPI C++ wrapper objects and plugin startup @@ -50,7 +52,7 @@ target(cpp_target_type, "cpp") { # Link to this target to get only the PPAPI C++ wrapper objects but not the # plugin startup code. Some plugins need special startup code that they supply # themselves. -source_set("objects") { +jumbo_source_set("objects") { sources = [ "array_output.cc", "array_output.h", diff --git a/chromium/ppapi/host/BUILD.gn b/chromium/ppapi/host/BUILD.gn index b9c867effae..2a459f799ba 100644 --- a/chromium/ppapi/host/BUILD.gn +++ b/chromium/ppapi/host/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -component("host") { +import("//build/config/jumbo.gni") + +jumbo_component("host") { output_name = "ppapi_host" sources = [ diff --git a/chromium/ppapi/proxy/BUILD.gn b/chromium/ppapi/proxy/BUILD.gn index 90c2049a4e4..68708b2abb2 100644 --- a/chromium/ppapi/proxy/BUILD.gn +++ b/chromium/ppapi/proxy/BUILD.gn @@ -2,15 +2,22 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/nacl/config.gni") config("proxy_implementation") { defines = [ "PPAPI_PROXY_IMPLEMENTATION" ] } -component("proxy") { +jumbo_component("proxy") { output_name = "ppapi_proxy" + if (is_nacl) { + # The nacl toolchain has template related bugs that are triggered + # in jumbo builds. https://crbug.com/912152 + never_build_jumbo = true + } + sources = [ # Take some standalone files from the C++ wrapper allowing us to more # easily make async callbacks in the proxy. We can't depend on the @@ -324,7 +331,7 @@ source_set("ipc_sources") { } } -static_library("test_support") { +jumbo_static_library("test_support") { testonly = true sources = [ diff --git a/chromium/ppapi/shared_impl/BUILD.gn b/chromium/ppapi/shared_impl/BUILD.gn index 4118baa5c61..24fbd4412d6 100644 --- a/chromium/ppapi/shared_impl/BUILD.gn +++ b/chromium/ppapi/shared_impl/BUILD.gn @@ -2,11 +2,18 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/nacl/config.gni") -component("shared_impl") { +jumbo_component("shared_impl") { output_name = "ppapi_shared" + if (is_nacl) { + # The nacl toolchain has template related bugs that are triggered + # in jumbo builds. https://crbug.com/912152 + never_build_jumbo = true + } + sources = [ "array_var.cc", "array_var.h", diff --git a/chromium/services/cert_verifier/cert_net_url_loader/BUILD.gn b/chromium/services/cert_verifier/cert_net_url_loader/BUILD.gn index 3efdc1e8994..009e8c23e52 100644 --- a/chromium/services/cert_verifier/cert_net_url_loader/BUILD.gn +++ b/chromium/services/cert_verifier/cert_net_url_loader/BUILD.gn @@ -3,9 +3,10 @@ # found in the LICENSE file. import("//build/config/crypto.gni") +import("//build/config/jumbo.gni") import("//testing/test.gni") -component("cert_net_url_loader") { +jumbo_component("cert_net_url_loader") { sources = [ "cert_net_fetcher_url_loader.cc", "cert_net_fetcher_url_loader.h", diff --git a/chromium/services/network/BUILD.gn b/chromium/services/network/BUILD.gn index 96eb95c55c6..e88852efc0e 100644 --- a/chromium/services/network/BUILD.gn +++ b/chromium/services/network/BUILD.gn @@ -3,12 +3,13 @@ # found in the LICENSE file. import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//mojo/public/tools/bindings/mojom.gni") import("//net/features.gni") import("//services/network/public/cpp/features.gni") import("//testing/libfuzzer/fuzzer_test.gni") -component("network_service") { +jumbo_component("network_service") { sources = [ "chunked_data_pipe_upload_data_stream.cc", "chunked_data_pipe_upload_data_stream.h", @@ -436,7 +437,7 @@ source_set("tests") { } } -source_set("test_support") { +jumbo_source_set("test_support") { testonly = true sources = [ diff --git a/chromium/services/network/public/cpp/BUILD.gn b/chromium/services/network/public/cpp/BUILD.gn index 772d4ba5995..0499bd7ef48 100644 --- a/chromium/services/network/public/cpp/BUILD.gn +++ b/chromium/services/network/public/cpp/BUILD.gn @@ -3,6 +3,7 @@ # found in the LICENSE file. import("//build/buildflag_header.gni") +import("//build/config/jumbo.gni") import("//mojo/public/tools/bindings/mojom.gni") import("//services/network/public/cpp/features.gni") import("//testing/libfuzzer/fuzzer_test.gni") @@ -12,7 +13,7 @@ buildflag_header("buildflags") { flags = [ "IS_CT_SUPPORTED=$is_ct_supported" ] } -component("crash_keys") { +jumbo_component("crash_keys") { sources = [ "crash_keys.cc", "crash_keys.h", @@ -21,7 +22,7 @@ component("crash_keys") { defines = [ "IS_NETWORK_CPP_CRASH_KEYS_IMPL" ] } -component("cpp") { +jumbo_component("cpp") { output_name = "network_cpp" sources = [ @@ -249,7 +250,7 @@ component("schemeful_site_mojom_support") { defines = [ "IS_NETWORK_CPP_SCHEMEFUL_IMPL" ] } -component("cpp_base") { +jumbo_component("cpp_base") { output_name = "network_cpp_base" sources = [ diff --git a/chromium/storage/browser/BUILD.gn b/chromium/storage/browser/BUILD.gn index 025683c50d7..b161551eb41 100644 --- a/chromium/storage/browser/BUILD.gn +++ b/chromium/storage/browser/BUILD.gn @@ -1,10 +1,11 @@ # Copyright 2014 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//mojo/public/tools/bindings/mojom.gni") import("//testing/test.gni") -component("browser") { +jumbo_component("browser") { output_name = "storage_browser" sources = [ "blob/blob_builder_from_stream.cc", @@ -347,7 +348,7 @@ source_set("unittests") { ] } -static_library("test_support") { +jumbo_static_library("test_support") { testonly = true sources = [ diff --git a/chromium/third_party/blink/common/BUILD.gn b/chromium/third_party/blink/common/BUILD.gn index 449029257d3..cbd76124861 100644 --- a/chromium/third_party/blink/common/BUILD.gn +++ b/chromium/third_party/blink/common/BUILD.gn @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//media/media_options.gni") import("//testing/libfuzzer/fuzzer_test.gni") import("//testing/test.gni") @@ -53,7 +54,7 @@ config("blink_common_implementation") { defines = [ "BLINK_COMMON_IMPLEMENTATION=1" ] } -source_set("common") { +jumbo_source_set("common") { # No target should directly depend on this target since this is just the # source set rather than the actual component that can be linked to. # Dependencies instead should be to //third_party/blink/public/common:common. @@ -284,7 +285,7 @@ test("blink_common_unittests") { data_deps = [ ":common_unittests_data" ] } -source_set("common_unittests_sources") { +jumbo_source_set("common_unittests_sources") { testonly = true sources = [ diff --git a/chromium/third_party/blink/renderer/bindings/core/v8/BUILD.gn b/chromium/third_party/blink/renderer/bindings/core/v8/BUILD.gn index 2c1fd29632e..7f8fc3a56c1 100644 --- a/chromium/third_party/blink/renderer/bindings/core/v8/BUILD.gn +++ b/chromium/third_party/blink/renderer/bindings/core/v8/BUILD.gn @@ -40,7 +40,7 @@ blink_core_sources("v8") { ] } -source_set("testing") { +jumbo_source_set("testing") { testonly = true visibility = [] @@ -193,7 +193,7 @@ blink_core_sources("bindings_core_impl") { # Compile the test sources generated above. This test target doesn't count # as part of the "core" component so shouldn't use the blink_core_sources for # linking on Windows. -source_set("testing_internal") { +jumbo_source_set("testing_internal") { testonly = true sources = [] diff --git a/chromium/third_party/blink/renderer/bindings/modules/v8/BUILD.gn b/chromium/third_party/blink/renderer/bindings/modules/v8/BUILD.gn index f52b72568d4..7ef84c60913 100644 --- a/chromium/third_party/blink/renderer/bindings/modules/v8/BUILD.gn +++ b/chromium/third_party/blink/renderer/bindings/modules/v8/BUILD.gn @@ -41,7 +41,7 @@ blink_modules_sources("v8") { ] } -source_set("testing") { +jumbo_source_set("testing") { testonly = true visibility = [] diff --git a/chromium/third_party/blink/renderer/controller/BUILD.gn b/chromium/third_party/blink/renderer/controller/BUILD.gn index 85b2547d1b3..f837787a77e 100644 --- a/chromium/third_party/blink/renderer/controller/BUILD.gn +++ b/chromium/third_party/blink/renderer/controller/BUILD.gn @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//testing/test.gni") import("//third_party/blink/renderer/bindings/bindings.gni") @@ -14,7 +15,7 @@ visibility = [ "//third_party/blink/*", ] -component("controller") { +jumbo_component("controller") { output_name = "blink_controller" deps = [ @@ -160,7 +161,7 @@ test("blink_perf_tests") { deps = [ ":blink_perf_tests_sources" ] } -source_set("blink_perf_tests_sources") { +jumbo_source_set("blink_perf_tests_sources") { visibility = [] # Allow re-assignment of list. visibility = [ "*" ] testonly = true @@ -204,7 +205,7 @@ source_set("blink_bindings_test_sources") { ] } -source_set("blink_unittests_sources") { +jumbo_source_set("blink_unittests_sources") { visibility = [] # Allow re-assignment of list. visibility = [ "*" ] testonly = true diff --git a/chromium/third_party/blink/renderer/core/BUILD.gn b/chromium/third_party/blink/renderer/core/BUILD.gn index dccd9d974b9..e04c132a1d9 100644 --- a/chromium/third_party/blink/renderer/core/BUILD.gn +++ b/chromium/third_party/blink/renderer/core/BUILD.gn @@ -358,7 +358,7 @@ blink_core_sources("core_hot") { ] } -source_set("testing") { +jumbo_source_set("testing") { testonly = true configs += [ @@ -1116,7 +1116,7 @@ if (is_component_build) { core_generated_target_type = "static_library" } -target(core_generated_target_type, "core_generated") { +target("jumbo_" + core_generated_target_type, "core_generated") { sources = bindings_core_v8_files # Add all sources generated by the targets above. @@ -1197,7 +1197,7 @@ fuzzer_test("text_resource_decoder_fuzzer") { ] } -source_set("unit_tests") { +jumbo_source_set("unit_tests") { testonly = true sources = [ "accessibility/ax_context_test.cc", @@ -1695,7 +1695,7 @@ group("js_files_for_form_controls_web_tests") { data_deps = [ ":form_controls_pickers_js" ] } -source_set("perf_tests") { +jumbo_source_set("perf_tests") { testonly = true sources = [ "layout/svg/svg_hit_test_perftest.cc", @@ -1718,7 +1718,7 @@ source_set("perf_tests") { ] } -source_set("unit_test_support") { +jumbo_source_set("unit_test_support") { testonly = true sources = [ "frame/frame_test_helpers.cc", diff --git a/chromium/third_party/blink/renderer/core/core.gni b/chromium/third_party/blink/renderer/core/core.gni index 82b09e18ccb..04acc23c796 100644 --- a/chromium/third_party/blink/renderer/core/core.gni +++ b/chromium/third_party/blink/renderer/core/core.gni @@ -3,6 +3,7 @@ # found in the LICENSE file. import("//build/config/chrome_build.gni") +import("//build/config/jumbo.gni") import("//third_party/blink/renderer/config.gni") blink_core_output_dir = "$root_gen_dir/third_party/blink/renderer/core" @@ -57,9 +58,9 @@ core_config_add += blink_symbols_config # Normal meaning if defined. If undefined, defaults to everything in core. template("blink_core_sources") { if (is_component_build) { - target_type = "source_set" + target_type = "jumbo_source_set" } else { - target_type = "static_library" + target_type = "jumbo_static_library" } target(target_type, target_name) { # The visibility will get overridden by forward_variables_from below if the @@ -97,7 +98,7 @@ set_defaults("blink_core_sources") { } template("blink_core_tests") { - source_set(target_name) { + jumbo_source_set(target_name) { # The visibility will get overridden by forward_variables_from below if the # invoker defined it. visibility = [ "//third_party/blink/renderer/core/*" ] diff --git a/chromium/third_party/blink/renderer/core/inspector/BUILD.gn b/chromium/third_party/blink/renderer/core/inspector/BUILD.gn index ae8bfda8024..567e20e5492 100644 --- a/chromium/third_party/blink/renderer/core/inspector/BUILD.gn +++ b/chromium/third_party/blink/renderer/core/inspector/BUILD.gn @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//third_party/blink/renderer/bindings/bindings.gni") import("//third_party/blink/renderer/core/core.gni") import("//third_party/inspector_protocol/inspector_protocol.gni") @@ -92,7 +93,7 @@ inspector_protocol_generate("protocol_sources") { } # Compiles the sources generated above. -source_set("generated") { +jumbo_source_set("generated") { sources = get_target_outputs(":protocol_sources") configs -= core_config_remove diff --git a/chromium/third_party/blink/renderer/modules/BUILD.gn b/chromium/third_party/blink/renderer/modules/BUILD.gn index 7a851990308..d415295d6f2 100644 --- a/chromium/third_party/blink/renderer/modules/BUILD.gn +++ b/chromium/third_party/blink/renderer/modules/BUILD.gn @@ -34,7 +34,7 @@ make_names("media_capabilities_names") { deps = [] # Don't use default deps (otherwise it will be circular). } -component("modules") { +jumbo_component("modules") { output_name = "blink_modules" visibility = [] # Allow re-assignment of list. @@ -223,7 +223,7 @@ component("modules") { configs += blink_optimization_config } -source_set("modules_testing") { +jumbo_source_set("modules_testing") { testonly = true sources = [ @@ -290,7 +290,7 @@ group("make_modules_generated") { ] } -source_set("unit_tests") { +jumbo_source_set("unit_tests") { testonly = true sources = [ diff --git a/chromium/third_party/blink/renderer/modules/gamepad/BUILD.gn b/chromium/third_party/blink/renderer/modules/gamepad/BUILD.gn index ea4c2eb0776..e7588bb6a30 100644 --- a/chromium/third_party/blink/renderer/modules/gamepad/BUILD.gn +++ b/chromium/third_party/blink/renderer/modules/gamepad/BUILD.gn @@ -39,7 +39,7 @@ blink_modules_sources("gamepad") { ] } -source_set("unit_tests") { +jumbo_source_set("unit_tests") { testonly = true sources = [ "gamepad_comparisons_test.cc" ] diff --git a/chromium/third_party/blink/renderer/modules/hid/BUILD.gn b/chromium/third_party/blink/renderer/modules/hid/BUILD.gn index 4b46a7c07fd..0bb19b35147 100644 --- a/chromium/third_party/blink/renderer/modules/hid/BUILD.gn +++ b/chromium/third_party/blink/renderer/modules/hid/BUILD.gn @@ -17,7 +17,7 @@ blink_modules_sources("hid") { ] } -source_set("unit_tests") { +jumbo_source_set("unit_tests") { testonly = true sources = [ "hid_device_test.cc" ] diff --git a/chromium/third_party/blink/renderer/modules/media/BUILD.gn b/chromium/third_party/blink/renderer/modules/media/BUILD.gn index a9855be83b2..37b23c53535 100644 --- a/chromium/third_party/blink/renderer/modules/media/BUILD.gn +++ b/chromium/third_party/blink/renderer/modules/media/BUILD.gn @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//third_party/blink/renderer/modules/modules.gni") blink_modules_sources("media") { diff --git a/chromium/third_party/blink/renderer/modules/mediastream/BUILD.gn b/chromium/third_party/blink/renderer/modules/mediastream/BUILD.gn index c2884478b0a..a70cc927e4d 100644 --- a/chromium/third_party/blink/renderer/modules/mediastream/BUILD.gn +++ b/chromium/third_party/blink/renderer/modules/mediastream/BUILD.gn @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//third_party/blink/renderer/modules/modules.gni") blink_modules_sources("mediastream") { @@ -117,7 +118,7 @@ blink_modules_sources("mediastream") { public_deps = [ "//media/capture:capture_lib" ] } -source_set("test_support") { +jumbo_source_set("test_support") { testonly = true sources = [ diff --git a/chromium/third_party/blink/renderer/modules/modules.gni b/chromium/third_party/blink/renderer/modules/modules.gni index 24badc49d7b..aed5f431201 100644 --- a/chromium/third_party/blink/renderer/modules/modules.gni +++ b/chromium/third_party/blink/renderer/modules/modules.gni @@ -7,6 +7,7 @@ # This file is shared with all modules' BUILD files which shouldn't need access # to the huge and slow lists of sources. If sharing is necessary, make a # separate .gni. +import("//build/config/jumbo.gni") import("//third_party/blink/renderer/config.gni") blink_modules_output_dir = "$root_gen_dir/third_party/blink/renderer/modules" @@ -25,7 +26,7 @@ template("blink_modules_sources") { target_type = "static_library" } - target(target_type, target_name) { + target("jumbo_" + target_type, target_name) { # The visibility will get overridden by forward_variables_from below if the # invoker defined it. visibility = [ "//third_party/blink/renderer/modules/*" ] diff --git a/chromium/third_party/blink/renderer/modules/peerconnection/BUILD.gn b/chromium/third_party/blink/renderer/modules/peerconnection/BUILD.gn index 163bb594b6d..fdf4c79d246 100644 --- a/chromium/third_party/blink/renderer/modules/peerconnection/BUILD.gn +++ b/chromium/third_party/blink/renderer/modules/peerconnection/BUILD.gn @@ -161,7 +161,7 @@ blink_modules_sources("peerconnection") { } } -source_set("test_support") { +jumbo_source_set("test_support") { testonly = true sources = [ diff --git a/chromium/third_party/blink/renderer/modules/storage/BUILD.gn b/chromium/third_party/blink/renderer/modules/storage/BUILD.gn index 01d50276fb3..8c3aef5c420 100644 --- a/chromium/third_party/blink/renderer/modules/storage/BUILD.gn +++ b/chromium/third_party/blink/renderer/modules/storage/BUILD.gn @@ -27,7 +27,7 @@ blink_modules_sources("storage") { ] } -source_set("unit_tests") { +jumbo_source_set("unit_tests") { testonly = true sources = [ "cached_storage_area_test.cc", diff --git a/chromium/third_party/blink/renderer/modules/webrtc/BUILD.gn b/chromium/third_party/blink/renderer/modules/webrtc/BUILD.gn index c00e88a641c..80e0329c7db 100644 --- a/chromium/third_party/blink/renderer/modules/webrtc/BUILD.gn +++ b/chromium/third_party/blink/renderer/modules/webrtc/BUILD.gn @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//third_party/blink/renderer/modules/modules.gni") blink_modules_sources("webrtc") { diff --git a/chromium/third_party/blink/renderer/modules/webtransport/BUILD.gn b/chromium/third_party/blink/renderer/modules/webtransport/BUILD.gn index 66edac2a9f2..83ed5e0aa2c 100644 --- a/chromium/third_party/blink/renderer/modules/webtransport/BUILD.gn +++ b/chromium/third_party/blink/renderer/modules/webtransport/BUILD.gn @@ -23,7 +23,7 @@ blink_modules_sources("webtransport") { ] } -source_set("unit_tests") { +jumbo_source_set("unit_tests") { testonly = true sources = [ "bidirectional_stream_test.cc", diff --git a/chromium/third_party/blink/renderer/platform/BUILD.gn b/chromium/third_party/blink/renderer/platform/BUILD.gn index 6b3e50e064d..bec4599ae66 100644 --- a/chromium/third_party/blink/renderer/platform/BUILD.gn +++ b/chromium/third_party/blink/renderer/platform/BUILD.gn @@ -7,6 +7,7 @@ import("//build/buildflag_header.gni") import("//build/compiled_action.gni") import("//build/config/compiler/compiler.gni") import("//build/config/features.gni") +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//media/media_options.gni") import("//skia/features.gni") @@ -250,7 +251,7 @@ source_set("platform_export") { ] } -component("platform") { +jumbo_component("platform") { visibility = [] # Allow re-assignment of list. visibility = [ "//components/pdf/common:interfaces_blink", @@ -1866,7 +1867,7 @@ component("platform") { configs += blink_symbols_config } -static_library("test_support") { +jumbo_static_library("test_support") { visibility += [ "//third_party/blink/*", "//tools/privacy_budget/font_indexer:*", @@ -1995,7 +1996,7 @@ test("blink_platform_unittests") { } } -source_set("blink_platform_unittests_sources") { +jumbo_source_set("blink_platform_unittests_sources") { visibility = [] # Allow re-assignment of list. visibility = [ "*" ] testonly = true @@ -2440,7 +2441,7 @@ test("blink_fuzzer_unittests") { # This source set is used for fuzzers that need an environment similar to unit # tests. -source_set("blink_fuzzer_test_support") { +jumbo_source_set("blink_fuzzer_test_support") { testonly = true visibility = [] # Allow re-assignment of list. visibility = [ "*" ] @@ -2574,7 +2575,7 @@ blink_text_codec_fuzzer("WINDOWS_1252") { # NOTE: These are legacy unit tests and tests that require a Platform # object. Do not add more unless the test requires a Platform object. # These tests are a part of the blink_unittests binary. -source_set("unit_tests") { +jumbo_source_set("unit_tests") { testonly = true visibility = [] visibility = [ "//third_party/blink/renderer/*" ] diff --git a/chromium/third_party/blink/renderer/platform/blob/BUILD.gn b/chromium/third_party/blink/renderer/platform/blob/BUILD.gn index ff184e7af3b..f55b6b7cf39 100644 --- a/chromium/third_party/blink/renderer/platform/blob/BUILD.gn +++ b/chromium/third_party/blink/renderer/platform/blob/BUILD.gn @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//third_party/blink/renderer/platform/platform.gni") # Intentionally depends on generator targets so to depend only on generated @@ -10,7 +11,7 @@ import("//third_party/blink/renderer/platform/platform.gni") # There is no tool to detect missing indirect generated header dependency today # and this is easy to be broken when mojom files are updated to depend on # another. -source_set("generator") { +jumbo_source_set("generator") { public_deps = [ "//third_party/blink/public/mojom:mojom_platform_blink_headers", "//url/mojom:url_mojom_gurl_blink_headers", @@ -41,7 +42,7 @@ blink_platform_sources("blob") { ] } -source_set("unit_tests") { +jumbo_source_set("unit_tests") { visibility = [ "//third_party/blink/renderer/platform:*" ] testonly = true @@ -62,7 +63,7 @@ source_set("unit_tests") { ] } -source_set("test_support") { +jumbo_source_set("test_support") { # This target defines test files for platform:test_support that # blink_platform_unittests and blink_unittests can use. visibility = [ "//third_party/blink/renderer/platform:test_support" ] diff --git a/chromium/third_party/blink/renderer/platform/heap/BUILD.gn b/chromium/third_party/blink/renderer/platform/heap/BUILD.gn index 601e1692fd2..2ce5d49b6ad 100644 --- a/chromium/third_party/blink/renderer/platform/heap/BUILD.gn +++ b/chromium/third_party/blink/renderer/platform/heap/BUILD.gn @@ -4,6 +4,7 @@ import("//build/buildflag_header.gni") import("//build/config/compiler/compiler.gni") +import("//build/config/jumbo.gni") import("//build/config/sanitizers/sanitizers.gni") import("//testing/test.gni") import("//third_party/blink/public/public_features.gni") @@ -19,7 +20,7 @@ buildflag_header("blink_heap_buildflags") { ] } -source_set("heap_unsanitized") { +jumbo_source_set("heap_unsanitized") { if (is_asan) { configs -= [ "//build/config/sanitizers:default_sanitizer_flags" ] } @@ -202,7 +203,7 @@ blink_platform_sources("heap") { ] } -source_set("test_support") { +jumbo_source_set("test_support") { testonly = true sources = [ @@ -260,7 +261,7 @@ test("blink_heap_unittests") { } } -source_set("blink_heap_unittests_sources") { +jumbo_source_set("blink_heap_unittests_sources") { testonly = true sources = [ "../testing/run_all_tests.cc" ] diff --git a/chromium/third_party/blink/renderer/platform/instrumentation/BUILD.gn b/chromium/third_party/blink/renderer/platform/instrumentation/BUILD.gn index 814c58d21ff..ba6496f903d 100644 --- a/chromium/third_party/blink/renderer/platform/instrumentation/BUILD.gn +++ b/chromium/third_party/blink/renderer/platform/instrumentation/BUILD.gn @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//third_party/blink/renderer/platform/platform.gni") blink_platform_sources("instrumentation") { @@ -45,7 +46,7 @@ blink_platform_sources("instrumentation") { allow_circular_includes_from = public_deps } -source_set("unit_tests") { +jumbo_source_set("unit_tests") { testonly = true sources = [ diff --git a/chromium/third_party/blink/renderer/platform/loader/BUILD.gn b/chromium/third_party/blink/renderer/platform/loader/BUILD.gn index 00b0691175c..f21ae1f0832 100644 --- a/chromium/third_party/blink/renderer/platform/loader/BUILD.gn +++ b/chromium/third_party/blink/renderer/platform/loader/BUILD.gn @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//third_party/blink/renderer/build/scripts/scripts.gni") import("//third_party/blink/renderer/platform/platform.gni") import("//third_party/blink/renderer/platform/platform_generated.gni") @@ -182,7 +183,7 @@ blink_platform_sources("loader") { [ "//third_party/blink/renderer/platform/network:network" ] } -source_set("unit_tests") { +jumbo_source_set("unit_tests") { # This target defines test files for blink_platform_unittests and only the # blink_platform_unittests target should depend on it. visibility = [ "//third_party/blink/renderer/platform:*" ] @@ -240,7 +241,7 @@ source_set("unit_tests") { ] } -source_set("test_support") { +jumbo_source_set("test_support") { # This target defines test files for platform:test_support that # blink_platform_unittests and blink_unittests can use. visibility = [ "//third_party/blink/renderer/platform:test_support" ] diff --git a/chromium/third_party/blink/renderer/platform/network/BUILD.gn b/chromium/third_party/blink/renderer/platform/network/BUILD.gn index 163d86a9bb9..252fd169093 100644 --- a/chromium/third_party/blink/renderer/platform/network/BUILD.gn +++ b/chromium/third_party/blink/renderer/platform/network/BUILD.gn @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//third_party/blink/renderer/build/scripts/scripts.gni") import("//third_party/blink/renderer/platform/platform.gni") import("//third_party/blink/renderer/platform/platform_generated.gni") @@ -72,7 +73,7 @@ blink_platform_sources("network") { ] } -source_set("unit_tests") { +jumbo_source_set("unit_tests") { visibility = [ "//third_party/blink/renderer/platform:*" ] testonly = true @@ -98,7 +99,7 @@ source_set("unit_tests") { public_deps = [ "//third_party/blink/renderer/platform:platform" ] } -source_set("test_support") { +jumbo_source_set("test_support") { visibility = [ "//third_party/blink/renderer/platform:test_support" ] testonly = true diff --git a/chromium/third_party/blink/renderer/platform/platform.gni b/chromium/third_party/blink/renderer/platform/platform.gni index eb8b78f4506..85a1a0a3c21 100644 --- a/chromium/third_party/blink/renderer/platform/platform.gni +++ b/chromium/third_party/blink/renderer/platform/platform.gni @@ -4,6 +4,8 @@ import("//third_party/blink/renderer/config.gni") +import("//build/config/jumbo.gni") + platform_config_add = [ "//build/config/compiler:no_size_t_to_int_warning", "//build/config/compiler:wexit_time_destructors", @@ -17,7 +19,7 @@ platform_config_add = [ platform_config_remove = [] template("blink_platform_sources") { - source_set(target_name) { + jumbo_source_set(target_name) { # Only platform can directly depend on this. # Any target outside platform should instead depend on platform. visibility = [ "//third_party/blink/renderer/platform/*" ] diff --git a/chromium/third_party/blink/renderer/platform/scheduler/BUILD.gn b/chromium/third_party/blink/renderer/platform/scheduler/BUILD.gn index 9b6541592a9..1c1b853008a 100644 --- a/chromium/third_party/blink/renderer/platform/scheduler/BUILD.gn +++ b/chromium/third_party/blink/renderer/platform/scheduler/BUILD.gn @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//testing/libfuzzer/fuzzer_test.gni") import("//third_party/blink/renderer/platform/platform.gni") import("//third_party/protobuf/proto_library.gni") @@ -186,7 +187,7 @@ blink_platform_sources("scheduler") { ] } -source_set("test_support") { +jumbo_source_set("test_support") { testonly = true sources = [ @@ -217,7 +218,7 @@ source_set("test_support") { configs += [ "//third_party/blink/renderer/platform:blink_platform_config" ] } -source_set("unit_tests") { +jumbo_source_set("unit_tests") { testonly = true sources = [ @@ -267,7 +268,7 @@ source_set("unit_tests") { configs += [ "//third_party/blink/renderer/platform:blink_platform_config" ] } -source_set("scheduler_fuzzer_tests") { +jumbo_source_set("scheduler_fuzzer_tests") { testonly = true sources = [] diff --git a/chromium/third_party/blink/renderer/platform/wtf/BUILD.gn b/chromium/third_party/blink/renderer/platform/wtf/BUILD.gn index 07f329965cb..16cc270a33f 100644 --- a/chromium/third_party/blink/renderer/platform/wtf/BUILD.gn +++ b/chromium/third_party/blink/renderer/platform/wtf/BUILD.gn @@ -6,6 +6,7 @@ assert(!is_ios) import("//build/buildflag_header.gni") import("//build/config/compiler/compiler.gni") +import("//build/config/jumbo.gni") import("//testing/test.gni") import("//third_party/blink/public/public_features.gni") import("//third_party/blink/renderer/config.gni") @@ -42,7 +43,7 @@ config("wtf_config") { } } -component("wtf") { +jumbo_component("wtf") { configs += [ "//build/config/compiler:noshadowing" ] sources = [ @@ -289,7 +290,7 @@ test("wtf_unittests") { deps = [ ":wtf_unittests_sources" ] } -source_set("wtf_unittests_sources") { +jumbo_source_set("wtf_unittests_sources") { visibility = [] # Allow re-assignment of list. visibility = [ "*" ] testonly = true diff --git a/chromium/third_party/inspector_protocol/BUILD.gn b/chromium/third_party/inspector_protocol/BUILD.gn index 010eb28c9ae..0712db60a33 100644 --- a/chromium/third_party/inspector_protocol/BUILD.gn +++ b/chromium/third_party/inspector_protocol/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -component("crdtp") { +import("//build/config/jumbo.gni") + +jumbo_component("crdtp") { sources = [ "crdtp/cbor.cc", "crdtp/cbor.h", diff --git a/chromium/ui/accessibility/BUILD.gn b/chromium/ui/accessibility/BUILD.gn index cf03156c5c0..333ad6ce0e6 100644 --- a/chromium/ui/accessibility/BUILD.gn +++ b/chromium/ui/accessibility/BUILD.gn @@ -3,6 +3,7 @@ # found in the LICENSE file. import("//build/config/features.gni") +import("//build/config/jumbo.gni") import("//build/config/linux/pkg_config.gni") import("//build/config/ui.gni") import("//mojo/public/tools/bindings/mojom.gni") @@ -34,7 +35,7 @@ mojom_component("ax_enums_mojo") { # included by Blink. The rule of thumb (for now) is that it's # anything platform-neutral (no platform/ directory) that # relates to a single accessibility node (no trees, etc.). -component("ax_base") { +jumbo_component("ax_base") { defines = [ "AX_BASE_IMPLEMENTATION" ] sources = [ @@ -99,7 +100,7 @@ component("ax_base") { # } #} -component("accessibility") { +jumbo_component("accessibility") { defines = [ "AX_IMPLEMENTATION" ] sources = [ diff --git a/chromium/ui/accessibility/platform/BUILD.gn b/chromium/ui/accessibility/platform/BUILD.gn index 142ad8b728c..a1515ed92ed 100644 --- a/chromium/ui/accessibility/platform/BUILD.gn +++ b/chromium/ui/accessibility/platform/BUILD.gn @@ -3,6 +3,7 @@ # found in the LICENSE file. import("//build/config/features.gni") +import("//build/config/jumbo.gni") import("//build/config/linux/pkg_config.gni") import("//build/config/ui.gni") import("//mojo/public/tools/bindings/mojom.gni") diff --git a/chromium/ui/aura/BUILD.gn b/chromium/ui/aura/BUILD.gn index 92de86a947a..e8395fa92a1 100644 --- a/chromium/ui/aura/BUILD.gn +++ b/chromium/ui/aura/BUILD.gn @@ -2,10 +2,11 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//testing/test.gni") -component("aura") { +jumbo_component("aura") { public = [ "client/aura_constants.h", "client/capture_client.h", @@ -184,7 +185,7 @@ component("aura") { configs += [ "//build/config/compiler:noshadowing" ] } -static_library("test_support") { +jumbo_static_library("test_support") { testonly = true sources = [ "test/aura_test_base.cc", diff --git a/chromium/ui/base/BUILD.gn b/chromium/ui/base/BUILD.gn index 25719d1700b..74979282a80 100644 --- a/chromium/ui/base/BUILD.gn +++ b/chromium/ui/base/BUILD.gn @@ -6,6 +6,7 @@ import("//build/buildflag_header.gni") import("//build/config/chromeos/ui_mode.gni") import("//build/config/compiler/compiler.gni") import("//build/config/dcheck_always_on.gni") +import("//build/config/jumbo.gni") import("//build/config/linux/gtk/gtk.gni") import("//build/config/linux/pangocairo/pangocairo.gni") import("//build/config/locales.gni") @@ -85,7 +86,7 @@ source_set("hit_test") { deps = [ "//base" ] } -component("base") { +jumbo_component("base") { output_name = "ui_base" sources = [ @@ -693,7 +694,7 @@ component("features") { # TODO(crbug.com/1091985): Support CrOS. if (is_win || is_mac || (is_linux || is_chromeos_lacros)) { - static_library("pixel_diff_test_support") { + jumbo_static_library("pixel_diff_test_support") { testonly = true sources = [ "test/skia_gold_matching_algorithm.cc", @@ -733,7 +734,7 @@ if (!is_ios) { } } -static_library("test_support") { +jumbo_static_library("test_support") { testonly = true sources = [ "interaction/element_test_util.cc", diff --git a/chromium/ui/base/clipboard/BUILD.gn b/chromium/ui/base/clipboard/BUILD.gn index 5e6fd124369..1723a6dff1d 100644 --- a/chromium/ui/base/clipboard/BUILD.gn +++ b/chromium/ui/base/clipboard/BUILD.gn @@ -4,9 +4,10 @@ import("///build/config/ozone.gni") import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//build/config/ui.gni") -component("clipboard_types") { +jumbo_component("clipboard_types") { output_name = "ui_base_clipboard_types" sources = [ "clipboard_buffer.h", @@ -66,7 +67,7 @@ component("file_info") { deps = [ "//base" ] } -component("clipboard") { +jumbo_component("clipboard") { output_name = "ui_base_clipboard" sources = [ @@ -187,7 +188,7 @@ component("clipboard") { } } -source_set("clipboard_test_support") { +jumbo_source_set("clipboard_test_support") { testonly = true if (!is_ios) { diff --git a/chromium/ui/base/ime/BUILD.gn b/chromium/ui/base/ime/BUILD.gn index 3a18c6bf896..8af241832b8 100644 --- a/chromium/ui/base/ime/BUILD.gn +++ b/chromium/ui/base/ime/BUILD.gn @@ -3,6 +3,7 @@ # found in the LICENSE file. import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//build/config/ui.gni") source_set("text_input_types") { @@ -14,7 +15,7 @@ source_set("text_input_types") { ] } -component("ime_types") { +jumbo_component("ime_types") { output_name = "ui_base_ime_types" sources = [ "candidate_window.cc", @@ -54,7 +55,7 @@ component("ime_types") { } } -component("ime") { +jumbo_component("ime") { output_name = "ui_base_ime" sources = [ "constants.cc", diff --git a/chromium/ui/base/ime/chromeos/BUILD.gn b/chromium/ui/base/ime/chromeos/BUILD.gn index 76365cbeb06..a7d7d687011 100644 --- a/chromium/ui/base/ime/chromeos/BUILD.gn +++ b/chromium/ui/base/ime/chromeos/BUILD.gn @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/chromeos/ui_mode.gni") assert(is_chromeos_ash) @@ -22,7 +23,7 @@ source_set("typing_session_manager") { ] } -component("chromeos") { +jumbo_component("chromeos") { output_name = "ui_base_ime_chromeos" sources = [ diff --git a/chromium/ui/base/ime/fuchsia/BUILD.gn b/chromium/ui/base/ime/fuchsia/BUILD.gn index 1b98ae14b06..c79a013d50c 100644 --- a/chromium/ui/base/ime/fuchsia/BUILD.gn +++ b/chromium/ui/base/ime/fuchsia/BUILD.gn @@ -2,9 +2,11 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") + assert(is_fuchsia) -component("fuchsia") { +jumbo_component("fuchsia") { output_name = "ui_base_ime_fuchsia" sources = [ diff --git a/chromium/ui/base/ime/init/BUILD.gn b/chromium/ui/base/ime/init/BUILD.gn index 28dda76ff0d..5c295864f0c 100644 --- a/chromium/ui/base/ime/init/BUILD.gn +++ b/chromium/ui/base/ime/init/BUILD.gn @@ -3,9 +3,10 @@ # found in the LICENSE file. import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//build/config/ui.gni") -component("init") { +jumbo_component("init") { output_name = "ui_base_ime_init" sources = [ diff --git a/chromium/ui/base/ime/linux/BUILD.gn b/chromium/ui/base/ime/linux/BUILD.gn index 77452cf14f9..9b2dcc7274c 100644 --- a/chromium/ui/base/ime/linux/BUILD.gn +++ b/chromium/ui/base/ime/linux/BUILD.gn @@ -2,12 +2,13 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/chromeos/ui_mode.gni") import("//build/config/linux/pangocairo/pangocairo.gni") assert(is_linux || is_chromeos_lacros) -component("linux") { +jumbo_component("linux") { output_name = "ui_base_ime_linux" sources = [ "fake_input_method_context.cc", diff --git a/chromium/ui/base/ime/mac/BUILD.gn b/chromium/ui/base/ime/mac/BUILD.gn index df1698a7b5c..41edb78b381 100644 --- a/chromium/ui/base/ime/mac/BUILD.gn +++ b/chromium/ui/base/ime/mac/BUILD.gn @@ -2,9 +2,11 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") + assert(is_mac) -component("mac") { +jumbo_component("mac") { output_name = "ui_base_ime_mac" sources = [ diff --git a/chromium/ui/base/ime/win/BUILD.gn b/chromium/ui/base/ime/win/BUILD.gn index 13d94842f69..b6cb95fcf81 100644 --- a/chromium/ui/base/ime/win/BUILD.gn +++ b/chromium/ui/base/ime/win/BUILD.gn @@ -2,9 +2,11 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") + assert(is_win) -component("win") { +jumbo_component("win") { output_name = "ui_base_ime_win" sources = [ "imm32_manager.cc", diff --git a/chromium/ui/base/prediction/BUILD.gn b/chromium/ui/base/prediction/BUILD.gn index bfd837c7b7e..f9abf4c09d5 100644 --- a/chromium/ui/base/prediction/BUILD.gn +++ b/chromium/ui/base/prediction/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -component("prediction") { +import("//build/config/jumbo.gni") + +jumbo_component("prediction") { sources = [ "empty_filter.cc", "empty_filter.h", diff --git a/chromium/ui/base/x/BUILD.gn b/chromium/ui/base/x/BUILD.gn index 97e767b1c7d..338055d94df 100644 --- a/chromium/ui/base/x/BUILD.gn +++ b/chromium/ui/base/x/BUILD.gn @@ -2,13 +2,14 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/linux/gtk/gtk.gni") import("//build/config/ozone.gni") import("//build/config/ui.gni") assert(use_x11 || ozone_platform_x11) -component("x") { +jumbo_component("x") { output_name = "ui_base_x" sources = [ diff --git a/chromium/ui/color/BUILD.gn b/chromium/ui/color/BUILD.gn index b0c1eba7fed..71daf9741bb 100644 --- a/chromium/ui/color/BUILD.gn +++ b/chromium/ui/color/BUILD.gn @@ -4,6 +4,7 @@ import("//build/buildflag_header.gni") import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//testing/test.gni") import("//ui/base/ui_features.gni") @@ -24,7 +25,7 @@ source_set("color_headers") { ] } -component("color") { +jumbo_component("color") { sources = [ "color_mixer.cc", "color_provider.cc", @@ -77,7 +78,7 @@ test("color_unittests") { ] } -component("mixers") { +jumbo_component("mixers") { sources = [ "color_mixers.h", "color_provider_manager.cc", diff --git a/chromium/ui/compositor/BUILD.gn b/chromium/ui/compositor/BUILD.gn index 9f3cca807e0..acc6b1eb792 100644 --- a/chromium/ui/compositor/BUILD.gn +++ b/chromium/ui/compositor/BUILD.gn @@ -2,10 +2,11 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//testing/test.gni") -component("compositor") { +jumbo_component("compositor") { sources = [ "animation_throughput_reporter.cc", "animation_throughput_reporter.h", @@ -117,7 +118,7 @@ component("compositor") { } } -static_library("test_support") { +jumbo_static_library("test_support") { testonly = true sources = [ "test/animation_throughput_reporter_test_base.cc", diff --git a/chromium/ui/display/BUILD.gn b/chromium/ui/display/BUILD.gn index b0890b9ffcd..a3162f37dec 100644 --- a/chromium/ui/display/BUILD.gn +++ b/chromium/ui/display/BUILD.gn @@ -3,11 +3,12 @@ # found in the LICENSE file. import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//testing/test.gni") import("//ui/display/display.gni") -component("display") { +jumbo_component("display") { sources = [ "display.cc", "display.h", @@ -136,7 +137,7 @@ component("display_manager_test_api") { ] } -static_library("test_support") { +jumbo_static_library("test_support") { testonly = true sources = [ "test/display_matchers.cc", diff --git a/chromium/ui/display/fake/BUILD.gn b/chromium/ui/display/fake/BUILD.gn index 9617ef1ff0e..69771bf685b 100644 --- a/chromium/ui/display/fake/BUILD.gn +++ b/chromium/ui/display/fake/BUILD.gn @@ -2,11 +2,12 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/ui.gni") # This target contains dummy or fake classes that can be used as # placeholders when lacking something better, or for testing. -component("fake") { +jumbo_component("fake") { sources = [ "fake_display_delegate.cc", "fake_display_delegate.h", diff --git a/chromium/ui/display/manager/BUILD.gn b/chromium/ui/display/manager/BUILD.gn index 189edadd577..fd52da4e525 100644 --- a/chromium/ui/display/manager/BUILD.gn +++ b/chromium/ui/display/manager/BUILD.gn @@ -3,10 +3,11 @@ # found in the LICENSE file. import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//ui/display/display.gni") -component("manager") { +jumbo_component("manager") { sources = [ "display_layout_store.cc", "display_layout_store.h", diff --git a/chromium/ui/display/types/BUILD.gn b/chromium/ui/display/types/BUILD.gn index 5d42d9c73ed..86ea7b44df1 100644 --- a/chromium/ui/display/types/BUILD.gn +++ b/chromium/ui/display/types/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -component("types") { +import("//build/config/jumbo.gni") + +jumbo_component("types") { output_name = "display_types" sources = [ "display_configuration_params.cc", diff --git a/chromium/ui/display/util/BUILD.gn b/chromium/ui/display/util/BUILD.gn index cdd6988ef1a..d00ed7ea328 100644 --- a/chromium/ui/display/util/BUILD.gn +++ b/chromium/ui/display/util/BUILD.gn @@ -3,10 +3,11 @@ # found in the LICENSE file. import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//testing/libfuzzer/fuzzer_test.gni") -component("util") { +jumbo_component("util") { output_name = "display_util" sources = [ "display_util.cc", diff --git a/chromium/ui/events/BUILD.gn b/chromium/ui/events/BUILD.gn index 82b8ba7a5e0..c9980450579 100644 --- a/chromium/ui/events/BUILD.gn +++ b/chromium/ui/events/BUILD.gn @@ -3,6 +3,7 @@ # found in the LICENSE file. import("//build/config/features.gni") +import("//build/config/jumbo.gni") import("//build/config/ozone.gni") import("//build/config/ui.gni") import("//testing/test.gni") @@ -16,7 +17,7 @@ if (is_ios) { import("//ios/build/config.gni") } -static_library("dom_keycode_converter") { +jumbo_static_library("dom_keycode_converter") { public = [ "keycodes/dom/dom_code.h", "keycodes/dom/dom_codes.h", @@ -92,7 +93,7 @@ source_set("platform_event") { sources = [ "platform_event.h" ] } -component("events_base") { +jumbo_component("events_base") { sources = [ "base_event_utils.cc", "base_event_utils.h", @@ -190,7 +191,7 @@ component("events_base") { } } -component("events") { +jumbo_component("events") { public = [ "cocoa/cocoa_event_utils.h", "event.h", @@ -375,7 +376,7 @@ component("events") { } } -component("keyboard_hook") { +jumbo_component("keyboard_hook") { public = [ "keyboard_hook.h" ] defines = [ "IS_KEYBOARD_HOOK_IMPL" ] @@ -449,7 +450,7 @@ component("keyboard_hook") { } } -component("gesture_detection") { +jumbo_component("gesture_detection") { sources = [ "gesture_detection/bitset_32.h", "gesture_detection/filtered_gesture_provider.cc", @@ -514,7 +515,7 @@ component("gesture_detection") { } } -static_library("test_support") { +jumbo_static_library("test_support") { sources = [ "test/event_generator.cc", "test/event_generator.h", diff --git a/chromium/ui/events/blink/BUILD.gn b/chromium/ui/events/blink/BUILD.gn index bfe2424fdf5..2ff0353b00c 100644 --- a/chromium/ui/events/blink/BUILD.gn +++ b/chromium/ui/events/blink/BUILD.gn @@ -2,9 +2,10 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/ui.gni") -component("blink_features") { +jumbo_component("blink_features") { defines = [ "IS_BLINK_FEATURES_IMPL" ] sources = [ @@ -15,7 +16,7 @@ component("blink_features") { deps = [ "//base" ] } -source_set("blink") { +jumbo_source_set("blink") { sources = [ "blink_event_util.cc", "blink_event_util.h", diff --git a/chromium/ui/events/devices/BUILD.gn b/chromium/ui/events/devices/BUILD.gn index bcd753dbb7d..427b658993a 100644 --- a/chromium/ui/events/devices/BUILD.gn +++ b/chromium/ui/events/devices/BUILD.gn @@ -2,12 +2,14 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") + if (is_android) { import("//build/config/android/config.gni") import("//build/config/android/rules.gni") } -component("devices") { +jumbo_component("devices") { sources = [ "device_data_manager.cc", "device_data_manager.h", diff --git a/chromium/ui/events/devices/x11/BUILD.gn b/chromium/ui/events/devices/x11/BUILD.gn index 6db5a3908b2..0a9f0f2b807 100644 --- a/chromium/ui/events/devices/x11/BUILD.gn +++ b/chromium/ui/events/devices/x11/BUILD.gn @@ -2,12 +2,13 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/ozone.gni") import("//build/config/ui.gni") assert(use_x11 || ozone_platform_x11) -component("x11") { +jumbo_component("x11") { output_name = "events_devices_x11" sources = [ diff --git a/chromium/ui/events/ipc/BUILD.gn b/chromium/ui/events/ipc/BUILD.gn index f82291ca2a5..378eca46614 100644 --- a/chromium/ui/events/ipc/BUILD.gn +++ b/chromium/ui/events/ipc/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -component("ipc") { +import("//build/config/jumbo.gni") + +jumbo_component("ipc") { output_name = "ui_events_ipc" sources = [ diff --git a/chromium/ui/events/keycodes/BUILD.gn b/chromium/ui/events/keycodes/BUILD.gn index 65159056e44..726296e5b98 100644 --- a/chromium/ui/events/keycodes/BUILD.gn +++ b/chromium/ui/events/keycodes/BUILD.gn @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/linux/pkg_config.gni") import("//build/config/ozone.gni") import("//build/config/ui.gni") @@ -13,7 +14,7 @@ if (use_xkbcommon) { } } -source_set("xkb") { +jumbo_source_set("xkb") { configs += [ ":xkbcommon" ] sources = [ @@ -36,7 +37,7 @@ source_set("xkb") { } if (use_x11 || ozone_platform_x11) { - component("x11") { + jumbo_component("x11") { output_name = "keycodes_x11" configs += [ ":xkbcommon" ] diff --git a/chromium/ui/events/platform/BUILD.gn b/chromium/ui/events/platform/BUILD.gn index 64efb0bbc34..dfceb31d1de 100644 --- a/chromium/ui/events/platform/BUILD.gn +++ b/chromium/ui/events/platform/BUILD.gn @@ -2,9 +2,10 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/ui.gni") -component("platform") { +jumbo_component("platform") { sources = [ # Allow this target to include events_export.h without depending on the # events target (which would be circular). diff --git a/chromium/ui/events/platform/x11/BUILD.gn b/chromium/ui/events/platform/x11/BUILD.gn index 46ccb75c71b..a5c349ddc80 100644 --- a/chromium/ui/events/platform/x11/BUILD.gn +++ b/chromium/ui/events/platform/x11/BUILD.gn @@ -3,12 +3,13 @@ # found in the LICENSE file. import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//build/config/ozone.gni") import("//build/config/ui.gni") assert(use_x11 || ozone_platform_x11) -component("x11") { +jumbo_component("x11") { output_name = "x11_events_platform" sources = [ diff --git a/chromium/ui/gfx/BUILD.gn b/chromium/ui/gfx/BUILD.gn index 86c3f048c63..0c2c4e647a1 100644 --- a/chromium/ui/gfx/BUILD.gn +++ b/chromium/ui/gfx/BUILD.gn @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/ozone.gni") import("//build/config/ui.gni") import("//device/vr/buildflags/buildflags.gni") @@ -22,7 +23,7 @@ source_set("gfx_export") { } # Used for color generation at build time without importing all the gfx. -component("color_utils") { +jumbo_component("color_utils") { sources = [ "color_palette.h", "color_utils.cc", @@ -37,7 +38,7 @@ component("color_utils") { ] } -component("geometry_skia") { +jumbo_component("geometry_skia") { sources = [ "geometry_skia_export.h", "mask_filter_info.cc", @@ -66,7 +67,7 @@ component("geometry_skia") { defines = [ "GEOMETRY_SKIA_IMPLEMENTATION" ] } -component("gfx") { +jumbo_component("gfx") { sources = [ "break_list.h", "color_analysis.cc", @@ -432,7 +433,7 @@ component("gfx") { } } -component("color_space") { +jumbo_component("color_space") { sources = [ "color_space.cc", "color_space.h", @@ -544,7 +545,7 @@ group("memory_buffer") { } # Cannot be a static_library in component builds due to exported functions -source_set("memory_buffer_sources") { +jumbo_source_set("memory_buffer_sources") { visibility = [ ":*" ] # Depend on through ":memory_buffer". # TODO(brettw) refactor this so these sources are in a coherent directory @@ -633,7 +634,7 @@ source_set("memory_buffer_sources") { } # TODO(ccameron): This can be moved into a separate source_set. -component("gfx_switches") { +jumbo_component("gfx_switches") { sources = [ "switches.cc", "switches.h", @@ -645,7 +646,7 @@ component("gfx_switches") { deps = [ "//base" ] } -static_library("test_support") { +jumbo_static_library("test_support") { testonly = true sources = [ "animation/animation_test_api.cc", diff --git a/chromium/ui/gfx/animation/BUILD.gn b/chromium/ui/gfx/animation/BUILD.gn index e544b0972f9..a08b3465255 100644 --- a/chromium/ui/gfx/animation/BUILD.gn +++ b/chromium/ui/gfx/animation/BUILD.gn @@ -3,6 +3,7 @@ # found in the LICENSE file. import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//build/config/ui.gni") if (is_android) { @@ -10,7 +11,7 @@ if (is_android) { import("//build/config/android/rules.gni") } -component("animation") { +jumbo_component("animation") { sources = [ "animation.cc", "animation.h", diff --git a/chromium/ui/gfx/codec/BUILD.gn b/chromium/ui/gfx/codec/BUILD.gn index 8b002e0aa13..45fa24ee9db 100644 --- a/chromium/ui/gfx/codec/BUILD.gn +++ b/chromium/ui/gfx/codec/BUILD.gn @@ -2,9 +2,10 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/ui.gni") -component("codec") { +jumbo_component("codec") { sources = [ "codec_export.h", "jpeg_codec.cc", diff --git a/chromium/ui/gfx/geometry/BUILD.gn b/chromium/ui/gfx/geometry/BUILD.gn index 3f83f70106d..94394222dc2 100644 --- a/chromium/ui/gfx/geometry/BUILD.gn +++ b/chromium/ui/gfx/geometry/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -component("geometry") { +import("//build/config/jumbo.gni") + +jumbo_component("geometry") { sources = [ "../gfx_export.h", "angle_conversions.h", diff --git a/chromium/ui/gfx/ipc/BUILD.gn b/chromium/ui/gfx/ipc/BUILD.gn index 547aadde8c3..b1b9af7c3ff 100644 --- a/chromium/ui/gfx/ipc/BUILD.gn +++ b/chromium/ui/gfx/ipc/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -component("ipc") { +import("//build/config/jumbo.gni") + +jumbo_component("ipc") { output_name = "gfx_ipc" sources = [ diff --git a/chromium/ui/gfx/ipc/buffer_types/BUILD.gn b/chromium/ui/gfx/ipc/buffer_types/BUILD.gn index 3cf5eca77f3..a1c2234f0bb 100644 --- a/chromium/ui/gfx/ipc/buffer_types/BUILD.gn +++ b/chromium/ui/gfx/ipc/buffer_types/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -component("buffer_types") { +import("//build/config/jumbo.gni") + +jumbo_component("buffer_types") { output_name = "gfx_ipc_buffer_types" sources = [ diff --git a/chromium/ui/gfx/ipc/color/BUILD.gn b/chromium/ui/gfx/ipc/color/BUILD.gn index a9ab0323013..9a3428ad414 100644 --- a/chromium/ui/gfx/ipc/color/BUILD.gn +++ b/chromium/ui/gfx/ipc/color/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -component("color") { +import("//build/config/jumbo.gni") + +jumbo_component("color") { output_name = "gfx_ipc_color" sources = [ diff --git a/chromium/ui/gfx/ipc/geometry/BUILD.gn b/chromium/ui/gfx/ipc/geometry/BUILD.gn index b8796b222cc..bd57c70f3e5 100644 --- a/chromium/ui/gfx/ipc/geometry/BUILD.gn +++ b/chromium/ui/gfx/ipc/geometry/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -component("geometry") { +import("//build/config/jumbo.gni") + +jumbo_component("geometry") { output_name = "gfx_ipc_geometry" sources = [ diff --git a/chromium/ui/gfx/ipc/skia/BUILD.gn b/chromium/ui/gfx/ipc/skia/BUILD.gn index fcb670e0225..2e4df260f7a 100644 --- a/chromium/ui/gfx/ipc/skia/BUILD.gn +++ b/chromium/ui/gfx/ipc/skia/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -component("skia") { +import("//build/config/jumbo.gni") + +jumbo_component("skia") { output_name = "gfx_ipc_skia" sources = [ diff --git a/chromium/ui/gfx/range/BUILD.gn b/chromium/ui/gfx/range/BUILD.gn index d150518b592..26d1a313ab3 100644 --- a/chromium/ui/gfx/range/BUILD.gn +++ b/chromium/ui/gfx/range/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -component("range") { +import("//build/config/jumbo.gni") + +jumbo_component("range") { sources = [ "gfx_range_export.h", "range.cc", diff --git a/chromium/ui/gfx/x/BUILD.gn b/chromium/ui/gfx/x/BUILD.gn index 87ce467eda0..2f095d33892 100644 --- a/chromium/ui/gfx/x/BUILD.gn +++ b/chromium/ui/gfx/x/BUILD.gn @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/ozone.gni") import("//build/config/ui.gni") import("//tools/generate_library_loader/generate_library_loader.gni") @@ -189,7 +190,7 @@ source_set("xproto") { libs = [ "xcb" ] } -component("x") { +jumbo_component("x") { output_name = "gfx_x11" sources = [ diff --git a/chromium/ui/gl/BUILD.gn b/chromium/ui/gl/BUILD.gn index 67cff458127..6cdcd9d91d5 100644 --- a/chromium/ui/gl/BUILD.gn +++ b/chromium/ui/gl/BUILD.gn @@ -6,6 +6,7 @@ import("//build/buildflag_header.gni") import("//build/config/chrome_build.gni") import("//build/config/chromecast_build.gni") import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//build/config/linux/pkg_config.gni") import("//build/config/ozone.gni") import("//build/config/ui.gni") @@ -46,7 +47,7 @@ config("gl_config") { } } -component("gl") { +jumbo_component("gl") { output_name = "gl_wrapper" # Avoid colliding with OS X"s libGL.dylib. sources = [ @@ -488,7 +489,7 @@ if (is_mac && use_egl) { } } -static_library("gl_unittest_utils") { +jumbo_static_library("gl_unittest_utils") { testonly = true sources = [ "egl_bindings_autogen_mock.cc", @@ -514,7 +515,7 @@ static_library("gl_unittest_utils") { ] } -static_library("test_support") { +jumbo_static_library("test_support") { testonly = true sources = [ "test/gl_image_bind_test_template.h", diff --git a/chromium/ui/gl/init/BUILD.gn b/chromium/ui/gl/init/BUILD.gn index 62763048aff..2d6c7c2b152 100644 --- a/chromium/ui/gl/init/BUILD.gn +++ b/chromium/ui/gl/init/BUILD.gn @@ -2,10 +2,11 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//ui/gl/features.gni") -component("init") { +jumbo_component("init") { output_name = "gl_init" public = [ diff --git a/chromium/ui/gtk/BUILD.gn b/chromium/ui/gtk/BUILD.gn index 7bdb5a0e439..3c33fb86881 100644 --- a/chromium/ui/gtk/BUILD.gn +++ b/chromium/ui/gtk/BUILD.gn @@ -4,6 +4,7 @@ import("//build/config/chromeos/ui_mode.gni") import("//build/config/features.gni") +import("//build/config/jumbo.gni") import("//build/config/ozone.gni") import("//build/config/ui.gni") import("//printing/buildflags/buildflags.gni") @@ -38,9 +39,8 @@ generate_stubs("gtk_stubs") { logging_include = "ui/gtk/log_noop.h" } -component("gtk") { +jumbo_component("gtk") { public = [ "gtk_ui_factory.h" ] - sources = [ "gtk_color_mixers.cc", "gtk_color_mixers.h", diff --git a/chromium/ui/latency/BUILD.gn b/chromium/ui/latency/BUILD.gn index 5130c405ed9..c6bca8391a0 100644 --- a/chromium/ui/latency/BUILD.gn +++ b/chromium/ui/latency/BUILD.gn @@ -2,9 +2,10 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//testing/test.gni") -source_set("latency") { +jumbo_source_set("latency") { sources = [ "latency_histogram_macros.h", "latency_info.cc", @@ -22,7 +23,7 @@ source_set("latency") { public_deps = [ "//services/metrics/public/cpp:metrics_cpp" ] } -source_set("test_support") { +jumbo_source_set("test_support") { testonly = true sources = [ "latency_info_test_support.cc" ] diff --git a/chromium/ui/message_center/BUILD.gn b/chromium/ui/message_center/BUILD.gn index 807e24d9bba..273e975683c 100644 --- a/chromium/ui/message_center/BUILD.gn +++ b/chromium/ui/message_center/BUILD.gn @@ -3,6 +3,7 @@ # found in the LICENSE file. import("//build/config/features.gni") +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//components/vector_icons/vector_icons.gni") import("//testing/test.gni") @@ -23,7 +24,7 @@ aggregate_vector_icons("message_center_vector_icons") { } # TODO(msw|mukai|dewittj): Move ash-specific files: crbug.com/585175 -component("message_center") { +jumbo_component("message_center") { deps = [ "//base", "//build:chromeos_buildflags", diff --git a/chromium/ui/message_center/public/cpp/BUILD.gn b/chromium/ui/message_center/public/cpp/BUILD.gn index 54fd58f025e..cbe5d10d4fb 100644 --- a/chromium/ui/message_center/public/cpp/BUILD.gn +++ b/chromium/ui/message_center/public/cpp/BUILD.gn @@ -2,8 +2,10 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") + # C++ headers and sources that can be used outside message_center. -component("cpp") { +jumbo_component("cpp") { output_name = "ui_message_center_cpp" sources = [ diff --git a/chromium/ui/native_theme/BUILD.gn b/chromium/ui/native_theme/BUILD.gn index 92f10160c2c..1748f087568 100644 --- a/chromium/ui/native_theme/BUILD.gn +++ b/chromium/ui/native_theme/BUILD.gn @@ -2,10 +2,11 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//testing/test.gni") -component("native_theme") { +jumbo_component("native_theme") { sources = [ "caption_style.cc", "caption_style.h", @@ -86,7 +87,7 @@ component("native_theme") { } if (is_win) { - component("native_theme_browser") { + jumbo_component("native_theme_browser") { defines = [ "NATIVE_THEME_IMPLEMENTATION" ] # These files cannot work in the renderer on Windows. @@ -107,11 +108,11 @@ if (is_win) { libs = [ "uxtheme.lib" ] } } else { - source_set("native_theme_browser") { + jumbo_source_set("native_theme_browser") { } } -source_set("test_support") { +jumbo_source_set("test_support") { testonly = true deps = [ diff --git a/chromium/ui/ozone/BUILD.gn b/chromium/ui/ozone/BUILD.gn index 8e3445e6cb0..65d0b86d9f7 100644 --- a/chromium/ui/ozone/BUILD.gn +++ b/chromium/ui/ozone/BUILD.gn @@ -3,6 +3,7 @@ # found in the LICENSE file. import("//build/buildflag_header.gni") +import("//build/config/jumbo.gni") import("//build/config/ozone.gni") import("//build/config/python.gni") import("//build/config/ui.gni") @@ -73,7 +74,7 @@ constructor_list_cc_file = "$target_gen_dir/constructor_list.cc" test_constructor_list_cc_file = "$target_gen_dir/test_constructor_list.cc" -component("ozone_base") { +jumbo_component("ozone_base") { sources = [ "public/gl_ozone.h", "public/gpu_platform_support_host.cc", @@ -222,7 +223,7 @@ source_set("platform") { visibility += ozone_external_platform_visibility } -component("ozone") { +jumbo_component("ozone") { visibility = [] visibility = [ "*" ] public_deps = [ @@ -232,7 +233,7 @@ component("ozone") { ] } -source_set("test_support_internal") { +jumbo_source_set("test_support_internal") { testonly = true sources = [ @@ -255,7 +256,7 @@ source_set("test_support_internal") { public_deps = [ "//base/test:test_support" ] } -static_library("ui_test_support") { +jumbo_static_library("ui_test_support") { visibility = [] visibility = [ "//ui/views:test_support" ] @@ -282,7 +283,7 @@ static_library("ui_test_support") { allow_circular_includes_from = ozone_platform_ui_test_support_deps } -static_library("test_support") { +jumbo_static_library("test_support") { visibility = [] visibility = [ ":*", diff --git a/chromium/ui/platform_window/stub/BUILD.gn b/chromium/ui/platform_window/stub/BUILD.gn index fd53cfe9258..55cff46168e 100644 --- a/chromium/ui/platform_window/stub/BUILD.gn +++ b/chromium/ui/platform_window/stub/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -component("stub") { +import("//build/config/jumbo.gni") + +jumbo_component("stub") { output_name = "stub_window" deps = [ diff --git a/chromium/ui/platform_window/win/BUILD.gn b/chromium/ui/platform_window/win/BUILD.gn index bf545a46ddb..fd1df29943c 100644 --- a/chromium/ui/platform_window/win/BUILD.gn +++ b/chromium/ui/platform_window/win/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -component("win") { +import("//build/config/jumbo.gni") + +jumbo_component("win") { output_name = "win_window" deps = [ diff --git a/chromium/ui/platform_window/x11/BUILD.gn b/chromium/ui/platform_window/x11/BUILD.gn index 72bce1f107e..9d1b9ee1054 100644 --- a/chromium/ui/platform_window/x11/BUILD.gn +++ b/chromium/ui/platform_window/x11/BUILD.gn @@ -2,13 +2,14 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/ozone.gni") import("//build/config/ui.gni") import("//testing/test.gni") assert(use_x11 || ozone_platform_x11) -component("x11") { +jumbo_component("x11") { output_name = "x11_window" deps = [ diff --git a/chromium/ui/resources/BUILD.gn b/chromium/ui/resources/BUILD.gn index 1182b83714b..c6183683d39 100644 --- a/chromium/ui/resources/BUILD.gn +++ b/chromium/ui/resources/BUILD.gn @@ -3,6 +3,7 @@ # found in the LICENSE file. import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//tools/grit/grit_rule.gni") import("//tools/grit/repack.gni") import("//ui/webui/webui_features.gni") diff --git a/chromium/ui/shell_dialogs/BUILD.gn b/chromium/ui/shell_dialogs/BUILD.gn index a7ef6364dc0..bd8730b5c5f 100644 --- a/chromium/ui/shell_dialogs/BUILD.gn +++ b/chromium/ui/shell_dialogs/BUILD.gn @@ -3,6 +3,7 @@ # found in the LICENSE file. import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//testing/test.gni") if (is_android) { @@ -12,7 +13,7 @@ if (is_mac) { import("//build/config/mac/rules.gni") } -component("shell_dialogs") { +jumbo_component("shell_dialogs") { sources = [ "base_shell_dialog.cc", "base_shell_dialog.h", diff --git a/chromium/ui/snapshot/BUILD.gn b/chromium/ui/snapshot/BUILD.gn index 22e747c9efe..efef82e32f3 100644 --- a/chromium/ui/snapshot/BUILD.gn +++ b/chromium/ui/snapshot/BUILD.gn @@ -2,10 +2,11 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//testing/test.gni") -component("snapshot") { +jumbo_component("snapshot") { sources = [ "screenshot_grabber.cc", "screenshot_grabber.h", @@ -79,7 +80,7 @@ component("snapshot") { } } -source_set("snapshot_export") { +jumbo_source_set("snapshot_export") { sources = [ "snapshot_export.h" ] visibility = [ ":*" ] } diff --git a/chromium/ui/surface/BUILD.gn b/chromium/ui/surface/BUILD.gn index e7e9468b21c..3293e4d3310 100644 --- a/chromium/ui/surface/BUILD.gn +++ b/chromium/ui/surface/BUILD.gn @@ -2,9 +2,10 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/ui.gni") -component("surface") { +jumbo_component("surface") { sources = [ "surface_export.h", "transport_dib.cc", diff --git a/chromium/ui/touch_selection/BUILD.gn b/chromium/ui/touch_selection/BUILD.gn index 952c6140775..22bea907648 100644 --- a/chromium/ui/touch_selection/BUILD.gn +++ b/chromium/ui/touch_selection/BUILD.gn @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//testing/test.gni") @@ -9,7 +10,7 @@ if (is_android) { import("//build/config/android/rules.gni") } -component("touch_selection") { +jumbo_component("touch_selection") { output_name = "ui_touch_selection" sources = [ diff --git a/chromium/ui/views/BUILD.gn b/chromium/ui/views/BUILD.gn index 90e851c1c61..500334b3b79 100644 --- a/chromium/ui/views/BUILD.gn +++ b/chromium/ui/views/BUILD.gn @@ -5,6 +5,7 @@ import("//build/buildflag_header.gni") import("//build/config/chromeos/ui_mode.gni") import("//build/config/features.gni") +import("//build/config/jumbo.gni") import("//build/config/ozone.gni") import("//build/config/ui.gni") import("//components/vector_icons/vector_icons.gni") @@ -52,7 +53,7 @@ buildflag_header("buildflags") { flags = [ "ENABLE_DESKTOP_AURA=$enable_desktop_aura" ] } -component("views") { +jumbo_component("views") { all_dependent_configs = [ ":flags" ] public = [ @@ -893,7 +894,7 @@ component("views") { } } -source_set("test_support") { +jumbo_source_set("test_support") { testonly = true sources = [ "animation/test/flood_fill_ink_drop_ripple_test_api.cc", diff --git a/chromium/ui/views/controls/webview/BUILD.gn b/chromium/ui/views/controls/webview/BUILD.gn index e4a99da2620..9072004640e 100644 --- a/chromium/ui/views/controls/webview/BUILD.gn +++ b/chromium/ui/views/controls/webview/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -component("webview") { +import("//build/config/jumbo.gni") + +jumbo_component("webview") { sources = [ "unhandled_keyboard_event_handler.cc", "unhandled_keyboard_event_handler.h", diff --git a/chromium/ui/views/examples/BUILD.gn b/chromium/ui/views/examples/BUILD.gn index 348ea49ddc7..2cae2b40160 100644 --- a/chromium/ui/views/examples/BUILD.gn +++ b/chromium/ui/views/examples/BUILD.gn @@ -3,11 +3,12 @@ # found in the LICENSE file. import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//testing/test.gni") import("//tools/grit/grit_rule.gni") -component("views_examples_lib") { +jumbo_component("views_examples_lib") { testonly = true sources = [ @@ -201,7 +202,7 @@ executable("views_examples") { ] } -component("views_examples_with_content_lib") { +jumbo_component("views_examples_with_content_lib") { testonly = true sources = [ "examples_window_with_content.cc", diff --git a/chromium/ui/views_content_client/BUILD.gn b/chromium/ui/views_content_client/BUILD.gn index bee5a733d2d..ad76960f0fc 100644 --- a/chromium/ui/views_content_client/BUILD.gn +++ b/chromium/ui/views_content_client/BUILD.gn @@ -3,9 +3,10 @@ # found in the LICENSE file. import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//build/config/ui.gni") -component("views_content_client") { +jumbo_component("views_content_client") { testonly = true sources = [ "views_content_browser_client.cc", diff --git a/chromium/ui/web_dialogs/BUILD.gn b/chromium/ui/web_dialogs/BUILD.gn index 154bfb21454..b70a755c3b9 100644 --- a/chromium/ui/web_dialogs/BUILD.gn +++ b/chromium/ui/web_dialogs/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -component("web_dialogs") { +import("//build/config/jumbo.gni") + +jumbo_component("web_dialogs") { sources = [ "web_dialog_delegate.cc", "web_dialog_delegate.h", @@ -31,7 +33,7 @@ component("web_dialogs") { } } -static_library("test_support") { +jumbo_static_library("test_support") { sources = [ "test/test_web_contents_handler.cc", "test/test_web_contents_handler.h", diff --git a/chromium/ui/wm/BUILD.gn b/chromium/ui/wm/BUILD.gn index f92f96279d8..bbf1b7e5003 100644 --- a/chromium/ui/wm/BUILD.gn +++ b/chromium/ui/wm/BUILD.gn @@ -3,10 +3,11 @@ # found in the LICENSE file. import("//build/config/chromeos/ui_mode.gni") +import("//build/config/jumbo.gni") import("//build/config/ui.gni") import("//testing/test.gni") -component("wm") { +jumbo_component("wm") { sources = [ "core/accelerator_delegate.h", "core/accelerator_filter.cc", @@ -95,7 +96,7 @@ component("wm") { } } -static_library("test_support") { +jumbo_static_library("test_support") { testonly = true sources = [ "test/testing_cursor_client_observer.cc", diff --git a/chromium/ui/wm/public/BUILD.gn b/chromium/ui/wm/public/BUILD.gn index b4ae9394e3a..799fb90a7b7 100644 --- a/chromium/ui/wm/public/BUILD.gn +++ b/chromium/ui/wm/public/BUILD.gn @@ -2,7 +2,9 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. -component("public") { +import("//build/config/jumbo.gni") + +jumbo_component("public") { output_name = "wm_public" public = [ diff --git a/chromium/v8/BUILD.gn b/chromium/v8/BUILD.gn index 2ca06e03d81..a627da29ec7 100644 --- a/chromium/v8/BUILD.gn +++ b/chromium/v8/BUILD.gn @@ -6,6 +6,7 @@ import("//build/config/android/config.gni") import("//build/config/arm.gni") import("//build/config/dcheck_always_on.gni") import("//build/config/host_byteorder.gni") +import("//build/config/jumbo.gni") import("//build/config/mips.gni") import("//build/config/sanitizers/sanitizers.gni") import("//build_overrides/build.gni") @@ -2015,8 +2016,13 @@ v8_source_set("v8_snapshot") { if (emit_builtins_as_inline_asm) { deps += [ ":asm_to_inline_asm_trusted" ] sources += [ "$target_gen_dir/embedded_trusted.cc" ] + jumbo_excluded_sources = [ "$target_gen_dir/embedded_trusted.cc" ] } else { sources += [ "$target_gen_dir/embedded_trusted.S" ] + jumbo_excluded_sources = [ + # Duplicated symbols with embedded.S + "$target_gen_dir/embedded_trusted.S", + ] } } } else { @@ -2122,6 +2128,17 @@ v8_source_set("v8_initializers") { ] } + jumbo_excluded_sources = [ + # TODO(mostynb@vewd.com): don't exclude these http://crbug.com/752428 + "src/builtins/builtins-async-iterator-gen.cc", + "src/builtins/builtins-async-generator-gen.cc", + + # These source files take an unusually large amount of time to + # compile. Build them separately to avoid bottlenecks. + "src/builtins/builtins-regexp-gen.cc", + "src/codegen/code-stub-assembler.cc", + ] + if (v8_current_cpu == "x86") { sources += [ ### gcmole(arch:ia32) ### @@ -4117,6 +4134,23 @@ v8_source_set("v8_base_without_compiler") { ] } + jumbo_excluded_sources = [ + # TODO(mostynb@vewd.com): don't exclude these http://crbug.com/752428 + "src/profiler/heap-snapshot-generator.cc", # Macro clash in mman-linux.h + "src/heap/local-heap.cc", + "src/heap/safepoint.cc", + "src/objects/js-display-names.cc", + "src/objects/js-relative-time-format.cc", + + # These source files take an unusually large amount of time to + # compile. Build them separately to avoid bottlenecks. + "src/api/api.cc", + "src/heap/heap.cc", + "src/objects/elements.cc", + "src/objects/objects.cc", + "src/parsing/parser.cc", + ] + if (v8_current_cpu == "x86") { sources += [ ### gcmole(arch:ia32) ### "src/codegen/ia32/assembler-ia32.cc", @@ -4216,6 +4250,11 @@ v8_source_set("v8_base_without_compiler") { if (is_win) { sources += [ "src/diagnostics/unwinding-info-win64.cc" ] } + jumbo_excluded_sources += [ + # TODO(mostynb@vewd.com): fix this code so it doesn't need + # to be excluded, see the comments inside. + "src/codegen/arm64/instructions-arm64-constants.cc", + ] } else if (v8_current_cpu == "mips" || v8_current_cpu == "mipsel") { sources += [ ### gcmole(arch:mipsel) ### "src/codegen/mips/assembler-mips.cc", diff --git a/chromium/v8/gni/v8.gni b/chromium/v8/gni/v8.gni index 8741e86c087..fcd2f255112 100644 --- a/chromium/v8/gni/v8.gni +++ b/chromium/v8/gni/v8.gni @@ -2,6 +2,7 @@ # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. +import("//build/config/jumbo.gni") import("//build/config/gclient_args.gni") import("//build/config/sanitizers/sanitizers.gni") import("//build/config/v8_target_cpu.gni") @@ -201,9 +202,9 @@ template("v8_source_set") { defined(v8_static_library) && v8_static_library && is_win) { link_target_type = "split_static_library" } else if (defined(v8_static_library) && v8_static_library) { - link_target_type = "static_library" + link_target_type = "jumbo_static_library" } else { - link_target_type = "source_set" + link_target_type = "jumbo_source_set" } target(link_target_type, target_name) { forward_variables_from(invoker, @@ -222,7 +223,7 @@ template("v8_source_set") { } template("v8_header_set") { - source_set(target_name) { + jumbo_source_set(target_name) { forward_variables_from(invoker, "*", [ "configs" ]) configs -= v8_remove_configs configs += v8_add_configs diff --git a/chromium/v8/infra/mb/mb_config.pyl b/chromium/v8/infra/mb/mb_config.pyl index 9c0c933cda7..49c6385d208 100644 --- a/chromium/v8/infra/mb/mb_config.pyl +++ b/chromium/v8/infra/mb/mb_config.pyl @@ -71,6 +71,11 @@ 'V8 Linux64 - shared': 'release_x64_shared_verify_heap', 'V8 Linux64 - verify csa': 'release_x64_verify_csa', 'V8 Linux64 - no wasm - builder': 'release_x64_webassembly_disabled', + # Jumbo. + 'V8 Linux64 Jumbo': 'release_x64_jumbo', + 'V8 Linux64 Jumbo - debug': 'debug_x64_jumbo', + 'V8 Linux64 Jumbo - limited': 'release_x64_jumbo_limited', + 'V8 Linux64 Jumbo - limited - debug': 'debug_x64_jumbo_limited', # Windows. 'V8 Win32 - builder': 'release_x86_minimal_symbols', 'V8 Win32 - debug builder': 'debug_x86_minimal_symbols', @@ -231,6 +236,8 @@ 'v8_linux64_cfi_rel_ng': 'release_x64_cfi', 'v8_linux64_fuzzilli_ng': 'release_x64_fuzzilli', 'v8_linux64_msan_rel_ng': 'release_simulate_arm64_msan_minimal_symbols', + 'v8_linux64_jumbo_compile_rel': 'release_x64_jumbo_trybot', + 'v8_linux64_jumbo_limited_compile_rel': 'release_x64_jumbo_limited_trybot', 'v8_linux64_riscv64_rel_ng': 'release_simulate_riscv64', 'v8_linux64_tsan_rel_ng': 'release_x64_tsan_minimal_symbols', 'v8_linux64_tsan_no_cm_rel_ng': 'release_x64_tsan_no_cm', @@ -492,6 +499,14 @@ 'release_bot', 'x64', 'ios_simulator'], 'release_x64_internal': [ 'release_bot', 'x64', 'v8_snapshot_internal'], + 'release_x64_jumbo': [ + 'release_bot', 'x64', 'jumbo'], + 'release_x64_jumbo_trybot': [ + 'release_trybot', 'x64', 'jumbo'], + 'release_x64_jumbo_limited': [ + 'release_bot', 'x64', 'jumbo_limited'], + 'release_x64_jumbo_limited_trybot': [ + 'release_trybot', 'x64', 'jumbo_limited'], 'release_x64_minimal_symbols': [ 'release_bot', 'x64', 'minimal_symbols'], 'release_x64_pointer_compression': [ @@ -543,6 +558,10 @@ 'debug_bot_no_goma', 'x64', 'gcc', 'lld', 'v8_check_header_includes'], 'debug_x64_header_includes': [ 'debug_bot', 'x64', 'v8_check_header_includes'], + 'debug_x64_jumbo': [ + 'debug_bot', 'x64', 'jumbo'], + 'debug_x64_jumbo_limited': [ + 'debug_bot', 'x64', 'jumbo_limited'], 'debug_x64_heap_sandbox': [ 'debug_bot', 'x64', 'v8_enable_heap_sandbox'], 'debug_x64_minimal_symbols': [ @@ -680,7 +699,7 @@ 'disable_concurrent_marking': { # Disable concurrent marking and atomic object field writes in order to - # increase the TSAN coverage for background tasks. We need to keep the + # increase the TSAN coverage for background tasks. We need to keep the # atomic marking state enabled because that is needed for the concurrent # write-barrier used by background compilation. 'gn_args': 'v8_enable_concurrent_marking=false ' @@ -721,6 +740,14 @@ 'gn_args': 'target_cpu="x64" target_os="ios"', }, + 'jumbo': { + 'gn_args': 'use_jumbo_build=true', + }, + + 'jumbo_limited': { + 'gn_args': 'use_jumbo_build=true jumbo_file_merge_limit=50', + }, + 'lld': { 'gn_args': 'use_lld=true', }, @@ -886,7 +913,7 @@ 'gn_args': 'v8_enable_pointer_compression=false', }, 'v8_enable_single_generation': { - 'gn_args': 'v8_enable_single_generation=true ' + 'gn_args': 'v8_enable_single_generation=true ' 'v8_disable_write_barriers=true', }, 'v8_enable_test_features': { diff --git a/chromium/v8/test/cctest/BUILD.gn b/chromium/v8/test/cctest/BUILD.gn index 8f6e5610b84..88743fa5738 100644 --- a/chromium/v8/test/cctest/BUILD.gn +++ b/chromium/v8/test/cctest/BUILD.gn @@ -300,6 +300,16 @@ v8_source_set("cctest_sources") { "unicode-helpers.h", ] + if (use_jumbo_build) { + jumbo_excluded_sources = [ + # TODO(mostynb@opera.com): figure out the jumbo issues with these source + # files, and include them in jumbo compilation units. + "interpreter/bytecode-expectations-printer.cc", + "interpreter/test-bytecode-generator.cc", + "test-api.cc", + ] + } + if (v8_current_cpu == "arm") { sources += [ ### gcmole(arch:arm) ### "assembler-helper-arm.cc", diff --git a/chromium/v8/test/unittests/BUILD.gn b/chromium/v8/test/unittests/BUILD.gn index f47b4994133..12128d4ba86 100644 --- a/chromium/v8/test/unittests/BUILD.gn +++ b/chromium/v8/test/unittests/BUILD.gn @@ -392,6 +392,15 @@ v8_source_set("unittests_sources") { "zone/zone-unittest.cc", ] + if (use_jumbo_build) { + jumbo_excluded_sources = [ + # TODO(mostynb@opera.com): figure out how to make this build in both + # modes. Template issues on windows if we add a functional_unittest + # namespace as with the other files. + "base/functional-unittest.cc", + ] + } + if (v8_enable_runtime_call_stats) { sources += [ "logging/runtime-call-stats-unittest.cc" ] } |