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

Add support for jumbo compilations to the rest of //ui

Jumbo is the Chromium implementation of a Unity build system aimed at
dramatically lowering the compilation times, especially for those
without access to goma.

In reference testing, this patch reduces the effort to compile
content_shell+chrome+blink_tests by about 9 CPU minutes, 1-2% of the
total effort. Earlier patches saved more so the total build effort
reduction in //ui is about 41 CPU minutes.

There is still some code in ui that doesn't use jumbo. Specifically
most of the tests.

Bug: 773275
Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel
Change-Id: Ie59fec4b67fc1e3d6855d04a4b9a1088e0a08768
Reviewed-on: https://chromium-review.googlesource.com/834348Reviewed-by: default avatarSadrul Chowdhury <sadrul@chromium.org>
Commit-Queue: Daniel Bratell <bratell@opera.com>
Cr-Commit-Position: refs/heads/master@{#589473}
parent 25b2ecaa
......@@ -4,6 +4,7 @@
import("//build/config/linux/pkg_config.gni")
import("//build/config/features.gni")
import("//build/config/jumbo.gni")
import("//build/config/ui.gni")
import("//mojo/public/tools/bindings/mojom.gni")
import("//services/service_manager/public/service_manifest.gni")
......@@ -28,7 +29,7 @@ mojom("ax_enums_mojo") {
]
}
component("accessibility") {
jumbo_component("accessibility") {
sources = [
"ax_action_data.cc",
"ax_action_data.h",
......
......@@ -4,6 +4,7 @@
import("//build/buildflag_header.gni")
import("//build/config/compiler/compiler.gni")
import("//build/config/jumbo.gni")
import("//build/config/linux/pangocairo/pangocairo.gni")
import("//build/config/sanitizers/sanitizers.gni")
import("//build/config/ui.gni")
......@@ -62,7 +63,7 @@ buildflag_header("ui_features") {
]
}
component("base") {
jumbo_component("base") {
output_name = "ui_base"
sources = [
......@@ -682,7 +683,7 @@ component("base") {
}
}
static_library("test_support") {
jumbo_static_library("test_support") {
testonly = true
sources = [
"test/material_design_controller_test_api.cc",
......
......@@ -4,6 +4,7 @@
import("//build/config/jumbo.gni")
import("//build/config/linux/pangocairo/pangocairo.gni")
import("//build/config/jumbo.gni")
import("//build/config/ui.gni")
import("//testing/test.gni")
......
......@@ -115,7 +115,7 @@ jumbo_component("compositor") {
}
}
static_library("test_support") {
jumbo_static_library("test_support") {
testonly = true
sources = [
"test/context_factories_for_test.cc",
......
......@@ -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")
import("//testing/test.gni")
import("//ui/display/display.gni")
component("display") {
jumbo_component("display") {
sources = [
"display.cc",
"display.h",
......@@ -101,7 +102,7 @@ component("display_manager_test_api") {
]
}
static_library("test_support") {
jumbo_static_library("test_support") {
testonly = true
sources = [
"test/display_matchers.cc",
......
......@@ -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("//testing/test.gni")
import("//ui/base/ui_features.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") {
]
}
component("events_base") {
jumbo_component("events_base") {
sources = [
"base_event_utils.cc",
"base_event_utils.h",
......@@ -153,7 +154,7 @@ component("events_base") {
}
}
component("events") {
jumbo_component("events") {
sources = [
"cocoa/cocoa_event_utils.h",
"cocoa/cocoa_event_utils.mm",
......@@ -300,7 +301,7 @@ component("events") {
}
}
component("gesture_detection") {
jumbo_component("gesture_detection") {
sources = [
"gesture_detection/bitset_32.h",
"gesture_detection/filtered_gesture_provider.cc",
......@@ -364,7 +365,7 @@ component("gesture_detection") {
}
}
static_library("test_support") {
jumbo_static_library("test_support") {
sources = [
"test/cocoa_test_event_utils.h",
"test/cocoa_test_event_utils.mm",
......
......@@ -483,7 +483,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
......@@ -574,7 +574,7 @@ jumbo_component("gfx_switches") {
]
}
static_library("test_support") {
jumbo_static_library("test_support") {
testonly = true
sources = [
"animation/animation_test_api.cc",
......
......@@ -3,6 +3,7 @@
# found in the LICENSE file.
import("//build/buildflag_header.gni")
import("//build/config/jumbo.gni")
import("//build/config/chrome_build.gni")
import("//build/config/linux/pkg_config.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 = [
......@@ -375,7 +376,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",
......@@ -401,7 +402,7 @@ static_library("gl_unittest_utils") {
]
}
static_library("test_support") {
jumbo_static_library("test_support") {
testonly = true
sources = [
"test/gl_image_test_support.cc",
......
......@@ -33,7 +33,7 @@ jumbo_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",
......
......@@ -98,7 +98,7 @@ jumbo_component("wm") {
}
}
static_library("test_support") {
jumbo_static_library("test_support") {
testonly = true
sources = [
"test/testing_cursor_client_observer.cc",
......
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