Commit b2123d44 authored by Daniel Bratell's avatar Daniel Bratell Committed by Commit Bot

Support jumbo in content/{utility,public,gpu,network}

Jumbo is a unity build system aimed at dramatically reducing
compilation times by merging cc files into larger translation
units.

This change will remove about 6 CPU minutes from the effort to compile
chrome+content_shell+blink_tests on the reference hardware. This is
slightly less than 1% of the total effort in a jumbo build.

Bug: 746953
Cq-Include-Trybots: master.tryserver.chromium.linux:linux_mojo
Change-Id: I19856815c50724004d11a7e5342e84bff802e6f4
Reviewed-on: https://chromium-review.googlesource.com/801013
Commit-Queue: Daniel Bratell <bratell@opera.com>
Reviewed-by: default avatarJochen Eisinger <jochen@chromium.org>
Cr-Commit-Position: refs/heads/master@{#521317}
parent 34537983
...@@ -2,6 +2,7 @@ ...@@ -2,6 +2,7 @@
# Use of this source code is governed by a BSD-style license that can be # Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file. # found in the LICENSE file.
import("//build/config/jumbo.gni")
import("//build/config/ui.gni") import("//build/config/ui.gni")
import("//gpu/vulkan/features.gni") import("//gpu/vulkan/features.gni")
import("//media/media_options.gni") import("//media/media_options.gni")
...@@ -23,9 +24,9 @@ group("gpu") { ...@@ -23,9 +24,9 @@ group("gpu") {
} }
if (is_component_build) { if (is_component_build) {
link_target_type = "source_set" link_target_type = "jumbo_source_set"
} else { } else {
link_target_type = "static_library" link_target_type = "jumbo_static_library"
} }
target(link_target_type, "gpu_sources") { target(link_target_type, "gpu_sources") {
......
...@@ -2,6 +2,7 @@ ...@@ -2,6 +2,7 @@
# Use of this source code is governed by a BSD-style license that can be # Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file. # found in the LICENSE file.
import("//build/config/jumbo.gni")
import("//services/service_manager/public/service_manifest.gni") import("//services/service_manager/public/service_manifest.gni")
group("network") { group("network") {
...@@ -18,7 +19,7 @@ group("network") { ...@@ -18,7 +19,7 @@ group("network") {
} }
} }
source_set("network_sources") { jumbo_source_set("network_sources") {
# Depend on via ":network above. # Depend on via ":network above.
visibility = [ visibility = [
":network", ":network",
......
...@@ -2,6 +2,7 @@ ...@@ -2,6 +2,7 @@
# Use of this source code is governed by a BSD-style license that can be # Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file. # found in the LICENSE file.
import("//build/config/jumbo.gni")
import("//build/config/ui.gni") import("//build/config/ui.gni")
import("//media/media_options.gni") import("//media/media_options.gni")
...@@ -18,10 +19,9 @@ group("browser") { ...@@ -18,10 +19,9 @@ group("browser") {
} }
} }
source_set("browser_sources") { jumbo_source_set("browser_sources") {
# External code should depend on via ":browser" above. # External code should depend on via ":browser" above.
visibility = [ "//content/*" ] visibility = [ "//content/*" ]
sources = [ sources = [
"android/android_overlay_provider.h", "android/android_overlay_provider.h",
"android/browser_media_player_manager_register.cc", "android/browser_media_player_manager_register.cc",
......
...@@ -2,6 +2,7 @@ ...@@ -2,6 +2,7 @@
# Use of this source code is governed by a BSD-style license that can be # Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file. # found in the LICENSE file.
import("//build/config/jumbo.gni")
import("//ppapi/features/features.gni") import("//ppapi/features/features.gni")
# See //content/BUILD.gn for how this works. # See //content/BUILD.gn for how this works.
...@@ -23,7 +24,7 @@ group("child") { ...@@ -23,7 +24,7 @@ group("child") {
} }
} }
source_set("child_sources") { jumbo_source_set("child_sources") {
# External code should depend in via ":child" above. # External code should depend in via ":child" above.
visibility = [ "//content/*" ] visibility = [ "//content/*" ]
......
...@@ -5,6 +5,7 @@ ...@@ -5,6 +5,7 @@
import("//build/buildflag_header.gni") import("//build/buildflag_header.gni")
import("//build/config/chromecast_build.gni") import("//build/config/chromecast_build.gni")
import("//build/config/features.gni") import("//build/config/features.gni")
import("//build/config/jumbo.gni")
import("//build/config/ui.gni") import("//build/config/ui.gni")
import("//media/media_options.gni") import("//media/media_options.gni")
import("//mojo/public/tools/bindings/mojom.gni") import("//mojo/public/tools/bindings/mojom.gni")
...@@ -102,7 +103,7 @@ source_set("static_features") { ...@@ -102,7 +103,7 @@ source_set("static_features") {
public_configs = [ ":static_switches_defines" ] public_configs = [ ":static_switches_defines" ]
} }
source_set("common_sources") { jumbo_source_set("common_sources") {
# External code should depend on via ":common" above. # External code should depend on via ":common" above.
visibility = [ "//content/*" ] visibility = [ "//content/*" ]
......
...@@ -3,6 +3,7 @@ ...@@ -3,6 +3,7 @@
# found in the LICENSE file. # found in the LICENSE file.
import("//build/config/features.gni") import("//build/config/features.gni")
import("//build/config/jumbo.gni")
import("//media/media_options.gni") import("//media/media_options.gni")
import("//ppapi/features/features.gni") import("//ppapi/features/features.gni")
...@@ -20,9 +21,9 @@ group("renderer") { ...@@ -20,9 +21,9 @@ group("renderer") {
} }
if (is_component_build) { if (is_component_build) {
link_target_type = "source_set" link_target_type = "jumbo_source_set"
} else { } else {
link_target_type = "static_library" link_target_type = "jumbo_static_library"
} }
target(link_target_type, "renderer_sources") { target(link_target_type, "renderer_sources") {
# External code should depend on via ":renderer" above. # External code should depend on via ":renderer" above.
......
...@@ -2,9 +2,10 @@ ...@@ -2,9 +2,10 @@
# Use of this source code is governed by a BSD-style license that can be # Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file. # found in the LICENSE file.
import("//build/config/jumbo.gni")
import("//media/media_options.gni") import("//media/media_options.gni")
source_set("utility") { jumbo_source_set("utility") {
# Only the public target should depend on this. All other targets (even # Only the public target should depend on this. All other targets (even
# internal content ones other than test) should depend on the public one. # internal content ones other than test) should depend on the public one.
visibility = [ visibility = [
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment