[Cast Convergence] Remove is_chromecast from //BUILD.gn
This CL updates the top-level`BUILD.gn` file to use `is_castos`,
`is_cast_android`, and `enable_cast_receiver` in place of
`is_chromecast`, to signify "Cast hardware devices running Linux",
"Cast hardware devices running android", and "general Cast receiver
functionality", respectively
Bug: 1219802, 1293571, 1330636
Change-Id: Ia4b95c49c0671e69db4f3c533909757a77a2c80b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3665840
Auto-Submit: Ryan Keane <[email protected]>
Reviewed-by: Scott Violet <[email protected]>
Commit-Queue: Ryan Keane <[email protected]>
Reviewed-by: David Dorwin <[email protected]>
Reviewed-by: Mark Foltz <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1015604}
diff --git a/BUILD.gn b/BUILD.gn
index 6ab6d2e0..a7a198d 100644
--- a/BUILD.gn
+++ b/BUILD.gn
@@ -109,27 +109,18 @@
deps += [ "//third_party/abseil-cpp:absl_tests" ]
}
- if (!is_android && !is_chromecast) {
+ if (enable_js_type_check) {
+ deps += [ ":webui_closure_compile" ]
+ }
+
+ if (!is_android && !is_castos) {
deps += [
"//crypto:crypto_unittests",
"//google_apis/gcm:gcm_unit_tests",
]
}
- if (enable_js_type_check) {
- deps += [ ":webui_closure_compile" ]
- }
-
- if (!is_ios && !is_android && !is_chromecast) {
- deps += [
- "//ui/accessibility:accessibility_perftests",
- "//ui/accessibility:accessibility_unittests",
- "//ui/accessibility/extensions:extension_tests",
- "//ui/accessibility/extensions:extensions",
- ]
- }
-
- if (!is_ios && !is_android && !is_chromecast) {
+ if (!is_ios && !is_android && !is_castos) {
deps += [
"//chrome",
"//chrome/browser/ui/color:dump_colors",
@@ -148,6 +139,10 @@
"//tools/perf/clear_system_cache",
"//tools/polymer:polymer_tools_python_unittests",
"//tools/privacy_budget:privacy_budget_tools",
+ "//ui/accessibility:accessibility_perftests",
+ "//ui/accessibility:accessibility_unittests",
+ "//ui/accessibility/extensions:extension_tests",
+ "//ui/accessibility/extensions:extensions",
]
}
@@ -254,7 +249,7 @@
]
}
- if (is_fuchsia && !is_chromecast) {
+ if (is_fuchsia) {
# Add targets that only exist on Fuchsia.
deps += [
":d8_fuchsia",
@@ -403,7 +398,7 @@
]
}
- if (!is_chromecast) {
+ if (!is_cast_android) {
deps += [
"//android_webview:empty_group",
"//android_webview/test",
@@ -609,26 +604,26 @@
"//third_party/breakpad:minidump_dump($host_toolchain)",
"//third_party/breakpad:minidump_stackwalk($host_toolchain)",
]
+ }
- if (!is_android) {
- deps += [
- "//chrome/test:chrome_app_unittests",
- "//gpu/khronos_glcts_support:khronos_glcts_test",
- "//media/cast:cast_benchmarks",
- "//media/cast:tap_proxy",
- "//skia:filter_fuzz_stub",
- "//skia:image_operations_bench",
- "//ui/snapshot:snapshot_unittests",
- ]
+ if (is_linux || is_chromeos_lacros) {
+ deps += [
+ "//chrome/test:chrome_app_unittests",
+ "//gpu/khronos_glcts_support:khronos_glcts_test",
+ "//media/cast:cast_benchmarks",
+ "//media/cast:tap_proxy",
+ "//skia:filter_fuzz_stub",
+ "//skia:image_operations_bench",
+ "//ui/snapshot:snapshot_unittests",
+ ]
- if (!is_debug && !is_component_build) {
- deps += [ "//chrome/tools/service_discovery_sniffer" ]
- }
+ if (!is_debug && !is_component_build) {
+ deps += [ "//chrome/tools/service_discovery_sniffer" ]
}
+ }
- if (ozone_platform_x11 && !is_chromecast && target_cpu != "arm") {
- deps += [ "//gpu/tools/compositor_model_bench" ]
- }
+ if (ozone_platform_x11 && !is_castos && target_cpu != "arm") {
+ deps += [ "//gpu/tools/compositor_model_bench" ]
}
if (is_mac) {
@@ -683,18 +678,19 @@
deps += [ "//third_party/breakpad:symupload($host_toolchain)" ]
}
- if (is_chromecast) {
+ # TODO(crbug.com/1330636): Remove the Fuchsia `is_chromecast` condition.
+ if (is_cast_android || is_castos || (is_fuchsia && is_chromecast)) {
deps += [ "//chromecast:cast_test_lists" ]
+ }
- if (!is_fuchsia) {
- deps += [
- "//chromecast:cast_shell",
- "//chromecast/cast_core:core_runtime_simple",
- ]
+ if (is_cast_android || is_castos) {
+ deps += [
+ "//chromecast:cast_shell",
+ "//chromecast/cast_core:core_runtime_simple",
+ ]
- if (enable_extensions && use_aura) {
- deps += [ "//chrome/browser/resources/chromeos/accessibility:build" ]
- }
+ if (enable_extensions && use_aura) {
+ deps += [ "//chrome/browser/resources/chromeos/accessibility:build" ]
}
}
@@ -726,14 +722,15 @@
deps += [ "//third_party/sqlite:sqlite_shell" ]
}
- if ((is_linux && !is_chromecast) || is_chromeos_lacros || is_fuchsia) {
- # TODO(https://crbug.com/1329673): Figure out if this should be in gn_all and how cross-platform this is.
+ if ((is_linux && !is_castos) || is_chromeos_lacros || is_fuchsia) {
+ # TODO(https://crbug.com/1329673): Figure out if this should be in gn_all
+ # and how cross-platform this is.
deps += [ "//components/services/filesystem:filesystem_service_unittests" ]
}
- if ((is_linux && !is_chromecast) || is_chromeos_lacros) {
- # TODO(https://crbug.com/1329673): Figure out if any of these should be in gn_all
- # and figure out how cross-platform they are
+ if ((is_linux && !is_castos) || is_chromeos_lacros) {
+ # TODO(https://crbug.com/1329673): Figure out if any of these should be in
+ # gn_all and figure out how cross-platform they are.
deps += [
"//chrome/installer/util:strings",
"//chrome/tools/convert_dict",
@@ -768,8 +765,8 @@
}
}
- if (((is_linux || is_chromeos) && !is_chromecast) ||
- (is_win && use_libfuzzer) || (use_libfuzzer && is_mac)) {
+ if ((is_linux && !is_castos) || is_chromeos ||
+ ((is_win || is_mac) && use_libfuzzer)) {
deps += [
"//testing/libfuzzer/fuzzers",
"//third_party/freetype-testing:fuzzers",
@@ -1055,13 +1052,13 @@
testonly = true
if (is_fuchsia || is_android) {
- # On Fuchsia/Android, ChromeDriver runs on the host, not the device.
- if (!is_chromecast) {
+ # On Fuchsia and non-Cast Android, ChromeDriver runs on the host, not the
+ # device.
+ if (!is_cast_android) {
deps = [ "//chrome/test/chromedriver:chromedriver($host_toolchain)" ]
-
- if (is_android) {
- deps += [ "//chrome/test/chromedriver/test/webview_shell:chromedriver_webview_shell_apk" ]
- }
+ }
+ if (is_android && !is_cast_android) {
+ deps += [ "//chrome/test/chromedriver/test/webview_shell:chromedriver_webview_shell_apk" ]
}
} else {
deps = [
@@ -1556,7 +1553,7 @@
group("chromium_builder_perf") {
testonly = true
- if (!is_ios && !is_android && !is_chromecast) {
+ if (!is_ios && !is_android && !is_castos) {
data_deps = [
"//cc:cc_perftests",
"//chrome/test:load_library_perf_tests",
@@ -1568,47 +1565,44 @@
"//tools/perf/chrome_telemetry_build:telemetry_chrome_test",
]
- if (is_android) {
- data += [ "//third_party/android_sdk/public/platform-tools/adb" ]
- }
-
if (!is_chromeos_ash) {
data_deps += [ "//chrome/test:performance_browser_tests" ]
}
- if (is_linux || is_chromeos_lacros) {
- if (is_official_build) {
- # In GN builds, this is controlled by the 'linux_dump_symbols'
- # flag, which defaults to 1 for official builds. For now,
- # we skip the separate flag and just key off of is_official_build.
- data_deps += [ "//chrome:linux_symbols" ]
- }
- data_deps += [ "//tools/perf/clear_system_cache" ]
- }
-
- if (is_win) {
- data_deps += [ "//chrome/installer/mini_installer:mini_installer" ]
- } else {
+ if (!is_win) {
data_deps +=
[ "//third_party/breakpad:minidump_stackwalk($host_toolchain)" ]
}
- if (is_win || is_android) {
- data_deps += [
- "//components:components_perftests",
- "//third_party/angle/src/tests:angle_perftests",
- ]
+ }
+
+ if ((is_linux && !is_castos) || is_chromeos_lacros) {
+ if (is_official_build) {
+ # In GN builds, this is controlled by the 'linux_dump_symbols'
+ # flag, which defaults to 1 for official builds. For now,
+ # we skip the separate flag and just key off of is_official_build.
+ data_deps += [ "//chrome:linux_symbols" ]
}
- # An `if (is_fuchsia)` condition in //chrome/test/BUILD.gn prevents this
- # target from being defined.
- # TODO(crbug.com/1310086): Resolve that and remove this exception.
- if (is_fuchsia) {
- data_deps -= [ "//chrome/test:performance_test_suite" ]
- }
+ data_deps += [ "//tools/perf/clear_system_cache" ]
+ }
+
+ if (is_win) {
+ data_deps += [
+ "//chrome/installer/mini_installer:mini_installer",
+ "//components:components_perftests",
+ "//third_party/angle/src/tests:angle_perftests",
+ ]
+ }
+
+ # An `if (is_fuchsia)` condition in //chrome/test/BUILD.gn prevents this
+ # target from being defined.
+ # TODO(crbug.com/1310086): Resolve that and remove this exception.
+ if (is_fuchsia) {
+ data_deps -= [ "//chrome/test:performance_test_suite" ]
}
}
-if (!is_ios && !is_android && !is_chromecast) {
+if (!is_ios && !is_android && !is_castos) {
group("chromium_builder_asan") {
testonly = true