123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779 |
- # Copyright (c) 2013 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 is the root build file for GN. GN will start processing by loading this
- # file, and recursively load all dependencies until all dependencies are either
- # resolved or known not to exist (which will cause the build to fail). So if
- # you add a new build file, there must be some path of dependencies from this
- # file to your new one or GN won't know about it.
- import("//build/config/chromeos/ui_mode.gni")
- import("//build/config/compiler/compiler.gni")
- import("//build/config/dcheck_always_on.gni")
- import("//build/config/features.gni")
- import("//build/config/rust.gni")
- import("//build/config/sanitizers/sanitizers.gni")
- import("//build/config/ui.gni")
- import("//build/gn_logs.gni")
- import("//build/util/generate_wrapper.gni")
- import("//chrome/browser/buildflags.gni")
- import("//components/nacl/features.gni")
- import("//device/vr/buildflags/buildflags.gni")
- import("//extensions/buildflags/buildflags.gni")
- import("//gpu/vulkan/features.gni")
- import("//media/gpu/args.gni")
- import("//media/media_options.gni")
- import("//pdf/features.gni")
- import("//ppapi/buildflags/buildflags.gni")
- import("//printing/buildflags/buildflags.gni")
- import("//remoting/remoting_enable.gni")
- import("//third_party/closure_compiler/compile_js.gni")
- import("//tools/ipc_fuzzer/ipc_fuzzer.gni")
- import("//ui/base/ui_features.gni")
- import("//ui/gl/features.gni")
- import("//v8/gni/v8.gni")
- if (is_android) {
- import("//build/config/android/config.gni")
- }
- if (is_linux) {
- import("build/config/linux/gtk/gtk.gni")
- }
- if (!is_ios) {
- import("//v8/gni/snapshot_toolchain.gni")
- }
- declare_args() {
- # A list of extra dependencies to add to the root target. This allows a
- # checkout to add additional targets without explicitly changing any checked-
- # in files.
- root_extra_deps = []
- }
- if (is_official_build) {
- # An official (maximally optimized!) component (optimized for build times)
- # build doesn't make sense and usually doesn't work.
- assert(!is_component_build)
- }
- # This file defines the following two main targets:
- #
- # "gn_all" is used to create explicit dependencies from the root BUILD.gn to
- # each top-level component that we wish to include when building everything via
- # "all". This is required since the set of targets built by "all" is determined
- # automatically based on reachability from the root BUILD.gn (for details, see
- # crbug.com/503241). Builders should typically use "all", or list targets
- # explicitly, rather than relying on "gn_all".
- #
- # "gn_visibility": targets that are normally not visible to top-level targets,
- # but are built anyway by "all". Since we don't want any such targets, we have
- # this placeholder to make sure hidden targets that aren't otherwise depended
- # on yet are accounted for.
- group("gn_all") {
- testonly = true
- deps = [
- ":gn_visibility",
- "//base:base_perftests",
- "//base:base_unittests",
- "//codelabs",
- "//components:components_unittests",
- "//components/gwp_asan:gwp_asan_unittests",
- "//infra/orchestrator:orchestrator_all",
- "//net:net_unittests",
- "//sandbox:sandbox_unittests",
- "//services:services_unittests",
- "//services/service_manager/public/cpp",
- "//skia:skia_unittests",
- "//sql:sql_unittests",
- "//third_party/angle/src/tests:angle_end2end_tests",
- "//third_party/angle/src/tests:angle_unittests",
- "//third_party/angle/src/tests:angle_white_box_tests",
- "//third_party/flatbuffers:flatbuffers_unittests",
- "//third_party/liburlpattern:liburlpattern_unittests",
- "//tools/binary_size:binary_size_trybot_py",
- "//tools/ipc_fuzzer:ipc_fuzzer_all",
- "//tools/metrics:metrics_metadata",
- "//ui/base:ui_base_unittests",
- "//ui/color:color_unittests",
- "//ui/gfx:gfx_unittests",
- "//url:url_unittests",
- ]
- if (!is_component_build) {
- deps += [ "//third_party/abseil-cpp:absl_tests" ]
- }
- 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 (!is_ios && !is_android && !is_castos) {
- deps += [
- "//chrome",
- "//chrome/browser/ui/color:dump_colors",
- "//chrome/test:browser_tests",
- "//chrome/test:interactive_ui_tests",
- "//chrome/test:sync_integration_tests",
- "//components/subresource_filter/tools:subresource_filter_tools",
- "//components/zucchini:zucchini",
- "//components/zucchini:zucchini_unittests",
- "//gpu/gles2_conform_support:gles2_conform_test",
- "//gpu/khronos_glcts_support:khronos_glcts_test",
- "//net:hpack_example_generator",
- "//third_party/vulkan-deps/spirv-tools/src:SPIRV-Tools",
- "//tools/aggregation_service:aggregation_service_tool",
- "//tools/attribution_reporting:attribution_reporting_simulator",
- "//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",
- ]
- }
- if (!is_castos) {
- deps += [
- "//chrome/installer",
- "//chrome/updater",
- ]
- }
- if (enable_ppapi) {
- deps += [
- "//ppapi:ppapi_unittests",
- "//ppapi/examples",
- ]
- }
- if (is_chromeos_lacros) {
- deps += [
- "//chrome/test:lacros_chrome_browsertests",
- "//chrome/test:lacros_chrome_unittests",
- ]
- }
- if (!is_ios && !is_castos) {
- deps += [ "//chrome/test:unit_tests" ]
- }
- if (!is_ios) {
- deps += [
- ":chromedriver",
- "//cc:cc_unittests",
- "//components:components_browsertests",
- "//components/policy:policy_templates",
- "//components/url_formatter/tools:format_url",
- "//components/viz:viz_perftests",
- "//components/viz:viz_unittests",
- "//content/shell:content_shell",
- "//content/test:content_browsertests",
- "//content/test:content_unittests",
- "//device:device_unittests",
- "//gpu:gpu_benchmark",
- "//gpu:gpu_unittests",
- "//ipc:ipc_tests",
- "//media:media_unittests",
- "//media/capture:capture_unittests",
- "//media/midi:midi_unittests",
- "//media/mojo:media_mojo_unittests",
- "//mojo",
- "//mojo:mojo_unittests",
- "//net:net_perftests",
- "//storage:storage_unittests",
- "//third_party/blink/common:blink_common_unittests",
- "//third_party/blink/renderer/controller:blink_unittests",
- "//third_party/blink/renderer/platform:blink_platform_unittests",
- "//third_party/blink/renderer/platform/heap:blink_heap_unittests",
- "//third_party/blink/renderer/platform/wtf:wtf_unittests",
- "//third_party/libjingle_xmpp:libjingle_xmpp_unittests",
- "//tools/imagediff",
- "//ui/display:display_unittests",
- "//ui/events:events_unittests",
- "//ui/gl:gl_unittests",
- "//ui/latency:latency_unittests",
- "//ui/native_theme:native_theme_unittests",
- "//ui/touch_selection:ui_touch_selection_unittests",
- "//url/ipc:url_ipc_unittests",
- "//v8:gn_all",
- ]
- }
- if (is_win || is_linux || is_android) {
- deps += [
- "//weblayer/shell:weblayer_shell",
- "//weblayer/test:weblayer_browsertests",
- "//weblayer/test:weblayer_unittests",
- ]
- if (is_android) {
- deps += [
- "//weblayer/browser/android/javatests:weblayer_instrumentation_test_apk",
- "//weblayer/browser/java:weblayer_junit_tests",
- ]
- }
- }
- if (!is_ios && !is_android && !is_fuchsia) {
- deps += [ "//components/viz/demo:viz_demo" ]
- if (!use_libfuzzer) {
- # TODO(crbug.com/1241949): libcronet.$version.so fails to link in libfuzzer builds.
- deps += [
- "//components/cronet:cronet_tests",
- "//components/cronet:cronet_unittests",
- ]
- }
- }
- if (!is_ios) {
- deps += [
- "//google_apis/gcm:mcs_probe",
- "//media/cast:cast_unittests",
- "//third_party/catapult/telemetry:bitmaptools($host_toolchain)",
- ]
- if (!is_android) {
- if (!is_castos) {
- deps += [ "//chrome/test:telemetry_perf_unittests" ]
- }
- } else {
- import("//tools/perf/chrome_telemetry_build/android_browser_types.gni")
- foreach(_target_suffix, telemetry_android_browser_target_suffixes) {
- deps += [ "//chrome/test:telemetry_perf_unittests${_target_suffix}" ]
- }
- }
- } else {
- deps += [
- "//ios:all",
- "//third_party/crashpad/crashpad:crashpad_tests",
- ]
- }
- if (is_fuchsia) {
- # Add targets that only exist on Fuchsia.
- deps += [
- ":d8_fuchsia",
- "//build/fuchsia/cipd",
- "//chrome/app:chrome_fuchsia",
- "//fuchsia_web:gn_all",
- "//tools/fuchsia/size_tests:fuchsia_sizes",
- # Ensure this target continues to build.
- "//chromecast/bindings:bindings_manager_fuchsia",
- ]
- }
- deps += root_extra_deps
- if (enable_basic_printing) {
- deps += [ "//printing:printing_unittests" ]
- }
- if (enable_extensions) {
- deps += [
- "//extensions:extensions_browsertests",
- "//extensions:extensions_unittests",
- "//extensions/browser/api/declarative_net_request/filter_list_converter",
- "//extensions/shell:app_shell_unittests",
- ]
- }
- if (enable_pdf) {
- deps += [
- "//pdf/pdfium/fuzzers",
- "//third_party/pdfium/samples:pdfium_test",
- ]
- }
- if (enable_remoting) {
- deps += [ "//remoting:remoting_all" ]
- }
- if (toolkit_views) {
- deps += [
- "//ui/views:views_unittests",
- "//ui/views/examples:views_examples",
- "//ui/views/examples:views_examples_unittests",
- "//ui/views/examples:views_examples_with_content",
- ]
- }
- if (use_aura) {
- deps += [
- "//ui/aura:aura_demo",
- "//ui/aura:aura_unittests",
- "//ui/wm:wm_unittests",
- ]
- }
- if (use_ozone) {
- deps += [
- "//ui/ozone",
- "//ui/ozone:unittests",
- "//ui/ozone/demo",
- ]
- }
- if (is_win) {
- deps += [
- "//chrome/credential_provider",
- "//chrome/credential_provider/test:gcp_unittests",
- ]
- }
- if (is_win || is_linux) {
- deps += [ "//tools/traffic_annotation/auditor:traffic_annotation_auditor" ]
- }
- if (is_mac) {
- deps += [
- "//chrome/installer/gcapi_mac:gcapi_example",
- "//tools/mac/power:all",
- ]
- }
- # Allow building md5sum tool for other OSes (android is added below).
- # For Windows, see: crbug.com/1090428.
- # TODO(cavalcantii): move it out of 'android' folder.
- if (!is_win) {
- deps += [ "//tools/android/md5sum" ]
- }
- if (is_android) {
- deps += [
- "//android_webview/js_sandbox/javatests:webview_js_sandbox_test_app",
- "//base:base_junit_tests",
- "//base/android/jni_generator:jni_generator_tests",
- "//base/android/linker:chromium_android_linker",
- "//build/android/gyp/test:hello_world",
- "//build/android/stacktrace:java_deobfuscate",
- "//build/config/android/test/proto:test_build_protos",
- "//chrome/android/monochrome:monochrome_public_apk_checker",
- "//chrome/android/webapk/shell_apk:maps_go_webapk",
- "//chrome/android/webapk/shell_apk:webapk",
- "//chrome/android/webapk/shell_apk/prepare_upload_dir:prepare_webapk_shell_upload_dir",
- "//chrome/test:android_browsertests",
- "//components:components_junit_tests",
- "//content/public/android:content_junit_tests",
- "//content/shell/android:content_shell_apk",
- "//device:device_junit_tests",
- "//media/gpu:video_decode_accelerator_unittest",
- "//net/android:net_junit_tests",
- "//services:services_junit_tests",
- "//testing/android/junit:junit_unit_tests",
- "//third_party/android_build_tools/lint:custom_lint_java",
- "//third_party/catapult/devil",
- "//third_party/r8:custom_d8_java",
- "//tools/android:android_tools",
- "//tools/android:memconsumer",
- "//tools/android:push_apps_to_background",
- "//tools/android/audio_focus_grabber:audio_focus_grabber_apk",
- "//tools/android/customtabs_benchmark:customtabs_benchmark_apk",
- "//tools/android/kerberos/SpnegoAuthenticator:spnego_authenticator_apk",
- "//ui/android:ui_junit_tests",
- "//weblayer/public/java:client_aar",
- "//weblayer/shell/android:weblayer_shell_apk",
- "//weblayer/shell/android:weblayer_support_apk",
- ]
- deps -= [
- "//net:net_perftests",
- "//url:url_unittests",
- ]
- if (!is_component_build) {
- deps += [
- "//components/cronet/android:cronet_package_android",
- "//components/cronet/android:cronet_perf_test_apk",
- "//components/cronet/android:cronet_sample_apk",
- "//components/cronet/android:cronet_sample_test_apk",
- "//components/cronet/android:cronet_test_instrumentation_apk",
- "//components/cronet/android:cronet_unittests_android",
- ]
- }
- if (!is_cast_android) {
- deps += [
- "//android_webview:empty_group",
- "//android_webview/test",
- "//android_webview/tools/automated_ui_tests:webview_ui_test_app",
- "//android_webview/tools/system_webview_shell",
- "//chrome/android:chrome_junit_tests",
- "//chrome/android:chrome_public_apk",
- "//chrome/android:chrome_public_test_apk",
- "//chrome/android:chrome_public_unit_test_apk",
- "//chrome/browser/android/examples/custom_tabs_client:custom_tabs_client_example_apk",
- "//chrome/browser/android/examples/partner_browser_customizations_provider:partner_browser_customizations_example_apk",
- "//content/shell/android:content_shell_test_apk",
- ]
- }
- if (enable_chrome_android_internal) {
- deps += [ "//clank" ]
- }
- }
- # NOTE: The following should really be 'is_android', but the fuzzing build
- # seems currently broken for this platform at the moment, and the
- # corresponding code build and works on Linux unmodified.
- # See instructions in the corresponding BUILD.gn.
- if (is_linux || is_chromeos) {
- deps +=
- [ "//third_party/android_crazy_linker:android_crazy_linker_zip_fuzzer" ]
- }
- if (is_linux || is_chromeos) {
- # This is only used by ChromeOS, but we want maximal fuzzer coverage, so
- # run it under linux too.
- deps += [
- "//third_party/minizip:minizip_compress_fuzzer",
- "//third_party/minizip:minizip_uncompress_fuzzer",
- ]
- }
- if (is_linux || is_chromeos || is_android) {
- deps += [
- "//third_party/breakpad:breakpad_unittests",
- "//third_party/breakpad:core-2-minidump",
- "//third_party/breakpad:generate_test_dump",
- "//third_party/breakpad:minidump-2-core",
- "//tools/dump_process_memory:dump_process",
- ]
- }
- if (is_linux || is_chromeos || is_android || is_mac) {
- deps += [ "//tools/memory/partition_allocator:all" ]
- }
- if (is_chromeos_ash) {
- deps += [
- "//ash:ash_unittests",
- "//ash/components:ash_components_unittests",
- "//ash/components/proximity_auth:proximity_auth_unittests",
- "//ash/keyboard/ui:keyboard_unittests",
- "//ash/webui:ash_webui_unittests",
- "//chrome/browser/metrics/perf:profile_provider_unittest",
- "//chrome/test:ash_crosapi_browsertests",
- "//chrome/test:usage_time_limit_unittests",
- "//chromeos/components:chromeos_components_unittests",
- "//components/exo/wayland:wayland_client_compatibility_tests",
- "//components/session_manager/core",
- "//third_party/shell-encryption:shell_encryption_unittests",
- "//tools/traffic_annotation/auditor:traffic_annotation_auditor",
- "//ui/chromeos:ui_chromeos_unittests",
- ]
- }
- if (is_chromeos) {
- deps += [ "//chromeos:chromeos_unittests" ]
- }
- if (is_chromeos_ash || is_mac || is_win) {
- deps += [
- "//rlz:rlz_id",
- "//rlz:rlz_lib",
- "//rlz:rlz_unittests",
- ]
- }
- if (is_linux || is_chromeos) {
- # The following are definitely linux-only.
- deps += [
- "//net:disk_cache_memory_test",
- "//net:quic_client",
- "//net:quic_server",
- "//sandbox/linux:chrome_sandbox",
- "//sandbox/linux:sandbox_linux_unittests",
- ]
- if (!is_clang) {
- deps += [ "//testing:empty_main" ]
- }
- if (!is_castos) {
- deps += [ "//chrome:xdg_mime" ]
- }
- if (use_dbus) {
- deps += [
- "//dbus:dbus_test_server",
- "//dbus:dbus_unittests",
- ]
- }
- if (is_chrome_branded && is_official_build) {
- # TODO(dpranke): add the linux_dump_symbols flag?
- deps += [ "//chrome:linux_symbols" ]
- }
- }
- if (is_ios || is_win || is_linux || is_chromeos_lacros || is_fuchsia) {
- deps += [
- "//base:base_i18n_perftests",
- "//google_apis:google_apis_unittests",
- ]
- }
- if ((is_win || is_mac || is_linux || is_chromeos || is_fuchsia) &&
- (target_cpu == "x86" || target_cpu == "x64")) {
- deps += [
- "//third_party/swiftshader/src/Vulkan:icd_file",
- "//third_party/swiftshader/src/Vulkan:swiftshader_libvulkan",
- ]
- }
- # TODO(GYP): Figure out which of these should (and can) build
- # for Chrome OS and iOS.
- if (!is_chromeos_ash && !is_ios) {
- deps += [
- "//base:build_utf8_validator_tables",
- "//base:check_example",
- "//cc:cc_perftests",
- "//components:components_perftests",
- "//device:device_unittests",
- "//gin:gin_shell",
- "//gin:gin_unittests",
- "//gpu:command_buffer_perftests",
- "//gpu:gl_tests",
- "//gpu:gpu_perftests",
- "//ipc:ipc_perftests",
- "//media:media_perftests",
- "//net:dump_cache",
- "//third_party/libphonenumber:libphonenumber_unittests",
- "//ui/compositor:compositor_unittests",
- ]
- if (!is_android && !is_castos) {
- deps += [
- "//chrome/test:load_library_perf_tests",
- "//chrome/test:sync_performance_tests",
- ]
- }
- if (!is_android) {
- deps += [
- "//courgette:courgette",
- "//courgette:courgette_fuzz",
- "//courgette:courgette_minimal_tool",
- "//courgette:courgette_unittests",
- "//media/cast:generate_barcode_video",
- "//media/cast:generate_timecode_audio",
- "//net:crash_cache",
- "//net:net_watcher", # TODO(GYP): This should be conditional on
- # use_v8_in_net
- "//net:run_testserver",
- "//net:stress_cache",
- "//net:tld_cleanup",
- "//third_party/leveldatabase:env_chromium_unittests",
- "//third_party/libaddressinput:libaddressinput_unittests",
- ]
- }
- if (enable_extensions) {
- deps += [ "//extensions/shell:app_shell" ]
- }
- # TODO(https://crbug.com/1299021): Implement building these NaCl targets
- # as ARM32 when Chrome is built for ARM64 (for Linux/Chrome OS).
- if (enable_nacl && target_cpu != "arm64") {
- deps += [ "//components/nacl/loader:nacl_loader_unittests" ]
- if (is_linux || is_chromeos) {
- # TODO(dpranke): Figure out what platforms should actually have this.
- deps += [ "//components/nacl/loader:nacl_helper" ]
- }
- }
- if (media_use_ffmpeg && !is_android) {
- deps += [ "//media:ffmpeg_regression_tests" ]
- }
- }
- if (enable_ppapi) {
- deps += [
- "//ppapi:pepper_hash_for_uma",
- "//ppapi:ppapi_perftests",
- ]
- }
- if (is_android || is_linux || is_chromeos_lacros) {
- deps += [
- "//components/network_hints/browser",
- "//content/public/app",
- "//mojo:mojo_perftests",
- "//services/service_manager/public/cpp",
- "//testing/gmock:gmock_main",
- "//third_party/breakpad:dump_syms($host_toolchain)",
- "//third_party/breakpad:microdump_stackwalk($host_toolchain)",
- "//third_party/breakpad:minidump_dump($host_toolchain)",
- "//third_party/breakpad:minidump_stackwalk($host_toolchain)",
- ]
- }
- if (is_linux || is_chromeos_lacros) {
- deps += [
- "//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_castos) {
- deps += [ "//chrome/test:chrome_app_unittests" ]
- }
- if (!is_debug && !is_component_build && !is_castos) {
- deps += [ "//chrome/tools/service_discovery_sniffer" ]
- }
- }
- if (ozone_platform_x11 && !is_castos && target_cpu != "arm") {
- deps += [ "//gpu/tools/compositor_model_bench" ]
- }
- if (is_mac) {
- deps += [
- "//third_party/breakpad:crash_inspector",
- "//third_party/breakpad:dump_syms",
- # The following are accessibility API tools.
- "//tools/accessibility/inspect:ax_dump_events",
- "//tools/accessibility/inspect:ax_dump_tree",
- ]
- deps -= [
- # Mojo in GN contains some things which are never compiled in GYP on Mac,
- # so compilation fails on Mac. They need porting.
- "//mojo",
- ]
- }
- if (is_win) {
- deps += [
- "//base:pe_image_test",
- "//chrome/chrome_cleaner",
- "//chrome/chrome_elf:chrome_elf_unittests",
- "//chrome/chrome_elf:dll_hash_main",
- "//chrome/elevation_service:elevation_service_unittests",
- "//chrome/install_static:install_static_unittests",
- "//chrome/installer/gcapi",
- "//chrome/installer/setup:setup_unittests",
- "//chrome/notification_helper:notification_helper_unittests",
- "//chrome/test:delayloads_unittests",
- "//components/wifi:wifi_test",
- "//components/zucchini",
- "//net:quic_client",
- "//net:quic_server",
- "//sandbox/win:sbox_integration_tests",
- "//sandbox/win:sbox_unittests",
- "//sandbox/win:sbox_validation_tests",
- "//testing/gtest:gtest_main",
- # The following two are accessibility API debugging tools.
- "//tools/accessibility/inspect:ax_dump_events",
- "//tools/accessibility/inspect:ax_dump_tree",
- "//tools/win/chromeexts:chromeexts",
- ]
- # TODO(thakis): Enable this in cross builds, https://crbug.com/799827
- if (!(is_component_build && is_debug && target_cpu == "x86") &&
- host_os == "win") {
- deps += [ "//chrome/test/mini_installer:mini_installer_tests" ]
- }
- } else if (!is_android && !is_ios && !is_fuchsia) {
- deps += [ "//third_party/breakpad:symupload($host_toolchain)" ]
- }
- if (is_cast_android || is_castos || (is_fuchsia && enable_cast_receiver)) {
- deps += [ "//chromecast:cast_test_lists" ]
- }
- if (is_cast_android || is_castos) {
- deps += [
- "//chromecast:cast_shell",
- "//chromecast/cast_core:core_runtime_simple",
- ]
- }
- if (is_mac || is_win || is_android || is_linux || is_chromeos) {
- deps += [
- "//third_party/crashpad/crashpad:crashpad_tests",
- "//third_party/crashpad/crashpad/handler:crashpad_handler",
- "//third_party/crashpad/crashpad/tools:crashpad_database_util",
- ]
- }
- if (enable_message_center) {
- deps += [ "//ui/message_center:message_center_unittests" ]
- }
- if (!is_android && !is_ios) {
- deps += [ "//content/browser/bluetooth/tools:bluetooth_metrics_hash" ]
- }
- if (is_win || is_linux || is_chromeos) {
- deps += [ "//mojo" ]
- }
- if (is_mac || is_linux || is_chromeos || is_android || is_fuchsia) {
- deps += [ "//third_party/perfetto:all" ]
- }
- if (is_win || is_mac || is_linux || is_chromeos) {
- deps += [ "//third_party/sqlite:sqlite_shell" ]
- }
- 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_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",
- "//components/constrained_window:unit_tests",
- "//components/metrics:serialization",
- "//components/sessions:unit_tests",
- "//media/cast:udp_proxy",
- "//storage/browser:dump_file_system",
- "//third_party/angle:libANGLE",
- "//third_party/angle:libEGL",
- "//third_party/angle:libGLESv2",
- "//third_party/leveldatabase:leveldb_test_targets",
- "//third_party/libjpeg_turbo:simd",
- "//third_party/opus:opus_compare",
- "//third_party/opus:opus_demo",
- "//third_party/opus:test_opus_api",
- "//third_party/opus:test_opus_decode",
- "//third_party/opus:test_opus_encode",
- "//third_party/opus:test_opus_padding",
- "//ui/display/types",
- "//ui/shell_dialogs:shell_dialogs_unittests",
- ]
- if (target_cpu == "x86" || target_cpu == "x64") {
- if (!is_android) {
- deps += [ "//chrome/test:load_library_perf_tests" ]
- }
- deps += [ "//third_party/libjpeg_turbo:simd_asm" ]
- }
- if ((is_linux || is_chromeos) && current_toolchain == host_toolchain) {
- deps += [ "//v8:v8_shell" ]
- }
- }
- if ((is_linux && !is_castos) || is_chromeos ||
- ((is_win || is_mac) && use_libfuzzer)) {
- deps += [
- "//testing/libfuzzer/fuzzers",
- "//third_party/freetype-testing:fuzzers",
- "//third_party/grpc:fuzzers",
- "//third_party/icu/fuzzers",
- "//third_party/qcms:fuzzers",
- "//third_party/ukey2/fuzzers",
- "//third_party/zlib/contrib/tests/fuzzers",
- ]
- if (is_chromeos_ash) {
- deps += [ "//chrome/services/ipp_parser/public/cpp:fuzzers" ]
- }
- # TODO(crbug.com/906751): Get the libFuzzer tests working on Windows.
- # Disable them for now because they cause the Windows clang ToT builder to
- # fail.
- if (!is_win) {
- deps += [ "//testing/libfuzzer/tests:libfuzzer_tests" ]
- }
- }
- # TODO(https://crbug.com/1299021): Remove the special case for arm64.
- if (enable_nacl && target_cpu != "arm64") {
- deps += [ "//native_client_sdk/src:nacl_core_sdk" ]
- }
- if (((is_linux || is_chromeos) && use_ozone) || is_fuchsia) {
- deps += [
- "//headless:headless_non_renderer",
- "//headless:headless_tests",
- ]
- }
- if (enable_vr) {
- deps += [
- "//chrome/browser/vr:vr_common_perftests",
- "//chrome/browser/vr:vr_common_unittests",
- "//chrome/browser/vr:vr_pixeltests",
- ]
- if (!is_android) {
- deps += [ "//tools/perf/contrib/vr_benchmarks:vr_perf_tests" ]
- } else {
- deps += [ "//chrome/browser/android/vr:vr_android_unittests" ]
- import("//tools/perf/chrome_telemetry_build/android_browser_types.gni")
- foreach(_target_suffix, telemetry_android_browser_target_suffixes) {
- deps += [
- "//tools/perf/contrib/vr_benchmarks:vr_perf_tests${_target_suffix}",
- ]
- }
- }
- }
- if (use_atk) {
- deps += [
- "//tools/accessibility/inspect:ax_dump_events",
- "//tools/accessibility/inspect:ax_dump_tree",
- ]
- }
- if (build_dawn_tests) {
- deps += [
- "//third_party/dawn/src/dawn/fuzzers:fuzzers",
- "//third_party/dawn/src/dawn/tests:dawn_end2end_tests",
- "//third_party/dawn/src/dawn/tests:dawn_unittests",
- "//third_party/dawn/src/tint:tint_unittests",
- "//third_party/dawn/src/tint/fuzzers",
- ]
- }
- # PFFFT.
- deps += [
- "//third_party/pffft:fuzzers",
- "//third_party/pffft:pffft_benchmark",
- "//third_party/pffft:pffft_unittest",
- ]
- # Minimal binaries to exercise Rust toolchain.
- deps += [ ":rust_build_tests" ]
- # More Rust targets.
- if (toolchain_has_rust) {
- deps += [
- "//mojo/public/rust",
- "//mojo/public/rust:mojo_rust_tests",
- "//third_party/rust/autocxx/chromium_integration/tests",
- # TODO(crbug.com/1291994): Determine whether it makes sense to build/run
- # this even on Android. If not, remove this and figure out how to run it
- # only on desktop testers.
- "//tools/crates/gnrt:gnrt_unittests",
- "//tools/crates/gnrt($host_toolchain)",
- ]
- }
- if (enable_rust) {
- deps += [ "//testing/rust_gtest_interop:rust_gtest_interop_unittests" ]
- }
- }
- # This group and the following exist to give targets for the waterfall to refer to.
- group("rust_build_tests") {
- testonly = true
- deps = [ "//build/rust/tests" ]
- }
- group("rust_autocxx_tests") {
- testonly = true
- deps = [ "//third_party/rust/autocxx/chromium_integration/tests" ]
- }
- # TODO(https://crbug.com/1112776): ensure remoting is functional on Linux builds with
- # other than X11 Ozone backends.
- if (enable_remoting && ((is_linux && ozone_platform_x11) ||
- ((is_chromeos || is_win) && !use_ozone))) {
- # On CQ, run the Traffic Annotation Auditor when a change affects one of these
- # targets.
- group("traffic_annotation_auditor_dependencies") {
- deps = [
- "//chrome:chrome",
- "//remoting/client",
- "//remoting/host:host",
- "//tools/traffic_annotation/summary:annotations_xml",
- ]
- if (is_win) {
- deps += [ "//chrome/chrome_cleaner:shipped_binaries" ]
- }
- }
- }
- if (is_chromeos_ash) {
- group("traffic_annotation_auditor_dependencies") {
- deps = [
- "//chrome",
- "//chromeos",
- "//tools/traffic_annotation/summary:annotations_xml",
- ]
- }
- }
- if (is_android) {
- # On CQ, run the Traffic Annotation Auditor when a change affects one of these
- # targets.
- group("traffic_annotation_auditor_dependencies") {
- deps = [
- "//chrome/android:chrome_public_apk",
- "//tools/traffic_annotation/summary:annotations_xml",
- ]
- }
- }
- if (is_fuchsia) {
- # TODO(https://crbug.com/731217): This can't practically be in //v8 without
- # duplicating all the Fuchsia running infrastructure there.
- cr_fuchsia_package("d8_fuchsia_pkg") {
- testonly = true
- binary = "//v8:d8"
- manifest = "//v8/gni/v8.cmx"
- package_name = "d8"
- }
- fuchsia_package_installer("d8_fuchsia") {
- testonly = true
- package = ":d8_fuchsia_pkg"
- package_name = "d8"
- }
- }
- # TODO(GYP_GONE): Figure out if we really need this target or if there's
- # some better way to specify things.
- if (is_win) {
- group("chrome_official_builder_no_unittests") {
- deps = [
- "//chrome/common/win:eventlog_provider",
- "//chrome/credential_provider",
- "//chrome/installer/gcapi",
- "//chrome/installer/mini_installer",
- "//chrome/updater/win:updater_zip",
- "//components/policy:pack_policy_templates",
- "//components/zucchini",
- "//courgette",
- "//courgette:copy_courgette_binaries",
- "//third_party/hyphenation-patterns",
- "//tools/metrics:metrics_metadata",
- ]
- if (target_cpu == "x86") {
- if (is_clang) {
- deps += [ "//courgette(//build/toolchain/win:win_clang_x64)" ]
- } else {
- deps += [ "//courgette(//build/toolchain/win:x64)" ]
- }
- }
- if (is_chrome_branded) {
- deps += [ "//remoting/host:remoting_host_installation" ]
- }
- }
- group("chrome_official_builder") {
- testonly = true
- deps = [
- ":chrome_official_builder_no_unittests",
- "//base:base_unittests",
- "//chrome/test:browser_tests",
- "//ipc:ipc_tests",
- "//media:media_unittests",
- "//media/midi:midi_unittests",
- "//net:net_unittests",
- "//printing:printing_unittests",
- "//sql:sql_unittests",
- "//third_party/breakpad:symupload($host_toolchain)",
- "//ui/base:ui_base_unittests",
- "//ui/gfx:gfx_unittests",
- "//ui/touch_selection:ui_touch_selection_unittests",
- "//ui/views:views_unittests",
- "//url:url_unittests",
- ]
- }
- }
- if (is_chromeos_ash) {
- # This group is used to collect all targets used when verifying a new version
- # of Chrome for Chrome OS.
- group("chromiumos_preflight") {
- testonly = true
- data_deps = [
- "//chrome",
- "//chrome/test/chromedriver",
- "//components/chromeos_camera:jpeg_decode_accelerator_unittest",
- "//components/exo/wayland:wayland_client_integration_tests",
- "//components/exo/wayland:wayland_client_perftests",
- "//components/exo/wayland:wayland_client_tests",
- "//components/policy/test_support:fake_dmserver",
- "//media:media_unittests",
- "//media/capture:capture_unittests",
- "//sandbox/linux:chrome_sandbox",
- "//sandbox/linux:sandbox_linux_unittests",
- "//third_party/breakpad:minidump_stackwalk($host_toolchain)",
- "//third_party/dawn/src/dawn/tests:dawn_end2end_tests",
- "//third_party/dawn/src/dawn/tests:dawn_unittests",
- "//ui/ozone:ozone_integration_tests",
- # Blocked on https://github.com/catapult-project/catapult/issues/2297
- #"//third_party/catapult/telemetry:bitmaptools",
- "//tools/perf/clear_system_cache",
- "//ui/ozone/gl:ozone_gl_unittests",
- ]
- if (enable_plugins) {
- data_deps += [ "//ppapi/examples/video_decode" ]
- }
- if (use_v4l2_codec || use_vaapi) {
- data_deps += [
- "//components/chromeos_camera:jpeg_encode_accelerator_unittest",
- "//media/gpu:video_decode_accelerator_perf_tests",
- "//media/gpu:video_decode_accelerator_tests",
- "//media/gpu:video_encode_accelerator_perf_tests",
- "//media/gpu:video_encode_accelerator_tests",
- "//media/gpu/chromeos:image_processor_test",
- ]
- if (use_vaapi) {
- data_deps += [
- "//media/gpu/vaapi:decode_test",
- "//media/gpu/vaapi:vaapi_unittest",
- ]
- }
- if (use_v4l2_codec) {
- data_deps += [ "//media/gpu/v4l2:v4l2_stateless_decoder" ]
- }
- }
- }
- }
- group("gn_visibility") {
- deps = [
- "//build/config/sanitizers:options_sources",
- # "//third_party/pdfium:pdfium_embeddertests", # TODO(GYP): visibility?
- # "//third_party/pdfium:pdfium_unittests", # TODO(GYP): visibility?
- ]
- if (!is_ios) {
- deps += [ "//v8:postmortem-metadata" ]
- if (!v8_use_external_startup_data) {
- deps += [ "//v8:v8_snapshot" ]
- }
- }
- }
- if (!is_ios) {
- group("chromedriver") {
- testonly = true
- if (is_fuchsia || is_android) {
- # 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 && !is_cast_android) {
- deps += [ "//chrome/test/chromedriver/test/webview_shell:chromedriver_webview_shell_apk" ]
- }
- } else if (!is_castos) {
- deps = [
- "//chrome/test/chromedriver:chromedriver",
- "//chrome/test/chromedriver:chromedriver_unittests",
- ]
- }
- }
- # This group includes all of the targets needed to build and test Blink,
- # including running web tests (see below). This target is defined here because
- # previously //third_party/WebKit, now //third_party/blink, couldn't depend on
- # //content/shell. This might not longer be true, see
- # https://crbug.com/1018659.
- group("blink_tests") {
- testonly = true
- deps = [
- ":blink_web_tests",
- ":blink_wpt_tests",
- "//third_party/blink/public:all_blink",
- ]
- }
- # Web tests runner
- # third_party/blink/tools/run_web_tests.py
- group("run_web_tests") {
- testonly = true
- deps = [
- ":blink_web_tests",
- ":blink_wpt_tests",
- ]
- }
- if (!is_chromeos_ash && !is_ios && !is_fuchsia && !is_android && !is_castos) {
- # WPT Webdriver tests runner
- # chrome/test/chromedriver/test/run_webdriver_tests.py
- script_test("webdriver_wpt_tests") {
- # The script is wrapped in testing/xvfb.py; the actual
- # run_webdriver_tests.py script is passed as an arg in gn_isolate_map.pyl
- script = "//testing/xvfb.py"
- data = [
- "//build/skia_gold_common/",
- "//chrome/test/chromedriver/chrome_paths.py",
- "//chrome/test/chromedriver/server/server.py",
- "//chrome/test/chromedriver/test/run_webdriver_tests.py",
- "//chrome/test/chromedriver/util.py",
- "//third_party/blink/tools/blinkpy/",
- "//third_party/blink/web_tests/external/wpt/webdriver/",
- "//third_party/blink/web_tests/VirtualTestSuites",
- "//third_party/blink/web_tests/WebDriverExpectations",
- "//third_party/pywebsocket3/src/mod_pywebsocket/",
- "//third_party/wpt_tools/",
- ]
- data_deps = [
- "//chrome:chrome",
- "//chrome/test/chromedriver",
- "//testing:test_scripts_shared",
- "//third_party/catapult/third_party/typ",
- ]
- if (is_win) {
- data_deps += [ "//build/win:copy_cdb_to_output" ]
- }
- }
- script_test("wpt_tests_isolate") {
- script = "//testing/scripts/run_wpt_tests.py"
- data_deps = [
- "//chrome:chrome",
- "//chrome/test/chromedriver",
- "//third_party/blink/tools:wpt_tests_isolate",
- "//tools/imagediff",
- ]
- }
- }
- group("blink_web_tests_support_data") {
- testonly = true
- data_deps = [
- ":layout_test_data_mojo_bindings",
- ":layout_test_data_mojo_bindings_lite",
- "//content/shell:content_shell",
- "//content/test:mojo_bindings_web_test_mojom_js_data_deps",
- "//content/test:mojo_web_test_bindings_js_data_deps",
- "//device/bluetooth/public/mojom:fake_bluetooth_interfaces_js_data_deps",
- "//device/vr/public/mojom:vr_service_js_data_deps",
- "//media/capture/mojom:image_capture_js_data_deps",
- "//media/midi:mojo_js_data_deps",
- "//mojo/public/interfaces/bindings/tests:test_data_deps",
- "//mojo/public/js/ts/bindings/tests:test_interfaces_js_data_deps",
- "//mojo/public/mojom/base:base_js_data_deps",
- "//services/device/public/mojom:generic_sensor_js_data_deps",
- "//services/device/public/mojom:mojom_js_data_deps",
- "//services/device/public/mojom:usb_js_data_deps",
- "//services/shape_detection/public/mojom:mojom_js_data_deps",
- "//skia/public/mojom:mojom_js_data_deps",
- "//testing/buildbot/filters:blink_web_tests_filter",
- "//third_party/blink/public:blink_devtools_frontend_resources_files",
- "//third_party/blink/public:blink_devtools_inspector_resources",
- "//third_party/blink/public/mojom:mojom_platform_js_data_deps",
- "//third_party/blink/renderer/core:js_files_for_form_controls_web_tests",
- "//third_party/catapult/third_party/typ",
- "//third_party/hyphenation-patterns:test_data",
- "//third_party/mesa_headers",
- "//tools/imagediff",
- "//ui/base:goldctl",
- ]
- if (is_android) {
- data_deps += [
- "//third_party/breakpad:breakpad_unittests",
- "//third_party/breakpad:dump_syms",
- "//third_party/breakpad:microdump_stackwalk",
- "//third_party/breakpad:minidump_dump",
- "//third_party/breakpad:minidump_stackwalk",
- "//third_party/breakpad:symupload",
- "//tools/android/forwarder2",
- ]
- } else {
- data_deps += [ "//content/web_test:web_test_common_mojom_js_data_deps" ]
- }
- if (!is_win && !is_android) {
- data_deps +=
- [ "//third_party/breakpad:minidump_stackwalk($host_toolchain)" ]
- }
- if (is_mac) {
- data_deps += [ "//third_party/breakpad:dump_syms($host_toolchain)" ]
- }
- if (is_linux || is_chromeos) {
- data_deps += [ "//third_party/breakpad:dump_syms($host_toolchain)" ]
- }
- if (is_fuchsia) {
- data_deps += [
- "//build/config/fuchsia:deployment_resources",
- "//content/shell:content_shell_fuchsia",
- "//content/shell:content_shell_pkg__archive-manifest",
- "//content/shell:content_shell_pkg__archive-metadata",
- ]
- }
- data = [
- "//build/skia_gold_common/",
- "//testing/scripts/common.py",
- "//testing/scripts/run_isolated_script_test.py",
- "//testing/xvfb.py",
- "//third_party/blink/tools/",
- "//third_party/blink/web_tests/resources/",
- "//third_party/pywebsocket3/src/mod_pywebsocket/",
- "//third_party/test_fonts/test_fonts/",
- "//third_party/wpt_tools/",
- ]
- if (is_win) {
- data += [
- "//third_party/apache-win32/",
- "//third_party/perl/perl/",
- ]
- data_deps += [ "//build/win:copy_cdb_to_output" ]
- }
- if (is_mac) {
- data += [
- "//third_party/apache-mac/",
- "//third_party/apache-mac-arm64/",
- ]
- }
- if (is_linux || is_fuchsia) {
- data += [ "//third_party/apache-linux/" ]
- }
- if (is_android) {
- data += [
- "//third_party/catapult/",
- "//build/android/",
- ]
- }
- }
- _common_web_test_script = "//testing/scripts/run_isolated_script_test.py"
- _common_web_test_args = [ "@WrappedPath(" + rebase_path(
- "//third_party/blink/tools/run_web_tests.py",
- root_build_dir) + ")" ]
- if (is_debug) {
- _common_web_test_args += [ "--debug" ]
- } else {
- _common_web_test_args += [ "--release" ]
- if (dcheck_always_on) {
- _common_web_test_args += [ "--timeout-ms=12000" ]
- }
- }
- if (is_android) {
- _common_web_test_args += [
- "--platform",
- "android",
- ]
- }
- _common_web_test_args += [
- "--seed",
- "4",
- "--debug-rwt-logging",
- "--no-show-results",
- "--zero-tests-executed-ok",
- "--clobber-old-results",
- "--exit-after-n-failures",
- "5000",
- "--exit-after-n-crashes-or-timeouts",
- "100",
- ]
- # https://chromium.googlesource.com/chromium/src/+/main/docs/testing/web_tests.md
- script_test("blink_web_tests") {
- script = _common_web_test_script
- args = _common_web_test_args
- data_deps = [ ":blink_web_tests_support_data" ]
- data = [
- "//third_party/blink/perf_tests/",
- "//third_party/blink/web_tests/SmokeTests/Default.txt",
- "//third_party/blink/web_tests/VirtualTestSuites",
- # List all test expectations here
- "//third_party/blink/web_tests/ASANExpectations",
- "//third_party/blink/web_tests/LeakExpectations",
- "//third_party/blink/web_tests/MSANExpectations",
- "//third_party/blink/web_tests/NeverFixTests",
- "//third_party/blink/web_tests/SlowTests",
- "//third_party/blink/web_tests/StaleTestExpectations",
- "//third_party/blink/web_tests/TestExpectations",
- "//third_party/blink/web_tests/WebDriverExpectations",
- "//third_party/blink/web_tests/WebGPUExpectations",
- # Generic baselines
- "//third_party/blink/web_tests/platform/generic/",
- # === List Test Cases folders here ===
- "//third_party/blink/web_tests/accessibility/",
- "//third_party/blink/web_tests/android/",
- "//third_party/blink/web_tests/animations/",
- "//third_party/blink/web_tests/app_banner/",
- "//third_party/blink/web_tests/bindings/",
- "//third_party/blink/web_tests/clipboard/",
- "//third_party/blink/web_tests/compositing/",
- "//third_party/blink/web_tests/crypto/",
- "//third_party/blink/web_tests/css-parser/",
- "//third_party/blink/web_tests/css1/",
- "//third_party/blink/web_tests/css2.1/",
- "//third_party/blink/web_tests/css3/",
- "//third_party/blink/web_tests/cssom/",
- "//third_party/blink/web_tests/custom-elements/",
- "//third_party/blink/web_tests/custom-properties/",
- "//third_party/blink/web_tests/dark-mode/",
- "//third_party/blink/web_tests/document-transition/",
- "//third_party/blink/web_tests/dom/",
- "//third_party/blink/web_tests/editing/",
- "//third_party/blink/web_tests/fast/",
- "//third_party/blink/web_tests/fonts/",
- "//third_party/blink/web_tests/fragmentation/",
- "//third_party/blink/web_tests/fullscreen/",
- "//third_party/blink/web_tests/gamepad/",
- "//third_party/blink/web_tests/harness-tests/",
- "//third_party/blink/web_tests/hittesting/",
- "//third_party/blink/web_tests/html/",
- "//third_party/blink/web_tests/html5lib/",
- "//third_party/blink/web_tests/http/",
- "//third_party/blink/web_tests/idle-callback/",
- "//third_party/blink/web_tests/ietestcenter/",
- "//third_party/blink/web_tests/images/",
- "//third_party/blink/web_tests/inspector-protocol/",
- "//third_party/blink/web_tests/intersection-observer/",
- "//third_party/blink/web_tests/jquery/",
- "//third_party/blink/web_tests/js/",
- "//third_party/blink/web_tests/lifecycle/",
- "//third_party/blink/web_tests/loader/",
- "//third_party/blink/web_tests/media/",
- "//third_party/blink/web_tests/media_capabilities/",
- "//third_party/blink/web_tests/mhtml/",
- "//third_party/blink/web_tests/navigator_language/",
- "//third_party/blink/web_tests/navigator_webdriver/",
- "//third_party/blink/web_tests/netinfo/",
- "//third_party/blink/web_tests/overflow/",
- "//third_party/blink/web_tests/paint/",
- "//third_party/blink/web_tests/payments/",
- "//third_party/blink/web_tests/permissionclient/",
- "//third_party/blink/web_tests/plugins/",
- "//third_party/blink/web_tests/pointer-lock/",
- "//third_party/blink/web_tests/print_testharness/",
- "//third_party/blink/web_tests/printing/",
- "//third_party/blink/web_tests/register-protocol-handler/",
- "//third_party/blink/web_tests/regress/",
- "//third_party/blink/web_tests/resize-observer/",
- "//third_party/blink/web_tests/resources/",
- "//third_party/blink/web_tests/rootscroller/",
- "//third_party/blink/web_tests/screen_orientation/",
- "//third_party/blink/web_tests/scrollbars/",
- "//third_party/blink/web_tests/scrollingcoordinator/",
- "//third_party/blink/web_tests/security/",
- "//third_party/blink/web_tests/handwriting/",
- "//third_party/blink/web_tests/shadow-dom/",
- "//third_party/blink/web_tests/storage/",
- "//third_party/blink/web_tests/svg/",
- "//third_party/blink/web_tests/synthetic_gestures/",
- "//third_party/blink/web_tests/tables/",
- "//third_party/blink/web_tests/test_runner/",
- "//third_party/blink/web_tests/third_party/",
- "//third_party/blink/web_tests/timezonechange/",
- "//third_party/blink/web_tests/touchadjustment/",
- "//third_party/blink/web_tests/transforms/",
- "//third_party/blink/web_tests/transitions/",
- "//third_party/blink/web_tests/traversal/",
- "//third_party/blink/web_tests/typedcssom/",
- "//third_party/blink/web_tests/vibration/",
- "//third_party/blink/web_tests/virtual/",
- "//third_party/blink/web_tests/virtualkeyboard/",
- "//third_party/blink/web_tests/wake-lock/",
- "//third_party/blink/web_tests/wasm/",
- "//third_party/blink/web_tests/webaudio/",
- "//third_party/blink/web_tests/webexposed/",
- "//third_party/blink/web_tests/webgpu/",
- "//third_party/blink/web_tests/xmlviewer/",
- # === Test Case Folders Ends ===
- ]
- if (is_win || is_linux || is_fuchsia) {
- data += [
- "//third_party/blink/web_tests/platform/win/",
- "//third_party/blink/web_tests/platform/win10/",
- ]
- if (is_linux || is_fuchsia) {
- data += [ "//third_party/blink/web_tests/platform/linux/" ]
- }
- if (is_fuchsia) {
- data += [ "//third_party/blink/web_tests/platform/fuchsia/" ]
- }
- } else if (is_mac) {
- data += [
- "//third_party/blink/web_tests/SmokeTests/Mac.txt",
- "//third_party/blink/web_tests/platform/mac/",
- "//third_party/blink/web_tests/platform/mac-mac10.13/",
- "//third_party/blink/web_tests/platform/mac-mac10.14/",
- "//third_party/blink/web_tests/platform/mac-mac10.15/",
- "//third_party/blink/web_tests/platform/mac-mac11/",
- "//third_party/blink/web_tests/platform/mac-mac11-arm64/",
- "//third_party/blink/web_tests/platform/mac-mac12-arm64/",
- ]
- }
- # flag-specific tests only runs on linux as of now
- if (is_linux) {
- data += [
- "//third_party/blink/web_tests/FlagSpecificConfig",
- "//third_party/blink/web_tests/FlagExpectations/",
- "//third_party/blink/web_tests/flag-specific/",
- ]
- }
- }
- script_test("blink_wpt_tests") {
- script = _common_web_test_script
- args = _common_web_test_args
- data_deps = [ ":blink_web_tests_support_data" ]
- data = [
- "//third_party/blink/perf_tests/",
- "//third_party/blink/web_tests/SmokeTests/Default.txt",
- "//third_party/blink/web_tests/VirtualTestSuites",
- # List all test expectations here
- "//third_party/blink/web_tests/ASANExpectations",
- "//third_party/blink/web_tests/LeakExpectations",
- "//third_party/blink/web_tests/MSANExpectations",
- "//third_party/blink/web_tests/NeverFixTests",
- "//third_party/blink/web_tests/SlowTests",
- "//third_party/blink/web_tests/StaleTestExpectations",
- "//third_party/blink/web_tests/TestExpectations",
- "//third_party/blink/web_tests/WebDriverExpectations",
- "//third_party/blink/web_tests/WebGPUExpectations",
- # Generic baselines
- "//third_party/blink/web_tests/platform/generic/",
- # === List Test Cases folders here ===
- "//third_party/blink/web_tests/external/",
- "//third_party/blink/web_tests/wpt_internal/",
- # === Test Case Folders Ends ===
- ]
- if (is_win || is_linux || is_fuchsia) {
- data += [
- "//third_party/blink/web_tests/platform/win/",
- "//third_party/blink/web_tests/platform/win10/",
- ]
- if (is_linux || is_fuchsia) {
- data += [ "//third_party/blink/web_tests/platform/linux/" ]
- }
- if (is_fuchsia) {
- data += [ "//third_party/blink/web_tests/platform/fuchsia/" ]
- }
- } else if (is_mac) {
- data += [
- "//third_party/blink/web_tests/SmokeTests/Mac.txt",
- "//third_party/blink/web_tests/platform/mac/",
- "//third_party/blink/web_tests/platform/mac-mac10.13/",
- "//third_party/blink/web_tests/platform/mac-mac10.14/",
- "//third_party/blink/web_tests/platform/mac-mac10.15/",
- "//third_party/blink/web_tests/platform/mac-mac11-arm64/",
- ]
- }
- # flag-specific tests only runs on linux as of now
- if (is_linux) {
- data += [
- "//third_party/blink/web_tests/FlagSpecificConfig",
- "//third_party/blink/web_tests/FlagExpectations/",
- "//third_party/blink/web_tests/flag-specific/",
- ]
- }
- }
- script_test("devtools_web_tests") {
- # This target differs from :blink_web_tests in that it uses the
- # same test harness but runs an entirely different set of tests
- # and doesn't have a dependency on the web_test directory at all.
- script = _common_web_test_script
- args = _common_web_test_args + [
- "--layout-tests-directory=@WrappedPath(" + rebase_path(
- "//third_party/devtools-frontend/src/test/webtests",
- root_out_dir) + ")",
- "http/tests/devtools",
- ]
- data_deps = [ ":blink_web_tests_support_data" ]
- data = [ "//third_party/devtools-frontend/src/test/webtests/" ]
- }
- script_test("webgpu_blink_web_tests") {
- # This target differs from :blink_web_tests in that it uses the same
- # test harness and a few additional flags but, more importantly, only runs
- # the web_tests/wpt_internal/webgpu tests, so it doesn't have a data
- # dependency on the whole web_test directory.
- script = _common_web_test_script
- args = _common_web_test_args
- if (is_asan) {
- args += [ "--timeout-ms=30000" ]
- }
- args += [
- "--ignore-default-expectations",
- "--additional-expectations",
- "@WrappedPath(../../third_party/blink/web_tests/WebGPUExpectations)",
- "--isolated-script-test-filter=wpt_internal/webgpu/web_platform/reftests/*",
- ]
- data_deps = [
- ":blink_web_tests_support_data",
- "//third_party/webgpu-cts",
- ]
- data = [
- "//third_party/blink/web_tests/external/wpt/common/",
- "//third_party/blink/web_tests/external/wpt/resources/",
- "//third_party/blink/web_tests/FlagSpecificConfig",
- "//third_party/blink/web_tests/VirtualTestSuites",
- "//third_party/blink/web_tests/WebGPUExpectations",
- "//third_party/blink/web_tests/wpt_internal/",
- "//third_party/webgpu-cts/scripts/",
- ]
- }
- copy("layout_test_data_mojo_bindings") {
- testonly = true
- sources = [ "$root_gen_dir/mojo/public/js/mojo_bindings.js" ]
- outputs =
- [ "$root_gen_dir/layout_test_data/mojo/public/js/mojo_bindings.js" ]
- deps = [ "//mojo/public/js:bindings" ]
- }
- copy("layout_test_data_mojo_bindings_lite") {
- testonly = true
- sources = [ "$root_gen_dir/mojo/public/js/mojo_bindings_lite.js" ]
- outputs = [
- "$root_gen_dir/layout_test_data/mojo/public/js/mojo_bindings_lite.js",
- ]
- deps = [ "//mojo/public/js:bindings_lite" ]
- }
- script_test("blink_python_tests") {
- script = "//testing/scripts/run_isolated_script_test.py"
- args = [ "@WrappedPath(" +
- rebase_path("//third_party/blink/tools/run_blinkpy_tests.py",
- root_build_dir) + ")" ]
- data = [
- # These tests use //build/android/devil_chromium.py even when !is_android,
- # so cannot use the helpers in //build/android (they assert(is_android)).
- "//build/android/",
- "//build/gn_helpers.py",
- "//build/config/gclient_args.gni",
- "//build/skia_gold_common/",
- "//components/crash/content/tools/generate_breakpad_symbols.py",
- "//testing/unexpected_passes_common/",
- "//third_party/blink/renderer/bindings/scripts/",
- "//third_party/blink/renderer/build/scripts/",
- "//third_party/blink/tools/",
- "//third_party/blink/web_tests/ASANExpectations",
- "//third_party/blink/web_tests/LeakExpectations",
- "//third_party/blink/web_tests/MSANExpectations",
- "//third_party/blink/web_tests/NeverFixTests",
- "//third_party/blink/web_tests/SlowTests",
- "//third_party/blink/web_tests/StaleTestExpectations",
- "//third_party/blink/web_tests/TestExpectations",
- "//third_party/blink/web_tests/VirtualTestSuites",
- "//third_party/catapult/common/py_utils/",
- "//third_party/catapult/devil/",
- "//third_party/catapult/dependency_manager/",
- "//third_party/catapult/third_party/typ/",
- "//third_party/depot_tools/pylint-1.5",
- "//third_party/depot_tools/pylint_main.py",
- "//third_party/depot_tools/pylintrc",
- "//third_party/ply/",
- "//third_party/wpt_tools/",
- "//tools/idl_parser/",
- ]
- data_deps = [ "//ui/base:goldctl" ]
- }
- }
- # TODO(cassew): Add more OS's that don't support x86.
- is_valid_x86_target =
- target_os != "ios" && target_os != "mac" &&
- (target_os != "linux" || use_libfuzzer || !build_with_chromium)
- # Note: v8_target_cpu == arm allows using the V8 arm simulator on x86 for fuzzing.
- assert(
- is_valid_x86_target || target_cpu != "x86" || v8_target_cpu == "arm",
- "'target_cpu=x86' is not supported for 'target_os=$target_os'. Consider omitting 'target_cpu' (default) or using 'target_cpu=x64' instead.")
- group("chromium_builder_perf") {
- testonly = true
- if (!is_ios && !is_android && !is_castos) {
- data_deps = [
- "//cc:cc_perftests",
- "//chrome/test:load_library_perf_tests",
- "//chrome/test:performance_test_suite",
- "//components/tracing:tracing_perftests",
- "//gpu:command_buffer_perftests",
- "//gpu:gpu_perftests",
- "//media:media_perftests",
- "//tools/perf/chrome_telemetry_build:telemetry_chrome_test",
- ]
- if (!is_chromeos_ash) {
- data_deps += [ "//chrome/test:performance_browser_tests" ]
- }
- if (!is_win) {
- data_deps +=
- [ "//third_party/breakpad:minidump_stackwalk($host_toolchain)" ]
- }
- }
- 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" ]
- }
- 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_castos) {
- group("chromium_builder_asan") {
- testonly = true
- deps = [
- "//chrome:chrome",
- "//content/shell:content_shell",
- "//third_party/blink/public/mojom:mojom_modules_js",
- "//v8:d8",
- ]
- if (!is_win) {
- deps += [ "//skia:filter_fuzz_stub" ]
- }
- if (enable_ipc_fuzzer && !is_component_build) {
- deps += [ "//tools/ipc_fuzzer:ipc_fuzzer_all" ]
- }
- if (!is_chromeos_ash) {
- deps += [
- "//third_party/pdfium/samples:pdfium_test",
- "//v8:v8_shell($v8_snapshot_toolchain)",
- ]
- }
- if (!is_component_build) {
- # See https://bugs.chromium.org/p/chromium/issues/detail?id=942546#c11.
- deps += [
- "//third_party/webrtc/rtc_tools:rtp_generator",
- "//third_party/webrtc/rtc_tools:video_replay",
- ]
- }
- if (build_dawn_tests) {
- deps += [ "//third_party/dawn/src/tint/fuzzers:fuzzers" ]
- }
- }
- }
- if (is_android) {
- group("optimize_gn_gen") {
- deps = [
- # These run expensive scripts in non-default toolchains. Generally, host
- # toolchain targets are loaded in the later part of the run, and the
- # result is they push out the end of generation. By preloading these, the
- # scripts can be parallelized with the rest of the load.
- "//build/config/linux(//build/toolchain/linux:clang_x64)",
- "//build/config/posix(//build/toolchain/linux:clang_x64)",
- # Include x86 toolchains as well since V8 uses them for 32-bit snapshot
- # generation.
- "//build/config/linux(//build/toolchain/linux:clang_x86)",
- "//build/config/posix(//build/toolchain/linux:clang_x86)",
- ]
- }
- }
- if (enable_js_type_check) {
- group("webui_closure_compile") {
- testonly = true
- data_deps = [
- "components/neterror/resources:closure_compile",
- "components/security_interstitials:closure_compile",
- "mojo/public/tools/bindings/generators/js_templates/lite/test:closure_compile",
- "ui/webui/resources:closure_compile",
- ]
- if (is_chromeos_ash) {
- data_deps += [
- "ash/webui:closure_compile",
- "ui/file_manager:closure_compile",
- ]
- }
- if (!is_castos) {
- data_deps += [
- "chrome/browser/resources:closure_compile",
- "chrome/test:closure_compile",
- ]
- }
- }
- }
- # Write debug logs to gn_logs.txt.
- _lines = [
- "Generated during 'gn gen' by //BUILD.gn.",
- "",
- ] + build_gn_logs
- # GN evaluates each .gn file once per toolchain, so restricting to default
- # toolchain will ensure write_file() is called only once.
- assert(current_toolchain == default_toolchain)
- write_file("$root_build_dir/gn_logs.txt", _lines)
|