diff --git a/docs/gen/build_arguments.md b/docs/gen/build_arguments.md index ac40c19e58226964ba570eb1a91a5277630f3622..1819d4e69fe66ee39ee8d14b549e5966d2fb6113 100644 --- a/docs/gen/build_arguments.md +++ b/docs/gen/build_arguments.md @@ -2,1338 +2,1414 @@ ## All builds -### minfs_minimum_data_bytes +### linux_runner_extras +If `true`, the extras.img will be built and mounted inside the container +at /mnt/chromeos. -**Current value (from the default):** `""` +This is useful for including some GN-built binaries into the guest image +without modifying the termina images. -From //build/images/fvm.gni:37 +**Current value (from the default):** `false` -### sdk_id -Identifier for the Core SDK. +From //garnet/bin/guest/pkg/biscotti_guest/linux_runner/BUILD.gn:26 + +### minfs_maximum_bytes **Current value (from the default):** `""` -From //sdk/config.gni:7 +From //build/images/fvm.gni:48 -### skia_enable_ccpr +### skia_pdf_subset_harfbuzz +TODO: set skia_pdf_subset_harfbuzz to skia_use_harfbuzz. -**Current value (from the default):** `true` +**Current value (from the default):** `false` -From //third_party/skia/BUILD.gn:41 +From //third_party/skia/gn/skia.gni:18 -### extra_variants -Additional variant toolchain configs to support. -This is just added to [`known_variants`](#known_variants). +### skia_use_vulkan -**Current value (from the default):** `[]` +**Current value (from the default):** `false` -From //build/config/BUILDCONFIG.gn:402 +From //third_party/skia/BUILD.gn:87 -### scenic_use_views2 -Temporary flag, switches Flutter to using Scenic's new View API. +### debian_guest_qcow +Package the rootfs as a QCOW image (as opposed to a flat file). -**Current value (from the default):** `false` +**Current value (from the default):** `true` -From //garnet/bin/ui/scenic/config.gni:7 +From //garnet/bin/guest/pkg/debian_guest/BUILD.gn:9 -### skia_llvm_lib +### known_variants +List of variants that will form the basis for variant toolchains. +To make use of a variant, set [`select_variant`](#select_variant). -**Current value (from the default):** `"LLVM"` +Normally this is not set as a build argument, but it serves to +document the available set of variants. +See also [`universal_variants`](#universal_variants). +Only set this to remove all the default variants here. +To add more, set [`extra_variants`](#extra_variants) instead. -From //third_party/skia/BUILD.gn:57 +Each element of the list is one variant, which is a scope defining: -### target_sysroot -The absolute path of the sysroot that is used with the target toolchain. + `configs` (optional) + [list of labels] Each label names a config that will be + automatically used by every target built in this variant. + For each config `${label}`, there must also be a target + `${label}_deps`, which each target built in this variant will + automatically depend on. The `variant()` template is the + recommended way to define a config and its `_deps` target at + the same time. -**Current value (from the default):** `""` + `remove_common_configs` (optional) + `remove_shared_configs` (optional) + [list of labels] This list will be removed (with `-=`) from + the `default_common_binary_configs` list (or the + `default_shared_library_configs` list, respectively) after + all other defaults (and this variant's configs) have been + added. -From //build/config/sysroot.gni:7 + `deps` (optional) + [list of labels] Added to the deps of every target linked in + this variant (as well as the automatic `${label}_deps` for + each label in configs). -### msd_arm_enable_all_cores -Enable all 8 cores, which is faster but emits more heat. + `name` (required if configs is omitted) + [string] Name of the variant as used in + [`select_variant`](#select_variant) elements' `variant` fields. + It's a good idea to make it something concise and meaningful when + seen as e.g. part of a directory name under `$root_build_dir`. + If name is omitted, configs must be nonempty and the simple names + (not the full label, just the part after all `/`s and `:`s) of these + configs will be used in toolchain names (each prefixed by a "-"), + so the list of config names forming each variant must be unique + among the lists in `known_variants + extra_variants`. -**Current value (from the default):** `true` + `toolchain_args` (optional) + [scope] Each variable defined in this scope overrides a + build argument in the toolchain context of this variant. -From //garnet/drivers/gpu/msd-arm-mali/src/BUILD.gn:9 + `host_only` (optional) + `target_only` (optional) + [scope] This scope can contain any of the fields above. + These values are used only for host or target, respectively. + Any fields included here should not also be in the outer scope. -### signed_image -**Current value (from the default):** `false` +**Current value (from the default):** +``` +[{ + configs = ["//build/config/lto"] +}, { + configs = ["//build/config/lto:thinlto"] +}, { + configs = ["//build/config/profile"] +}, { + configs = ["//build/config/scudo"] +}, { + configs = ["//build/config/sanitizers:ubsan"] +}, { + configs = ["//build/config/sanitizers:ubsan", "//build/config/sanitizers:sancov"] +}, { + configs = ["//build/config/sanitizers:asan"] + host_only = { + remove_shared_configs = ["//build/config:symbol_no_undefined"] +} + toolchain_args = { + use_scudo = false +} +}, { + configs = ["//build/config/sanitizers:asan", "//build/config/sanitizers:sancov"] + host_only = { + remove_shared_configs = ["//build/config:symbol_no_undefined"] +} + toolchain_args = { + use_scudo = false +} +}, { + configs = ["//build/config/sanitizers:asan"] + host_only = { + remove_shared_configs = ["//build/config:symbol_no_undefined"] +} + name = "asan_no_detect_leaks" + toolchain_args = { + asan_default_options = "detect_leaks=0" + use_scudo = false +} +}, { + configs = ["//build/config/sanitizers:asan", "//build/config/sanitizers:fuzzer"] + host_only = { + remove_shared_configs = ["//build/config:symbol_no_undefined"] +} + remove_shared_configs = ["//build/config:symbol_no_undefined"] + toolchain_args = { + asan_default_options = "alloc_dealloc_mismatch=0" + use_scudo = false +} +}, { + configs = ["//build/config/sanitizers:ubsan", "//build/config/sanitizers:fuzzer"] + remove_shared_configs = ["//build/config:symbol_no_undefined"] +}] +``` -From //build/images/BUILD.gn:46 +From //build/config/BUILDCONFIG.gn:337 -### skia_enable_fontmgr_custom +### linux_runner_ip +Default values for the guest network configuration. -**Current value (from the default):** `true` +These are currently hard-coded to match what is setup in the virtio-net +device. -From //third_party/skia/BUILD.gn:67 +See //garnet/bin/guest/vmm/device/virtio_net.cc for more details. -### skia_use_sfntly +**Current value (from the default):** `"10.0.0.2"` -**Current value for `target_cpu = "arm64"`:** `false` +From //garnet/bin/guest/pkg/biscotti_guest/linux_runner/BUILD.gn:17 -From //.gn:30 +### scenic_ignore_vsync -**Overridden from the default:** `true` +**Current value (from the default):** `false` -From //third_party/skia/BUILD.gn:63 +From //garnet/lib/ui/gfx/BUILD.gn:8 -**Current value for `target_cpu = "x64"`:** `false` +### allow_layer_guesswork +Does nothing. -From //.gn:30 +Will be removed after 30 April 2019. -**Overridden from the default:** `false` +**Current value (from the default):** `false` -From //third_party/skia/BUILD.gn:63 +From //BUILD.gn:39 -### use_prebuilt_ffmpeg -Use a prebuilt ffmpeg binary rather than building it locally. See -//src/media/lib/ffmpeg/README.md for details. This is ignored when -building in variant builds for which there is no prebuilt. In that -case, ffmpeg is always built from source so as to be built with the -selected variant's config. When this is false (either explicitly or in -a variant build) then //third_party/ffmpeg must be in the source tree, -which requires: -`jiri import -name integration third_party/ffmpeg https://fuchsia.googlesource.com/integration` +### skia_enable_gpu **Current value (from the default):** `true` -From //src/media/lib/ffmpeg/BUILD.gn:14 +From //third_party/skia/gn/skia.gni:11 -### fuchsia_vulkan_sdk -Path to Fuchsia Vulkan SDK +### zircon_r_partition -**Current value (from the default):** `"//third_party/vulkan_loader_and_validation_layers"` +**Current value (from the default):** `""` -From //build/vulkan/config.gni:10 +From //build/images/BUILD.gn:41 -### meta_package_labels -A list of labels for meta packages to be included in the monolith. +### scenic_use_new_renderer +Specifies whether Scenic uses the new "PaperRenderer2" when +rendering Scenes with fuchsia.ui.gfx.ShadowTechnique.UNSHADOWED. -**Current value for `target_cpu = "arm64"`:** `["//build/images:config-data", "//build/images:shell-commands", "//garnet/bin/component_index:component_index"]` +**Current value (from the default):** `true` -From //products/core.gni:11 +From //garnet/lib/ui/gfx/BUILD.gn:12 -**Overridden from the default:** `[]` +### linux_runner_netmask -From //build/images/BUILD.gn:36 +**Current value (from the default):** `"255.255.255.0"` -**Current value for `target_cpu = "x64"`:** `["//build/images:config-data", "//build/images:shell-commands", "//garnet/bin/component_index:component_index"]` +From //garnet/bin/guest/pkg/biscotti_guest/linux_runner/BUILD.gn:19 -From //products/core.gni:11 +### skia_qt_path -**Overridden from the default:** `[]` +**Current value (from the default):** `""` -From //build/images/BUILD.gn:36 +From //third_party/skia/BUILD.gn:49 -### zircon_build_root +### skia_use_fontconfig -**Current value (from the default):** `"//zircon"` +**Current value for `target_cpu = "arm64"`:** `false` -From //garnet/lib/magma/gnbuild/magma.gni:12 +From //.gn:28 -### data_partition_manifest -Path to manifest file containing data to place into the initial /data -partition. +**Overridden from the default:** `true` -**Current value (from the default):** `""` +From //third_party/skia/BUILD.gn:23 -From //build/images/BUILD.gn:28 +**Current value for `target_cpu = "x64"`:** `false` -### engine_version +From //.gn:28 -**Current value (from the default):** `""` +**Overridden from the default:** `false` -From //third_party/flutter/shell/version/version.gni:6 +From //third_party/skia/BUILD.gn:23 -### dart_version_git_info -Whether the Dart binary version string should include the git hash and -git commit time. +### use_ccache +Set to true to enable compiling with ccache -**Current value (from the default):** `true` +**Current value (from the default):** `false` -From //third_party/dart/runtime/runtime_args.gni:60 +From //build/toolchain/ccache.gni:9 -### flutter_space_dart -Whether experimental space dart mode is enabled for Flutter applications. +### zircon_build_root -**Current value (from the default):** `false` +**Current value (from the default):** `"//zircon"` -From [//topaz/runtime/dart/dart_component.gni:38](https://fuchsia.googlesource.com/topaz/+/ff9f85507acd416f76801f1a561574b28c48446d/runtime/dart/dart_component.gni#38) +From //garnet/lib/magma/gnbuild/magma.gni:12 -### scudo_default_options -Default [Scudo](https://llvm.org/docs/ScudoHardenedAllocator.html) -options (before the `SCUDO_OPTIONS` environment variable is read at -runtime). *NOTE:* This affects only components using the `scudo` -variant (see GN build argument `select_variant`), and does not affect -anything when the `use_scudo` build flag is set instead. +### kernel_cmdline_files +Files containing additional kernel command line arguments to bake into +the boot image. The contents of these files (in order) come after any +arguments directly in [`kernel_cmdline_args`](#kernel_cmdline_args). +These can be GN `//` source pathnames or absolute system pathnames. -**Current value (from the default):** `["abort_on_error=1", "QuarantineSizeKb=0", "ThreadLocalQuarantineSizeKb=0", "DeallocationTypeMismatch=false", "DeleteSizeMismatch=false", "allocator_may_return_null=true"]` +**Current value (from the default):** `[]` -From //build/config/scudo/scudo.gni:17 +From //build/images/BUILD.gn:476 -### shell_enable_vulkan +### skia_enable_spirv_validation **Current value (from the default):** `false` -From //third_party/flutter/shell/config.gni:6 +From //third_party/skia/BUILD.gn:46 -### skia_use_freetype +### skia_skqp_global_error_tolerance -**Current value (from the default):** `true` +**Current value (from the default):** `0` -From //third_party/skia/BUILD.gn:25 +From //third_party/skia/BUILD.gn:54 -### zircon_b_partition +### skia_use_expat -**Current value (from the default):** `""` +**Current value for `target_cpu = "arm64"`:** `false` -From //build/images/BUILD.gn:40 +From //.gn:27 -### kernel_cmdline_args -List of kernel command line arguments to bake into the boot image. -See also //zircon/docs/kernel_cmdline.md and -[`devmgr_config`](#devmgr_config). +**Overridden from the default:** `true` -**Current value (from the default):** `[]` +From //third_party/skia/BUILD.gn:22 -From //build/images/BUILD.gn:470 +**Current value for `target_cpu = "x64"`:** `false` -### zxcrypt_key_source -This argument specifies from where the system should obtain the zxcrypt -master key to the system data partition. +From //.gn:27 -This value be reified as /boot/config/zxcrypt in both the zircon boot image -and the zedboot boot image, for consumption by fshost and the paver, -respectively. +**Overridden from the default:** `true` -Acceptable values are: -* "null": the device should use an all-0's master key, as we lack support -for any secure on-device storage. -* "tee": the device is required to have a Trusted Execution Environment -(TEE) which includes the "keysafe" Trusted Application (associated with the -KMS service). The zxcrypt master key should be derived from a per-device -key accessible only to trusted apps running in the TEE. +From //third_party/skia/BUILD.gn:22 -In the future, we may consider adding support for TPMs, or additional logic -to explicitly support fallback behavior. +### skia_use_harfbuzz -**Current value (from the default):** `"null"` +**Current value (from the default):** `true` -From //build/images/zxcrypt.gni:23 +From //third_party/skia/gn/skia.gni:14 -### use_lto -Use link time optimization (LTO). +### vbmeta_a_partition -**Current value (from the default):** `false` +**Current value (from the default):** `""` -From //build/config/lto/config.gni:7 +From //build/images/BUILD.gn:42 -### board_name -Board name used for paving and amber updates. +### skia_compile_processors -**Current value (from the default):** `""` +**Current value (from the default):** `false` -From //build/package.gni:21 +From //third_party/skia/BUILD.gn:50 -### cloudkms_key_dir +### max_fvm_size +Maximum allowable size for the FVM in a release mode build +Zero means no limit -**Current value (from the default):** `"projects/fuchsia-infra/locations/global/keyRings/test-secrets/cryptoKeys"` +**Current value (from the default):** `"0"` -From //build/testing/secret_spec.gni:8 +From //build/images/max_fvm_size.gni:8 -### magma_enable_developer_build -Enable this to have the msd include a suite of tests and invoke them -automatically when the driver starts. +### base_package_labels +If you add package labels to this variable, the packages will be included in +the 'base' package set, which represents the set of packages that are part +of an OTA. These pacakages are updated as an atomic unit during an OTA +process and are immutable and are a superset of the TCB (Trusted Computing +Base) for a product. These packages are never evicted by the system. -**Current value (from the default):** `false` +**Current value for `target_cpu = "arm64"`:** `["//garnet/packages/config:kernel_crash_checker", "//garnet/packages/prod:crashpad_agent", "//garnet/packages/prod:feedback_agent", "//garnet/packages/prod:kernel_crash_checker", "//garnet/packages/products:base", "//bundles:kitchen_sink"]` -From //garnet/lib/magma/gnbuild/magma.gni:21 +From //root_build_dir/args.gn:3 -### minfs_maximum_bytes +**Overridden from the default:** `[]` -**Current value (from the default):** `""` +From //BUILD.gn:14 -From //build/images/fvm.gni:48 +**Current value for `target_cpu = "x64"`:** `["//garnet/packages/config:kernel_crash_checker", "//garnet/packages/prod:crashpad_agent", "//garnet/packages/prod:feedback_agent", "//garnet/packages/prod:kernel_crash_checker", "//garnet/packages/products:base", "//bundles:kitchen_sink"]` -### rust_lto -Sets the default LTO type for rustc bulids. +From //root_build_dir/args.gn:3 -**Current value (from the default):** `"unset"` +**Overridden from the default:** `[]` -From //build/rust/config.gni:20 +From //BUILD.gn:14 -### skia_use_harfbuzz +### skia_enable_nima -**Current value (from the default):** `true` +**Current value (from the default):** `false` -From //third_party/skia/gn/skia.gni:14 +From //third_party/skia/BUILD.gn:44 -### enable_input_subsystem +### blobfs_maximum_bytes +In addition to reserving space for inodes and data, fs needs additional +space for maintaining some internal data structures. So the +space required to reserve inodes and data may exceed sum of the space +needed for inodes and data. +maximum_bytes puts an upper bound on the total bytes reserved for inodes, +data bytes and reservation for all other internal fs metadata. +An empty string does not put any upper bound. A filesystem may +reserve few blocks required for its operations. -**Current value (from the default):** `true` +**Current value (from the default):** `""` -From //garnet/bin/ui/scenic/BUILD.gn:14 +From //build/images/fvm.gni:47 -### export_x64_sdk_images +### dart_use_tcmalloc +Whether to link the standalone VM against tcmalloc. The standalone build of +the VM enables this only for Linux builds. **Current value (from the default):** `false` -From //sdk/BUILD.gn:12 - -### host_os - -**Current value (from the default):** `"linux"` +From //third_party/dart/runtime/runtime_args.gni:47 -### host_tools_dir -This is the directory where host tools intended for manual use by -developers get installed. It's something a developer might put -into their shell's $PATH. Host tools that are just needed as part -of the build do not get copied here. This directory is only for -things that are generally useful for testing or debugging or -whatnot outside of the GN build itself. These are only installed -by an explicit install_host_tools() rule (see //build/host.gni). +### fvm_image_size +The size in bytes of the FVM partition image to create. Normally this is +computed to be just large enough to fit the blob and data images. The +default value is "", which means to size based on inputs. Specifying a size +that is too small will result in build failure. -**Current value (from the default):** `"//root_build_dir/tools"` +**Current value (from the default):** `""` -From //build/host.gni:13 +From //build/images/fvm.gni:12 -### is_debug -Debug build. +### go_vet_enabled + go_vet_enabled + [bool] if false, go vet invocations are disabled for all builds. -**Current value (from the default):** `true` +**Current value (from the default):** `false` -From //build/config/BUILDCONFIG.gn:11 +From //build/go/go_build.gni:20 -### msd_arm_enable_cache_coherency -With this flag set the system tries to use cache coherent memory if the -GPU supports it. +### use_account_manager +Whether basemgr and dev_base_shell should use account_manager for account +creation. This is a temporary flag while modular transitions to use account +manager. **Current value (from the default):** `true` -From //garnet/drivers/gpu/msd-arm-mali/src/BUILD.gn:13 +From //peridot/bin/basemgr/BUILD.gn:18 -### skia_use_lua +### dart_runtime_mode +Set the runtime mode. This affects how the runtime is built and what +features it has. Valid values are: +'develop' (the default) - VM is built to run as a JIT with all development +features enabled. +'profile' - The VM is built to run with AOT compiled code with only the +CPU profiling features enabled. +'release' - The VM is built to run with AOT compiled code with no developer +features enabled. -**Current value (from the default):** `false` +These settings are only used for Flutter, at the moment. A standalone build +of the Dart VM should leave this set to "develop", and should set +'is_debug', 'is_release', or 'is_product'. -From //third_party/skia/BUILD.gn:30 +TODO(rmacnak): dart_runtime_mode no longer selects whether libdart is build +for JIT or AOT, since libdart waw split into libdart_jit and +libdart_precompiled_runtime. We should remove this flag and just set +dart_debug/dart_product. -### concurrent_rust_jobs -Maximum number of Rust processes to run in parallel. +**Current value (from the default):** `"develop"` -We run multiple rustc jobs in parallel, each of which can cause significant -amount of memory, especially when using LTO. To avoid out-of-memory errors -we explicitly reduce the number of jobs. +From //third_party/dart/runtime/runtime_args.gni:28 -**Current value (from the default):** `14` +### sdk_dirs +The directories to search for parts of the SDK. -From //build/rust/BUILD.gn:15 +By default, we search the public directories for the various layers. +In the future, we'll search a pre-built SDK as well. -### debian_guest_earlycon +**Current value (from the default):** `["//garnet/public", "//peridot/public", "//topaz/public"]` -**Current value (from the default):** `false` +From //build/config/fuchsia/sdk.gni:10 -From //garnet/bin/guest/pkg/debian_guest/BUILD.gn:10 +### skia_enable_flutter_defines -### extra_manifest_args -Extra args to globally apply to the manifest generation script. +**Current value for `target_cpu = "arm64"`:** `true` -**Current value (from the default):** `[]` +From //.gn:24 -From //build/images/manifest.gni:22 +**Overridden from the default:** `false` -### use_scudo -TODO(davemoore): Remove this entire mechanism once standalone scudo is the -default (DNO-442) -Enable the [Scudo](https://llvm.org/docs/ScudoHardenedAllocator.html) -memory allocator. +From //third_party/skia/BUILD.gn:16 -**Current value (from the default):** `false` +**Current value for `target_cpu = "x64"`:** `true` -From //build/config/scudo/scudo.gni:10 +From //.gn:24 -### crash_diagnostics_dir -Clang crash reports directory path. Use empty path to disable altogether. +**Overridden from the default:** `false` -**Current value (from the default):** `"//root_build_dir/clang-crashreports"` +From //third_party/skia/BUILD.gn:16 -From //build/config/BUILD.gn:9 +### zircon_asserts -### skia_skqp_global_error_tolerance +**Current value (from the default):** `true` -**Current value (from the default):** `0` +From //build/config/fuchsia/BUILD.gn:201 -From //third_party/skia/BUILD.gn:54 +### flutter_profile -### vbmeta_r_partition +**Current value (from the default):** `true` -**Current value (from the default):** `""` +From [//topaz/runtime/dart/dart_component.gni:32](https://fuchsia.googlesource.com/topaz/+/ff9f85507acd416f76801f1a561574b28c48446d/runtime/dart/dart_component.gni#32) -From //build/images/BUILD.gn:44 +### skia_use_libpng -### enable_sketchy_subsystem +**Current value (from the default):** `true` -**Current value (from the default):** `false` +From //third_party/skia/BUILD.gn:28 -From //garnet/bin/ui/scenic/BUILD.gn:13 - -### skia_use_metal +### dart_space_dart +Whether experimental space dart mode is enabled for Dart applications. **Current value (from the default):** `false` -From //third_party/skia/BUILD.gn:35 +From [//topaz/runtime/dart/dart_component.gni:41](https://fuchsia.googlesource.com/topaz/+/ff9f85507acd416f76801f1a561574b28c48446d/runtime/dart/dart_component.gni#41) -### symbol_level -How many symbols to include in the build. This affects the performance of -the build since the symbols are large and dealing with them is slow. - 2 means regular build with symbols. - 1 means minimal symbols, usually enough for backtraces only. Symbols with -internal linkage (static functions or those in anonymous namespaces) may not -appear when using this level. - 0 means no symbols. +### use_vboot +Use vboot images -**Current value (from the default):** `2` +**Current value (from the default):** `false` -From //build/config/compiler.gni:13 +From //build/images/boot.gni:11 -### always_zedboot -Build boot images that prefer Zedboot over local boot (only for EFI). +### host_cpu -**Current value (from the default):** `false` +**Current value (from the default):** `"x64"` -From //build/images/BUILD.gn:796 +### flutter_aot_sharing_basis +When AOT compiling, an app will reference objects in the sharing basis's +snapshot when available instead of writing the objects in its own snapshot. +The snapshot of the sharing basis app will be included in every other app's +package and deduplicated by blobfs. -### magma_python_path +**Current value (from the default):** `""` -**Current value (from the default):** `"/b/s/w/ir/k/third_party/mako"` +From [//topaz/runtime/dart/dart_component.gni:27](https://fuchsia.googlesource.com/topaz/+/ff9f85507acd416f76801f1a561574b28c48446d/runtime/dart/dart_component.gni#27) -From //garnet/lib/magma/gnbuild/magma.gni:14 +### concurrent_dart_jobs +Maximum number of Dart processes to run in parallel. -### prebuilt_dart_sdk -Directory containing prebuilt Dart SDK. -This must have in its `bin/` subdirectory `gen_snapshot.OS-CPU` binaries. -Set to empty for a local build. +Dart analyzer uses a lot of memory which may cause issues when building +with many parallel jobs e.g. when using goma. To avoid out-of-memory +errors we explicitly reduce the number of jobs. -**Current value (from the default):** `"//topaz/tools/prebuilt-dart-sdk/linux-x64"` +**Current value (from the default):** `16` -From //build/dart/dart.gni:9 +From //build/dart/BUILD.gn:15 -### skia_tools_require_resources +### max_log_disk_usage +Controls how many bytes of space on disk are used to persist device logs. +Should be a string value that only contains digits. -**Current value (from the default):** `false` +**Current value (from the default):** `"0"` -From //third_party/skia/BUILD.gn:59 +From //garnet/bin/log_listener/BUILD.gn:13 -### system_package_key -The package key to use for signing Fuchsia packages made by the -`package()` template (and the `system_image` package). If this -doesn't exist yet when it's needed, it will be generated. New -keys can be generated with the `pm -k FILE genkey` host command. +### use_prebuilt_ffmpeg +Use a prebuilt ffmpeg binary rather than building it locally. See +//src/media/lib/ffmpeg/README.md for details. This is ignored when +building in variant builds for which there is no prebuilt. In that +case, ffmpeg is always built from source so as to be built with the +selected variant's config. When this is false (either explicitly or in +a variant build) then //third_party/ffmpeg must be in the source tree, +which requires: +`jiri import -name integration third_party/ffmpeg https://fuchsia.googlesource.com/integration` -**Current value (from the default):** `"//build/development.key"` +**Current value (from the default):** `true` -From //build/package.gni:18 +From //src/media/lib/ffmpeg/BUILD.gn:14 -### use_goma -Set to true to enable distributed compilation using Goma. +### clang_lib_dir +Path to Clang lib directory. -**Current value (from the default):** `false` +**Current value (from the default):** `"../build/buildtools/linux-x64/clang/lib"` -From //build/toolchain/goma.gni:9 +From //build/images/manifest.gni:19 -### build_sdk_archives -Whether to build SDK tarballs. +### dart_vm_code_coverage +Whether to enable code coverage for the standalone VM. **Current value (from the default):** `false` -From //build/sdk/sdk.gni:13 +From //third_party/dart/runtime/runtime_args.gni:39 -### msd_arm_enable_protected_debug_swap_mode -In protected mode, faults don't return as much information so they're much harder to debug. To -work around that, add a mode where protected atoms are executed in non-protected mode and -vice-versa. +### minfs_minimum_inodes -NOTE: The memory security ranges should also be set (in TrustZone) to the opposite of normal, so -that non-protected mode accesses can only access protected memory and vice versa. Also, -growable memory faults won't work in this mode, so larger portions of growable memory should -precommitted (which is not done by default). +**Current value (from the default):** `""` + +From //build/images/fvm.gni:29 + +### skia_enable_fontmgr_android **Current value (from the default):** `false` -From //garnet/drivers/gpu/msd-arm-mali/src/BUILD.gn:23 +From //third_party/skia/BUILD.gn:69 -### skia_use_xps +### skia_enable_skpicture **Current value (from the default):** `true` -From //third_party/skia/BUILD.gn:38 +From //third_party/skia/BUILD.gn:47 -### use_mock_magma +### skia_use_libjpeg_turbo -**Current value (from the default):** `false` +**Current value (from the default):** `true` -From [//third_party/mesa/src/intel/vulkan/BUILD.gn:25](https://fuchsia.googlesource.com/third_party/mesa/+/1cfafcad803bc40d46133be708d5df1b4a604352/src/intel/vulkan/BUILD.gn#25) +From //third_party/skia/BUILD.gn:27 -### blobfs_minimum_data_bytes -Number of bytes to reserve for data in the fs. This is in addition -to what is reserved, if any, for the inodes. Data bytes constitutes -"usable" space of the fs. -An empty string does not reserve any additional space than minimum -required for the filesystem. +### skia_use_metal -**Current value (from the default):** `""` +**Current value (from the default):** `false` -From //build/images/fvm.gni:36 +From //third_party/skia/BUILD.gn:35 -### create_kernel_service_snapshot +### use_vbmeta +If true, then the paving script will pave vbmeta images to the target device. +It is assumed that the vbmeta image will be created by the custom_signing_script. **Current value (from the default):** `false` -From //third_party/dart/runtime/runtime_args.gni:101 +From //build/images/custom_signing.gni:16 -### dart_component_kind -Allow for deduping the VM between standalone, flutter_runner and dart_runner. +### clang_prefix +The default clang toolchain provided by the buildtools. This variable is +additionally consumed by the Go toolchain. -**Current value (from the default):** `"shared_library"` +**Current value (from the default):** `"../buildtools/linux-x64/clang/bin"` -From //third_party/dart/runtime/runtime_args.gni:78 +From //build/config/clang/clang.gni:11 -### minfs_minimum_inodes +### symbol_level +How many symbols to include in the build. This affects the performance of +the build since the symbols are large and dealing with them is slow. + 2 means regular build with symbols. + 1 means minimal symbols, usually enough for backtraces only. Symbols with +internal linkage (static functions or those in anonymous namespaces) may not +appear when using this level. + 0 means no symbols. + +**Current value (from the default):** `2` + +From //build/config/compiler.gni:13 + +### build_info_version +Logical version of the current build. If not set, defaults to the timestamp +of the most recent update. **Current value (from the default):** `""` -From //build/images/fvm.gni:29 +From //garnet/BUILD.gn:28 -### skia_enable_fontmgr_empty +### dart_snapshot_kind -**Current value (from the default):** `false` +**Current value (from the default):** `"kernel"` -From //third_party/skia/BUILD.gn:65 +From //third_party/dart/utils/application_snapshot.gni:14 -### skia_use_angle +### goma_dir +Absolute directory containing the Goma source code. -**Current value (from the default):** `false` +**Current value (from the default):** `"/home/swarming/goma"` -From //third_party/skia/BUILD.gn:20 +From //build/toolchain/goma.gni:12 -### use_thinlto -Use ThinLTO variant of LTO if use_lto = true. +### scenic_enable_vulkan_validation +Include the vulkan validation layers in scenic. **Current value (from the default):** `true` -From //build/config/lto/config.gni:10 +From //garnet/bin/ui/BUILD.gn:40 -### vk_loader_debug +### board_name +Board name used for paving and amber updates. -**Current value (from the default):** `"warn,error"` +**Current value (from the default):** `""` -From [//third_party/vulkan_loader_and_validation_layers/loader/BUILD.gn:26](https://fuchsia.googlesource.com/third_party/vulkan_loader_and_validation_layers/+/62e58ed31dc9711381fbe80817a89b51e9ff0686/loader/BUILD.gn#26) +From //build/package.gni:21 -### zedboot_cmdline_files -Files containing additional kernel command line arguments to bake into -the Zedboot image. The contents of these files (in order) come after any -arguments directly in [`zedboot_cmdline_args`](#zedboot_cmdline_args). -These can be GN `//` source pathnames or absolute system pathnames. +### expat_build_root -**Current value (from the default):** `[]` +**Current value (from the default):** `"//third_party/expat"` -From //build/images/zedboot/BUILD.gn:23 +From //garnet/lib/magma/gnbuild/magma.gni:9 -### skia_enable_skshaper +### skia_enable_fontmgr_win_gdi -**Current value (from the default):** `true` +**Current value (from the default):** `false` -From //third_party/skia/modules/skshaper/BUILD.gn:9 +From //third_party/skia/BUILD.gn:72 -### skia_use_x11 +### blobfs_minimum_inodes +minimum_inodes is the number of inodes to reserve for the fs +An empty string does not reserve any additional space than minimum +required for the filesystem. -**Current value for `target_cpu = "arm64"`:** `false` +**Current value (from the default):** `""` -From //.gn:31 +From //build/images/fvm.gni:28 -**Overridden from the default:** `true` +### msd_intel_gen_build_root -From //third_party/skia/BUILD.gn:37 +**Current value (from the default):** `"//garnet/drivers/gpu/msd-intel-gen"` -**Current value for `target_cpu = "x64"`:** `false` +From //garnet/lib/magma/gnbuild/magma.gni:10 -From //.gn:31 +### skia_enable_fontmgr_custom -**Overridden from the default:** `false` +**Current value (from the default):** `true` -From //third_party/skia/BUILD.gn:37 +From //third_party/skia/BUILD.gn:67 -### wlancfg_config_type -Selects the wlan configuration type to use. Choices: - "client" - client mode - "ap" - access point mode - "" (empty string) - no configuration +### target_sysroot +The absolute path of the sysroot that is used with the target toolchain. -**Current value (from the default):** `"client"` +**Current value (from the default):** `""` -From //src/connectivity/wlan/wlancfg/BUILD.gn:15 +From //build/config/sysroot.gni:7 -### zedboot_cmdline_args -List of kernel command line arguments to bake into the Zedboot image. -See //zircon/docs/kernel_cmdline.md and -[`zedboot_devmgr_config`](#zedboot_devmgr_config). +### thinlto_jobs +Number of parallel ThinLTO jobs. -**Current value (from the default):** `[]` +**Current value (from the default):** `8` -From //build/images/zedboot/BUILD.gn:17 +From //build/config/lto/config.gni:13 -### glm_build_root +### toolchain_manifests +Manifest files describing target libraries from toolchains. +Can be either // source paths or absolute system paths. -**Current value (from the default):** `"//third_party/glm"` +**Current value (from the default):** `["/b/s/w/ir/k/buildtools/linux-x64/clang/lib/aarch64-fuchsia.manifest"]` -From //garnet/lib/magma/gnbuild/magma.gni:11 +From //build/images/manifest.gni:11 -### host_byteorder +### dart_lib_export_symbols +Whether libdart should export the symbols of the Dart API. -**Current value (from the default):** `"undefined"` +**Current value (from the default):** `true` -From //build/config/host_byteorder.gni:7 +From //third_party/dart/runtime/runtime_args.gni:91 -### use_account_manager -Whether basemgr and dev_base_shell should use account_manager for account -creation. This is a temporary flag while modular transitions to use account -manager. +### dart_use_fallback_root_certificates +Whether to fall back to built-in root certificates when they cannot be +verified at the operating system level. -**Current value (from the default):** `true` +**Current value (from the default):** `false` -From //peridot/bin/basemgr/BUILD.gn:18 +From //third_party/dart/runtime/runtime_args.gni:43 -### concurrent_go_jobs -Maximum number of Go processes to run in parallel. +### extra_authorized_keys_file +Additional SSH authorized_keys file to include in the build. +For example: + extra_authorized_keys_file=\"$HOME/.ssh/id_rsa.pub\" -**Current value (from the default):** `16` +**Current value (from the default):** `""` -From //build/go/BUILD.gn:11 +From [//third_party/openssh-portable/fuchsia/developer-keys/BUILD.gn:11](https://fuchsia.googlesource.com/third_party/openssh-portable/+/f62e9e1879377736a8505bef9499df060613173d/fuchsia/developer-keys/BUILD.gn#11) -### debian_guest_qcow -Package the rootfs as a QCOW image (as opposed to a flat file). +### skia_use_lua -**Current value (from the default):** `true` +**Current value (from the default):** `false` -From //garnet/bin/guest/pkg/debian_guest/BUILD.gn:9 +From //third_party/skia/BUILD.gn:30 -### skia_enable_discrete_gpu +### current_cpu -**Current value (from the default):** `true` +**Current value (from the default):** `""` -From //third_party/skia/BUILD.gn:43 +### zircon_extra_args +[Zircon GN build arguments](../../../zircon/docs/gen/build_arguments.md). +This is included in the default value of [`zircon_args`](#zircon_args) so +you can set this to add things there without wiping out the defaults. +When you set `zircon_args` directly, then this has no effect at all. +Arguments you set here override any arguments in the default +`zircon_args`. There is no way to append to a value from the defaults. +Note that for just setting simple (string-only) values in Zircon GN's +[`variants`](../../../zircon/docs/gen/build_arguments.md#variants), the +default [`zircon_args`](#zircon_args) uses a `variants` value derived from +[`select_variant`](#select_variant) so for simple cases there is no need +to explicitly set Zircon's `variants` here. -### skia_enable_gpu +**Current value (from the default):** `{ }` -**Current value (from the default):** `true` +From //build/config/fuchsia/zircon.gni:27 -From //third_party/skia/gn/skia.gni:11 +### skia_enable_tools -### blobfs_minimum_inodes -minimum_inodes is the number of inodes to reserve for the fs -An empty string does not reserve any additional space than minimum -required for the filesystem. +**Current value (from the default):** `false` -**Current value (from the default):** `""` +From //third_party/skia/gn/skia.gni:12 -From //build/images/fvm.gni:28 +### use_thinlto +Use ThinLTO variant of LTO if use_lto = true. -### dart_version +**Current value (from the default):** `true` -**Current value (from the default):** `""` +From //build/config/lto/config.gni:10 -From //third_party/flutter/shell/version/version.gni:10 +### skia_use_fonthost_mac -### active_partition +**Current value (from the default):** `false` -**Current value (from the default):** `""` +From //third_party/skia/BUILD.gn:24 -From //build/images/BUILD.gn:45 +### skia_use_xps -### fvm_image_size -The size in bytes of the FVM partition image to create. Normally this is -computed to be just large enough to fit the blob and data images. The -default value is "", which means to size based on inputs. Specifying a size -that is too small will result in build failure. +**Current value (from the default):** `true` -**Current value (from the default):** `""` +From //third_party/skia/BUILD.gn:38 -From //build/images/fvm.gni:12 +### enable_input_subsystem -### go_vet_enabled - go_vet_enabled - [bool] if false, go vet invocations are disabled for all builds. +**Current value (from the default):** `true` -**Current value (from the default):** `false` +From //garnet/bin/ui/scenic/BUILD.gn:14 -From //build/go/go_build.gni:20 +### linux_guest_extras_path -### msd_intel_gen_build_root +**Current value (from the default):** `""` -**Current value (from the default):** `"//garnet/drivers/gpu/msd-intel-gen"` +From //garnet/bin/guest/pkg/linux_guest/BUILD.gn:13 -From //garnet/lib/magma/gnbuild/magma.gni:10 +### rust_warnings +Sets whether Rust compiler warnings cause errors or not. +"deny" will make all warnings into errors, while "allow" will ignore warnings -### devmgr_config -List of arguments to add to /boot/config/devmgr. -These come after synthesized arguments to configure blobfs and pkgfs. +**Current value (from the default):** `"deny"` -**Current value (from the default):** `[]` +From //build/rust/config.gni:27 -From //build/images/BUILD.gn:465 +### always_zedboot +Build boot images that prefer Zedboot over local boot (only for EFI). -### enable_netboot -Whether to build the netboot zbi by default. +**Current value (from the default):** `false` -You can still build //build/images:netboot explicitly even if enable_netboot is false. +From //build/images/BUILD.gn:796 -**Current value for `target_cpu = "arm64"`:** `false` +### skia_android_serial -From //products/core.gni:7 +**Current value (from the default):** `""` -**Overridden from the default:** `false` +From //third_party/skia/BUILD.gn:40 -From //build/images/BUILD.gn:33 +### skia_llvm_path -**Current value for `target_cpu = "x64"`:** `false` +**Current value (from the default):** `""` -From //products/core.gni:7 +From //third_party/skia/BUILD.gn:56 -**Overridden from the default:** `false` +### use_goma +Set to true to enable distributed compilation using Goma. -From //build/images/BUILD.gn:33 +**Current value (from the default):** `false` -### framework_packages +From //build/toolchain/goma.gni:9 -**Current value (from the default):** `["collection", "flutter", "meta", "typed_data", "vector_math"]` +### flutter_runtime_mode +The runtime mode ("debug", "profile", "release", "dynamic_profile", or "dynamic_release") -From [//topaz/runtime/flutter_runner/prebuilt_framework.gni:8](https://fuchsia.googlesource.com/topaz/+/ff9f85507acd416f76801f1a561574b28c48446d/runtime/flutter_runner/prebuilt_framework.gni#8) +**Current value (from the default):** `"debug"` -### skia_enable_nima +From //third_party/flutter/common/config.gni:15 -**Current value (from the default):** `false` +### crashpad_use_boringssl_for_http_transport_socket +TODO(scottmg): https://crbug.com/crashpad/266 fuchsia:DX-690: BoringSSL +was removed from the Fuchsia SDK. Re-enable it when we have a way to acquire +a BoringSSL lib again. -From //third_party/skia/BUILD.gn:44 +**Current value (from the default):** `true` -### vbmeta_b_partition +From [//third_party/crashpad/util/net/tls.gni:21](https://chromium.googlesource.com/crashpad/crashpad/+/5081a90207ec5e39aefeeab4ccc3e4690ee5c1e5/util/net/tls.gni#21) -**Current value (from the default):** `""` +### create_kernel_service_snapshot -From //build/images/BUILD.gn:43 +**Current value (from the default):** `false` -### concurrent_link_jobs -Maximum number of concurrent link jobs. +From //third_party/dart/runtime/runtime_args.gni:101 -We often want to run fewer links at once than we do compiles, because -linking is memory-intensive. The default to use varies by platform and by -the amount of memory available, so we call out to a script to get the right -value. +### magma_enable_developer_build +Enable this to have the msd include a suite of tests and invoke them +automatically when the driver starts. -**Current value (from the default):** `16` +**Current value (from the default):** `false` -From //build/toolchain/BUILD.gn:15 +From //garnet/lib/magma/gnbuild/magma.gni:21 -### skia_enable_fontmgr_android +### skia_enable_fontmgr_win **Current value (from the default):** `false` -From //third_party/skia/BUILD.gn:69 +From //third_party/skia/BUILD.gn:71 -### skia_enable_fontmgr_custom_empty +### skia_tools_require_resources **Current value (from the default):** `false` -From //third_party/skia/BUILD.gn:68 +From //third_party/skia/BUILD.gn:59 -### dart_force_product -Forces all Dart and Flutter apps to build in a specific configuration that -we use to build products. +### board_packages -**Current value (from the default):** `false` +**Current value for `target_cpu = "arm64"`:** `[]` -From [//topaz/runtime/dart/config.gni:10](https://fuchsia.googlesource.com/topaz/+/ff9f85507acd416f76801f1a561574b28c48446d/runtime/dart/config.gni#10) +From //boards/arm64.gni:7 -### skia_use_libpng +**Overridden from the default:** `[]` -**Current value (from the default):** `true` +From //BUILD.gn:40 -From //third_party/skia/BUILD.gn:28 +**Current value for `target_cpu = "x64"`:** `[]` -### dart_use_fallback_root_certificates -Whether to fall back to built-in root certificates when they cannot be -verified at the operating system level. +From //boards/x64.gni:9 -**Current value (from the default):** `false` +**Overridden from the default:** `[]` -From //third_party/dart/runtime/runtime_args.gni:43 +From //BUILD.gn:40 -### skia_android_serial +### enable_dart_analysis +Enable all dart analysis -**Current value (from the default):** `""` +**Current value (from the default):** `true` -From //third_party/skia/BUILD.gn:40 +From //build/dart/dart_library.gni:15 -### skia_enable_spirv_validation +### cache_package_labels +If you add package labels to this variable, the packages will be included +in the 'cache' package set, which represents an additional set of software +that is made available on disk immediately after paving and in factory +flows. These packages are not updated with an OTA, but instead are updated +ephemerally. This cache of software can be evicted by the system if storage +pressure arises or other policies indicate. -**Current value (from the default):** `false` +**Current value for `target_cpu = "arm64"`:** `[]` -From //third_party/skia/BUILD.gn:46 +From //products/core.gni:24 -### skia_use_expat +**Overridden from the default:** `[]` -**Current value for `target_cpu = "arm64"`:** `false` +From //BUILD.gn:22 -From //.gn:27 +**Current value for `target_cpu = "x64"`:** `[]` -**Overridden from the default:** `true` +From //products/core.gni:24 -From //third_party/skia/BUILD.gn:22 +**Overridden from the default:** `[]` -**Current value for `target_cpu = "x64"`:** `false` +From //BUILD.gn:22 -From //.gn:27 +### magma_enable_tracing +Enable this to include fuchsia tracing capability -**Overridden from the default:** `true` +**Current value (from the default):** `true` -From //third_party/skia/BUILD.gn:22 +From //garnet/lib/magma/gnbuild/magma.gni:17 -### skia_use_fonthost_mac +### magma_python_path -**Current value (from the default):** `false` +**Current value (from the default):** `"/b/s/w/ir/k/third_party/mako"` -From //third_party/skia/BUILD.gn:24 +From //garnet/lib/magma/gnbuild/magma.gni:14 -### skia_use_piex +### msd_arm_enable_cache_coherency +With this flag set the system tries to use cache coherent memory if the +GPU supports it. **Current value (from the default):** `true` -From //third_party/skia/BUILD.gn:32 +From //garnet/drivers/gpu/msd-arm-mali/src/BUILD.gn:13 -### custom_signing_script -If non-empty, the given script will be invoked to produce a signed ZBI -image. The given script must accept -z for the input zbi path, and -o for -the output signed zbi path. The path must be in GN-label syntax (i.e. -starts with //). +### persist_logs -**Current value (from the default):** `""` +**Current value (from the default):** `true` -From //build/images/custom_signing.gni:12 +From //build/persist_logs.gni:13 -### experimental_wlan_client_mlme -Selects the SoftMAC client implementation to use. Choices: - false (default) - C++ Client MLME implementation - true - Rust Client MLME implementation -This argument is temporary until Rust MLME is ready to be used. +### select_variant_shortcuts +List of short names for commonly-used variant selectors. Normally this +is not set as a build argument, but it serves to document the available +set of short-cut names for variant selectors. Each element of this list +is a scope where `.name` is the short name and `.select_variant` is a +a list that can be spliced into [`select_variant`](#select_variant). -**Current value (from the default):** `false` +**Current value (from the default):** +``` +[{ + name = "host_asan" + select_variant = [{ + dir = ["//third_party/yasm", "//third_party/vboot_reference", "//garnet/tools/vboot_reference"] + host = true + variant = "asan_no_detect_leaks" +}, { + host = true + variant = "asan" +}] +}, { + name = "asan" + select_variant = [{ + target_type = ["driver_module"] + variant = false +}, { + host = false + variant = "asan" +}] +}] +``` -From //src/connectivity/wlan/lib/mlme/cpp/BUILD.gn:10 +From //build/config/BUILDCONFIG.gn:448 -### linux_guest_extras_path +### skia_enable_skottie + +**Current value (from the default):** `true` + +From //third_party/skia/modules/skottie/BUILD.gn:9 + +### skia_use_piex + +**Current value (from the default):** `true` + +From //third_party/skia/BUILD.gn:32 + +### extra_variants +Additional variant toolchain configs to support. +This is just added to [`known_variants`](#known_variants). + +**Current value (from the default):** `[]` + +From //build/config/BUILDCONFIG.gn:402 + +### scudo_default_options +Default [Scudo](https://llvm.org/docs/ScudoHardenedAllocator.html) +options (before the `SCUDO_OPTIONS` environment variable is read at +runtime). *NOTE:* This affects only components using the `scudo` +variant (see GN build argument `select_variant`), and does not affect +anything when the `use_scudo` build flag is set instead. + +**Current value (from the default):** `["abort_on_error=1", "QuarantineSizeKb=0", "ThreadLocalQuarantineSizeKb=0", "DeallocationTypeMismatch=false", "DeleteSizeMismatch=false", "allocator_may_return_null=true"]` + +From //build/config/scudo/scudo.gni:17 + +### skia_gl_standard **Current value (from the default):** `""` -From //garnet/bin/guest/pkg/linux_guest/BUILD.gn:13 +From //third_party/skia/BUILD.gn:79 -### skia_qt_path +### zircon_b_partition **Current value (from the default):** `""` -From //third_party/skia/BUILD.gn:49 +From //build/images/BUILD.gn:40 -### skia_use_dng_sdk +### have_secmem_ta +The secmem TA must be obtained elsewhere and put into the firmware +directory. -**Current value for `target_cpu = "arm64"`:** `false` +**Current value (from the default):** `false` -From //.gn:26 +From //garnet/bin/sysmem-assistant/BUILD.gn:44 -**Overridden from the default:** `true` +### rustc_prefix +Sets a custom base directory for `rustc` and `cargo`. +This can be used to test custom Rust toolchains. -From //third_party/skia/BUILD.gn:62 +**Current value (from the default):** `"//buildtools/linux-x64/rust/bin"` -**Current value for `target_cpu = "x64"`:** `false` +From //build/rust/config.gni:17 -From //.gn:26 +### skia_generate_workarounds -**Overridden from the default:** `false` +**Current value (from the default):** `false` -From //third_party/skia/BUILD.gn:62 +From //third_party/skia/BUILD.gn:51 -### zircon_enable_kernel_debugging_features -Whether to include various features (non-shipping, insecure, etc.) in the -kernel build. +### skia_use_libwebp **Current value for `target_cpu = "arm64"`:** `false` -From //products/core.gni:9 +From //.gn:29 -**Overridden from the default:** `false` +**Overridden from the default:** `true` -From //build/config/fuchsia/zircon.gni:32 +From //third_party/skia/BUILD.gn:29 **Current value for `target_cpu = "x64"`:** `false` -From //products/core.gni:9 +From //.gn:29 **Overridden from the default:** `false` -From //build/config/fuchsia/zircon.gni:32 +From //third_party/skia/BUILD.gn:29 -### dart_custom_version_for_pub -When this argument is a non-empty string, the version repoted by the -Dart VM will be one that is compatible with pub's interpretation of -semantic version strings. The version string will also include the values -of the argument. In particular the version string will read: +### warn_on_sdk_changes +Whether to only warn when an SDK has been modified. +If false, any unacknowledged SDK change will cause a build failure. - "M.m.p-dev.x.x-$(dart_custom_version_for_pub)-$(short_git_hash)" +**Current value (from the default):** `false` -Where 'M', 'm', and 'p' are the major, minor and patch version numbers, -and 'dev.x.x' is the dev version tag most recently preceeding the current -revision. The short git hash can be omitted by setting -dart_version_git_info=false +From //build/sdk/config.gni:8 -**Current value (from the default):** `""` +### framework_packages -From //third_party/dart/runtime/runtime_args.gni:73 +**Current value (from the default):** `["collection", "flutter", "meta", "typed_data", "vector_math"]` -### dart_lib_export_symbols -Whether libdart should export the symbols of the Dart API. +From [//topaz/runtime/flutter_runner/prebuilt_framework.gni:8](https://fuchsia.googlesource.com/topaz/+/ff9f85507acd416f76801f1a561574b28c48446d/runtime/flutter_runner/prebuilt_framework.gni#8) -**Current value (from the default):** `true` +### devmgr_config +List of arguments to add to /boot/config/devmgr. +These come after synthesized arguments to configure blobfs and pkgfs. -From //third_party/dart/runtime/runtime_args.gni:91 +**Current value (from the default):** `[]` -### escher_use_null_vulkan_config_on_host -Using Vulkan on host (i.e. Linux) is an involved affair that involves -downloading the Vulkan SDK, setting environment variables, and so forth... -all things that are difficult to achieve in a CQ environment. Therefore, -by default we use a stub implementation of Vulkan which fails to create a -VkInstance. This allows everything to build, and also allows running Escher -unit tests which don't require Vulkan. +From //build/images/BUILD.gn:465 -**Current value (from the default):** `true` +### host_byteorder -From //garnet/public/lib/escher/BUILD.gn:16 +**Current value (from the default):** `"undefined"` -### linux_runner_netmask +From //build/config/host_byteorder.gni:7 -**Current value (from the default):** `"255.255.255.0"` +### signed_image -From //garnet/bin/guest/pkg/biscotti_guest/linux_runner/BUILD.gn:19 +**Current value (from the default):** `false` -### skia_pdf_subset_harfbuzz -TODO: set skia_pdf_subset_harfbuzz to skia_use_harfbuzz. +From //build/images/BUILD.gn:46 + +### debian_guest_earlycon **Current value (from the default):** `false` -From //third_party/skia/gn/skia.gni:18 +From //garnet/bin/guest/pkg/debian_guest/BUILD.gn:10 -### target_os +### fuchsia_vulkan_sdk +Path to Fuchsia Vulkan SDK -**Current value (from the default):** `""` +**Current value (from the default):** `"//third_party/vulkan_loader_and_validation_layers"` -### skia_enable_pdf +From //build/vulkan/config.gni:10 -**Current value for `target_cpu = "arm64"`:** `false` +### msd_arm_enable_protected_debug_swap_mode +In protected mode, faults don't return as much information so they're much harder to debug. To +work around that, add a mode where protected atoms are executed in non-protected mode and +vice-versa. -From //.gn:25 +NOTE: The memory security ranges should also be set (in TrustZone) to the opposite of normal, so +that non-protected mode accesses can only access protected memory and vice versa. Also, +growable memory faults won't work in this mode, so larger portions of growable memory should +precommitted (which is not done by default). -**Overridden from the default:** `true` +**Current value (from the default):** `false` -From //third_party/skia/BUILD.gn:45 +From //garnet/drivers/gpu/msd-arm-mali/src/BUILD.gn:23 -**Current value for `target_cpu = "x64"`:** `false` +### skia_use_x11 -From //.gn:25 +**Current value for `target_cpu = "arm64"`:** `false` + +From //.gn:31 **Overridden from the default:** `true` -From //third_party/skia/BUILD.gn:45 +From //third_party/skia/BUILD.gn:37 -### skia_enable_particles +**Current value for `target_cpu = "x64"`:** `false` -**Current value (from the default):** `true` +From //.gn:31 -From //third_party/skia/modules/particles/BUILD.gn:7 +**Overridden from the default:** `false` -### dart_use_crashpad -Whether to link Crashpad library for crash handling. Only supported on -Windows for now. +From //third_party/skia/BUILD.gn:37 -**Current value (from the default):** `false` +### thinlto_cache_dir +ThinLTO cache directory path. -From //third_party/dart/runtime/runtime_args.gni:51 +**Current value (from the default):** `"dartlang/thinlto-cache"` -### skia_use_opencl +From //build/config/lto/config.gni:16 + +### exclude_kernel_service +Whether the VM includes the kernel service in all modes (debug, release, +product). **Current value (from the default):** `false` -From //third_party/skia/BUILD.gn:31 +From //third_party/dart/runtime/runtime_args.gni:88 -### zircon_a_partition -arguments to fx flash script +### skia_use_dng_sdk -**Current value (from the default):** `""` +**Current value for `target_cpu = "arm64"`:** `false` -From //build/images/BUILD.gn:39 +From //.gn:26 -### enable_gfx_subsystem +**Overridden from the default:** `true` -**Current value (from the default):** `true` +From //third_party/skia/BUILD.gn:62 -From //garnet/bin/ui/scenic/BUILD.gn:12 +**Current value for `target_cpu = "x64"`:** `false` -### fvm_slice_size -The size of the FVM partition images "slice size". The FVM slice size is a -minimum size of a particular chunk of a partition that is stored within -FVM. A very small slice size may lead to decreased throughput. A very large -slice size may lead to wasted space. The selected default size of 8mb is -selected for conservation of space, rather than performance. +From //.gn:26 -**Current value (from the default):** `"8388608"` +**Overridden from the default:** `false` -From //build/images/fvm.gni:19 +From //third_party/skia/BUILD.gn:62 -### gocache_dir - gocache_dir - Directory GOCACHE environment variable will be set to. This directory - will have build and test results cached, and is safe to be written to - concurrently. If overridden, this directory must be a full path. +### flutter_default_app -**Current value (from the default):** `"/b/s/w/ir/k/root_build_dir/host_x64/.gocache"` +**Current value (from the default):** `"flutter_jit_app"` -From //build/go/go_build.gni:16 +From [//topaz/runtime/dart/dart_component.gni:12](https://fuchsia.googlesource.com/topaz/+/ff9f85507acd416f76801f1a561574b28c48446d/runtime/dart/dart_component.gni#12) -### scenic_use_new_renderer -Specifies whether Scenic uses the new "PaperRenderer2" when -rendering Scenes with fuchsia.ui.gfx.ShadowTechnique.UNSHADOWED. - -**Current value (from the default):** `true` - -From //garnet/lib/ui/gfx/BUILD.gn:12 - -### skia_use_zlib +### use_vulkan_loader_for_tests +Mesa doesn't properly handle loader-less operation; +their GetInstanceProcAddr implementation returns 0 for some interfaces. +On ARM there may be multiple libvulkan_arms, so they can't all be linked +to. **Current value (from the default):** `true` -From //third_party/skia/BUILD.gn:34 +From //garnet/lib/magma/gnbuild/magma.gni:31 -### use_vbmeta -If true, then the paving script will pave vbmeta images to the target device. -It is assumed that the vbmeta image will be created by the custom_signing_script. +### vk_loader_debug -**Current value (from the default):** `false` +**Current value (from the default):** `"warn,error"` -From //build/images/custom_signing.gni:16 +From [//third_party/vulkan_loader_and_validation_layers/loader/BUILD.gn:26](https://fuchsia.googlesource.com/third_party/vulkan_loader_and_validation_layers/+/62e58ed31dc9711381fbe80817a89b51e9ff0686/loader/BUILD.gn#26) -### magma_enable_tracing -Enable this to include fuchsia tracing capability +### skia_use_freetype **Current value (from the default):** `true` -From //garnet/lib/magma/gnbuild/magma.gni:17 +From //third_party/skia/BUILD.gn:25 -### thinlto_jobs -Number of parallel ThinLTO jobs. +### prebuilt_libvulkan_arm_path -**Current value (from the default):** `8` +**Current value (from the default):** `""` -From //build/config/lto/config.gni:13 +From //garnet/lib/magma/gnbuild/magma.gni:23 -### auto_update_packages -Whether the component loader should automatically update packages. +### skia_version -**Current value (from the default):** `true` +**Current value (from the default):** `""` -From //garnet/bin/sysmgr/BUILD.gn:10 +From //third_party/flutter/shell/version/version.gni:8 -### extra_authorized_keys_file -Additional SSH authorized_keys file to include in the build. -For example: - extra_authorized_keys_file=\"$HOME/.ssh/id_rsa.pub\" +### zircon_enable_kernel_debugging_features +Whether to include various features (non-shipping, insecure, etc.) in the +kernel build. -**Current value (from the default):** `""` +**Current value for `target_cpu = "arm64"`:** `false` -From [//third_party/openssh-portable/fuchsia/developer-keys/BUILD.gn:11](https://fuchsia.googlesource.com/third_party/openssh-portable/+/f62e9e1879377736a8505bef9499df060613173d/fuchsia/developer-keys/BUILD.gn#11) +From //products/core.gni:9 -### magma_build_root +**Overridden from the default:** `false` -**Current value (from the default):** `"//garnet/lib/magma"` +From //build/config/fuchsia/zircon.gni:32 -From //garnet/lib/magma/gnbuild/magma.gni:8 +**Current value for `target_cpu = "x64"`:** `false` -### skia_llvm_path +From //products/core.gni:9 -**Current value (from the default):** `""` +**Overridden from the default:** `false` -From //third_party/skia/BUILD.gn:56 +From //build/config/fuchsia/zircon.gni:32 -### dart_aot_sharing_basis -module_suggester is not AOT compiled in debug builds +### msd_arm_enable_all_cores +Enable all 8 cores, which is faster but emits more heat. -**Current value (from the default):** `""` +**Current value (from the default):** `true` -From [//topaz/runtime/dart/dart_component.gni:51](https://fuchsia.googlesource.com/topaz/+/ff9f85507acd416f76801f1a561574b28c48446d/runtime/dart/dart_component.gni#51) +From //garnet/drivers/gpu/msd-arm-mali/src/BUILD.gn:9 -### full_dart_sdk +### skia_enable_nvpr **Current value (from the default):** `false` -From //third_party/flutter/BUILD.gn:10 +From //third_party/skia/BUILD.gn:42 -### scenic_enable_vulkan_validation -Include the vulkan validation layers in scenic. +### skia_enable_particles **Current value (from the default):** `true` -From //garnet/bin/ui/BUILD.gn:40 - -### dart_use_tcmalloc -Whether to link the standalone VM against tcmalloc. The standalone build of -the VM enables this only for Linux builds. - -**Current value (from the default):** `false` +From //third_party/skia/modules/particles/BUILD.gn:7 -From //third_party/dart/runtime/runtime_args.gni:47 +### target_cpu -### skia_enable_vulkan_debug_layers +**Current value for `target_cpu = "arm64"`:** `"arm64"` -**Current value (from the default):** `false` +From //boards/arm64.gni:5 -From //third_party/skia/BUILD.gn:48 +**Overridden from the default:** `""` -### skia_use_libheif +**Current value for `target_cpu = "x64"`:** `"x64"` -**Current value (from the default):** `false` +From //boards/x64.gni:5 -From //third_party/skia/BUILD.gn:36 +**Overridden from the default:** `""` -### update_kernels -List of kernel images to include in the update (OTA) package. -If no list is provided, all built kernels are included. The names in the -list are strings that must match the filename to be included in the update -package. +### universal_variants -**Current value (from the default):** `[]` +**Current value (from the default):** +``` +[{ + configs = [] + name = "release" + toolchain_args = { + is_debug = false +} +}] +``` -From //build/images/BUILD.gn:488 +From //build/config/BUILDCONFIG.gn:422 -### cache_package_labels -If you add package labels to this variable, the packages will be included -in the 'cache' package set, which represents an additional set of software -that is made available on disk immediately after paving and in factory -flows. These packages are not updated with an OTA, but instead are updated -ephemerally. This cache of software can be evicted by the system if storage -pressure arises or other policies indicate. +### use_mock_magma -**Current value for `target_cpu = "arm64"`:** `[]` +**Current value (from the default):** `false` -From //products/core.gni:24 +From [//third_party/mesa/src/intel/vulkan/BUILD.gn:25](https://fuchsia.googlesource.com/third_party/mesa/+/1cfafcad803bc40d46133be708d5df1b4a604352/src/intel/vulkan/BUILD.gn#25) -**Overridden from the default:** `[]` +### use_scudo +TODO(davemoore): Remove this entire mechanism once standalone scudo is the +default (DNO-442) +Enable the [Scudo](https://llvm.org/docs/ScudoHardenedAllocator.html) +memory allocator. -From //BUILD.gn:22 +**Current value (from the default):** `false` -**Current value for `target_cpu = "x64"`:** `[]` +From //build/config/scudo/scudo.gni:10 -From //products/core.gni:24 +### glm_build_root -**Overridden from the default:** `[]` +**Current value (from the default):** `"//third_party/glm"` -From //BUILD.gn:22 +From //garnet/lib/magma/gnbuild/magma.gni:11 -### crashpad_use_boringssl_for_http_transport_socket -TODO(scottmg): https://crbug.com/crashpad/266 fuchsia:DX-690: BoringSSL -was removed from the Fuchsia SDK. Re-enable it when we have a way to acquire -a BoringSSL lib again. +### skia_enable_skshaper **Current value (from the default):** `true` -From [//third_party/crashpad/util/net/tls.gni:21](https://chromium.googlesource.com/crashpad/crashpad/+/5081a90207ec5e39aefeeab4ccc3e4690ee5c1e5/util/net/tls.gni#21) - -### log_startup_sleep +From //third_party/skia/modules/skshaper/BUILD.gn:9 -**Current value (from the default):** `"30000"` +### dart_component_kind +Allow for deduping the VM between standalone, flutter_runner and dart_runner. -From //garnet/bin/log_listener/BUILD.gn:14 +**Current value (from the default):** `"shared_library"` -### max_log_disk_usage -Controls how many bytes of space on disk are used to persist device logs. -Should be a string value that only contains digits. +From //third_party/dart/runtime/runtime_args.gni:78 -**Current value (from the default):** `"0"` +### icu_use_data_file +Tells icu to load an external data file rather than rely on the icudata +being linked directly into the binary. -From //garnet/bin/log_listener/BUILD.gn:13 +This flag is a bit confusing. As of this writing, icu.gyp set the value to +0 but common.gypi sets the value to 1 for most platforms (and the 1 takes +precedence). -### zircon_asserts +TODO(GYP) We'll probably need to enhance this logic to set the value to +true or false in similar circumstances. **Current value (from the default):** `true` -From //build/config/fuchsia/BUILD.gn:201 +From [//third_party/icu/config.gni:15](https://fuchsia.googlesource.com/third_party/icu/+/65e4aa3b8cc6b41cf31136b9474a9c97bdc27739/config.gni#15) -### host_cpu +### rust_lto +Sets the default LTO type for rustc bulids. -**Current value (from the default):** `"x64"` +**Current value (from the default):** `"unset"` -### persist_logs +From //build/rust/config.gni:20 -**Current value (from the default):** `true` +### skia_use_wuffs -From //build/persist_logs.gni:13 +**Current value (from the default):** `false` -### select_variant -List of "selectors" to request variant builds of certain targets. -Each selector specifies matching criteria and a chosen variant. -The first selector in the list to match a given target determines -which variant is used for that target. +From //third_party/skia/BUILD.gn:33 -Each selector is either a string or a scope. A shortcut selector is -a string; it gets expanded to a full selector. A full selector is a -scope, described below. +### host_os -A string selector can match a name in -[`select_variant_shortcuts`](#select_variant_shortcuts). If it's not a -specific shortcut listed there, then it can be the name of any variant -described in [`known_variants`](#known_variants) and -[`universal_variants`](#universal_variants) (and combinations thereof). -A `selector` that's a simple variant name selects for every binary -built in the target toolchain: `{ host=false variant=selector }`. +**Current value (from the default):** `"linux"` -If a string selector contains a slash, then it's `"shortcut/filename"` -and selects only the binary in the target toolchain whose `output_name` -matches `"filename"`, i.e. it adds `output_name=["filename"]` to each -selector scope that the shortcut's name alone would yield. +### enable_netboot +Whether to build the netboot zbi by default. -The scope that forms a full selector defines some of these: +You can still build //build/images:netboot explicitly even if enable_netboot is false. - variant (required) - [string or `false`] The variant that applies if this selector - matches. This can be `false` to choose no variant, or a string - that names the variant. See - [`known_variants`](#known_variants) and - [`universal_variants`](#universal_variants). +**Current value for `target_cpu = "arm64"`:** `false` -The rest below are matching criteria. All are optional. -The selector matches if and only if all of its criteria match. -If none of these is defined, then the selector always matches. +From //products/core.gni:7 -The first selector in the list to match wins and then the rest of -the list is ignored. So construct more complex rules by using a -"blacklist" selector with `variant=false` before a catch-all or -"whitelist" selector that names a variant. +**Overridden from the default:** `false` -Each "[strings]" criterion is a list of strings, and the criterion -is satisfied if any of the strings matches against the candidate string. +From //build/images/BUILD.gn:33 - host - [boolean] If true, the selector matches in the host toolchain. - If false, the selector matches in the target toolchain. +**Current value for `target_cpu = "x64"`:** `false` - testonly - [boolean] If true, the selector matches targets with testonly=true. - If false, the selector matches in targets without testonly=true. +From //products/core.gni:7 - target_type - [strings]: `"executable"`, `"loadable_module"`, or `"driver_module"` +**Overridden from the default:** `false` - output_name - [strings]: target's `output_name` (default: its `target name`) +From //build/images/BUILD.gn:33 - label - [strings]: target's full label with `:` (without toolchain suffix) +### magma_build_root - name - [strings]: target's simple name (label after last `/` or `:`) +**Current value (from the default):** `"//garnet/lib/magma"` - dir - [strings]: target's label directory (`//dir` for `//dir:name`). - -**Current value (from the default):** `[]` - -From //build/config/BUILDCONFIG.gn:622 - -### skia_enable_nvpr +From //garnet/lib/magma/gnbuild/magma.gni:8 -**Current value (from the default):** `false` +### meta_package_labels +A list of labels for meta packages to be included in the monolith. -From //third_party/skia/BUILD.gn:42 +**Current value for `target_cpu = "arm64"`:** `["//build/images:config-data", "//build/images:shell-commands", "//garnet/bin/component_index:component_index"]` -### skia_enable_tools +From //products/core.gni:11 -**Current value (from the default):** `false` +**Overridden from the default:** `[]` -From //third_party/skia/gn/skia.gni:12 +From //build/images/BUILD.gn:36 -### enable_frame_pointers -Controls whether the compiler emits full stack frames for function calls. -This reduces performance but increases the ability to generate good -stack traces, especially when we have bugs around unwind table generation. -It applies only for Fuchsia targets (see below where it is unset). +**Current value for `target_cpu = "x64"`:** `["//build/images:config-data", "//build/images:shell-commands", "//garnet/bin/component_index:component_index"]` -TODO(ZX-2361): Theoretically unwind tables should be good enough so we can -remove this option when the issues are addressed. +From //products/core.gni:11 -**Current value (from the default):** `true` +**Overridden from the default:** `[]` -From //build/config/BUILD.gn:19 +From //build/images/BUILD.gn:36 -### exclude_kernel_service -Whether the VM includes the kernel service in all modes (debug, release, -product). +### use_lto +Use link time optimization (LTO). **Current value (from the default):** `false` -From //third_party/dart/runtime/runtime_args.gni:88 - -### use_vulkan_loader_for_tests -Mesa doesn't properly handle loader-less operation; -their GetInstanceProcAddr implementation returns 0 for some interfaces. -On ARM there may be multiple libvulkan_arms, so they can't all be linked -to. +From //build/config/lto/config.gni:7 -**Current value (from the default):** `true` +### cloudkms_key_dir -From //garnet/lib/magma/gnbuild/magma.gni:31 +**Current value (from the default):** `"projects/fuchsia-infra/locations/global/keyRings/test-secrets/cryptoKeys"` -### skia_use_wuffs +From //build/testing/secret_spec.gni:8 -**Current value (from the default):** `false` +### dart_custom_version_for_pub +When this argument is a non-empty string, the version repoted by the +Dart VM will be one that is compatible with pub's interpretation of +semantic version strings. The version string will also include the values +of the argument. In particular the version string will read: -From //third_party/skia/BUILD.gn:33 + "M.m.p-dev.x.x-$(dart_custom_version_for_pub)-$(short_git_hash)" -### skia_version +Where 'M', 'm', and 'p' are the major, minor and patch version numbers, +and 'dev.x.x' is the dev version tag most recently preceeding the current +revision. The short git hash can be omitted by setting +dart_version_git_info=false **Current value (from the default):** `""` -From //third_party/flutter/shell/version/version.gni:8 - -### board_packages - -**Current value for `target_cpu = "arm64"`:** `[]` - -From //boards/arm64.gni:7 - -**Overridden from the default:** `[]` - -From //BUILD.gn:40 - -**Current value for `target_cpu = "x64"`:** `[]` - -From //boards/x64.gni:9 - -**Overridden from the default:** `[]` - -From //BUILD.gn:40 +From //third_party/dart/runtime/runtime_args.gni:73 -### dart_debug -Instead of using is_debug, we introduce a different flag for specifying a -Debug build of Dart so that clients can still use a Release build of Dart -while themselves doing a Debug build. +### embedder_for_target +By default, the dynamic library target exposing the embedder API is only +built for the host. The reasoning is that platforms that have target +definitions would not need an embedder API because an embedder +implementation is already provided for said target. This flag allows tbe +builder to obtain a shared library exposing the embedder API for alternative +embedder implementations. **Current value (from the default):** `false` -From //third_party/dart/runtime/runtime_args.gni:9 +From //third_party/flutter/shell/platform/embedder/embedder.gni:12 ### enable_mdns_trace Enables the tracing feature of mdns, which can be turned on using @@ -1343,966 +1419,884 @@ Enables the tracing feature of mdns, which can be turned on using From //garnet/bin/mdns/service/BUILD.gn:15 -### scenic_ignore_vsync +### fvm_slice_size +The size of the FVM partition images "slice size". The FVM slice size is a +minimum size of a particular chunk of a partition that is stored within +FVM. A very small slice size may lead to decreased throughput. A very large +slice size may lead to wasted space. The selected default size of 8mb is +selected for conservation of space, rather than performance. -**Current value (from the default):** `false` +**Current value (from the default):** `"8388608"` -From //garnet/lib/ui/gfx/BUILD.gn:8 +From //build/images/fvm.gni:19 -### current_cpu +### dart_aot_sharing_basis +module_suggester is not AOT compiled in debug builds **Current value (from the default):** `""` -### dart_debug_optimization_level -The optimization level to use for debug builds. Defaults to 0 for builds with -code coverage enabled. +From [//topaz/runtime/dart/dart_component.gni:51](https://fuchsia.googlesource.com/topaz/+/ff9f85507acd416f76801f1a561574b28c48446d/runtime/dart/dart_component.gni#51) -**Current value (from the default):** `"2"` +### zircon_a_partition +arguments to fx flash script -From //third_party/dart/runtime/runtime_args.gni:36 +**Current value (from the default):** `""` -### have_secmem_ta -The secmem TA must be obtained elsewhere and put into the firmware -directory. +From //build/images/BUILD.gn:39 -**Current value (from the default):** `false` +### active_partition -From //garnet/bin/sysmem-assistant/BUILD.gn:44 +**Current value (from the default):** `""` -### max_fvm_size -Maximum allowable size for the FVM in a release mode build -Zero means no limit +From //build/images/BUILD.gn:45 -**Current value (from the default):** `"0"` +### crashpad_dependencies -From //build/images/max_fvm_size.gni:8 +**Current value (from the default):** `"fuchsia"` -### sdk_dirs -The directories to search for parts of the SDK. +From [//third_party/crashpad/build/crashpad_buildconfig.gni:22](https://chromium.googlesource.com/crashpad/crashpad/+/5081a90207ec5e39aefeeab4ccc3e4690ee5c1e5/build/crashpad_buildconfig.gni#22) -By default, we search the public directories for the various layers. -In the future, we'll search a pre-built SDK as well. +### dart_use_crashpad +Whether to link Crashpad library for crash handling. Only supported on +Windows for now. -**Current value (from the default):** `["//garnet/public", "//peridot/public", "//topaz/public"]` +**Current value (from the default):** `false` -From //build/config/fuchsia/sdk.gni:10 +From //third_party/dart/runtime/runtime_args.gni:51 -### skia_enable_atlas_text +### enable_value_subsystem **Current value (from the default):** `false` -From //third_party/skia/BUILD.gn:64 +From //garnet/bin/ui/scenic/BUILD.gn:11 -### skia_enable_fontmgr_win_gdi +### kernel_cmdline_args +List of kernel command line arguments to bake into the boot image. +See also //zircon/docs/kernel_cmdline.md and +[`devmgr_config`](#devmgr_config). -**Current value (from the default):** `false` +**Current value (from the default):** `[]` -From //third_party/skia/BUILD.gn:72 +From //build/images/BUILD.gn:470 -### embedder_for_target -By default, the dynamic library target exposing the embedder API is only -built for the host. The reasoning is that platforms that have target -definitions would not need an embedder API because an embedder -implementation is already provided for said target. This flag allows tbe -builder to obtain a shared library exposing the embedder API for alternative -embedder implementations. +### build_sdk_archives +Whether to build SDK tarballs. **Current value (from the default):** `false` -From //third_party/flutter/shell/platform/embedder/embedder.gni:12 +From //build/sdk/sdk.gni:13 -### enable_dart_analysis -Enable all dart analysis +### dart_target_arch +Explicitly set the target architecture to use a simulator. +Available options are: arm, arm64, x64, ia32, and dbc. -**Current value (from the default):** `true` +**Current value (from the default):** `"arm64"` -From //build/dart/dart_library.gni:15 +From //third_party/dart/runtime/runtime_args.gni:32 -### goma_dir -Absolute directory containing the Goma source code. +### enable_frame_pointers +Controls whether the compiler emits full stack frames for function calls. +This reduces performance but increases the ability to generate good +stack traces, especially when we have bugs around unwind table generation. +It applies only for Fuchsia targets (see below where it is unset). -**Current value (from the default):** `"/home/swarming/goma"` +TODO(ZX-2361): Theoretically unwind tables should be good enough so we can +remove this option when the issues are addressed. -From //build/toolchain/goma.gni:12 +**Current value (from the default):** `true` -### skia_use_libwebp +From //build/config/BUILD.gn:19 -**Current value for `target_cpu = "arm64"`:** `false` +### enable_gfx_subsystem -From //.gn:29 +**Current value (from the default):** `true` -**Overridden from the default:** `true` +From //garnet/bin/ui/scenic/BUILD.gn:12 -From //third_party/skia/BUILD.gn:29 +### log_startup_sleep -**Current value for `target_cpu = "x64"`:** `false` +**Current value (from the default):** `"30000"` -From //.gn:29 +From //garnet/bin/log_listener/BUILD.gn:14 -**Overridden from the default:** `false` +### shell_enable_vulkan -From //third_party/skia/BUILD.gn:29 +**Current value (from the default):** `false` -### rustc_prefix -Sets a custom base directory for `rustc` and `cargo`. -This can be used to test custom Rust toolchains. +From //third_party/flutter/shell/config.gni:6 -**Current value (from the default):** `"//buildtools/linux-x64/rust/bin"` +### skia_enable_pdf -From //build/rust/config.gni:17 +**Current value for `target_cpu = "arm64"`:** `false` -### skia_generate_workarounds +From //.gn:25 -**Current value (from the default):** `false` +**Overridden from the default:** `true` -From //third_party/skia/BUILD.gn:51 +From //third_party/skia/BUILD.gn:45 -### thinlto_cache_dir -ThinLTO cache directory path. +**Current value for `target_cpu = "x64"`:** `false` -**Current value (from the default):** `"dartlang/thinlto-cache"` +From //.gn:25 -From //build/config/lto/config.gni:16 +**Overridden from the default:** `true` -### allow_layer_guesswork -Does nothing. +From //third_party/skia/BUILD.gn:45 -Will be removed after 30 April 2019. +### skia_use_opencl **Current value (from the default):** `false` -From //BUILD.gn:39 +From //third_party/skia/BUILD.gn:31 -### base_package_labels -If you add package labels to this variable, the packages will be included in -the 'base' package set, which represents the set of packages that are part -of an OTA. These pacakages are updated as an atomic unit during an OTA -process and are immutable and are a superset of the TCB (Trusted Computing -Base) for a product. These packages are never evicted by the system. +### board_package_labels +A list of package labels to include in the 'base' package set. Used by the +board definition rather than the product definition. -**Current value for `target_cpu = "arm64"`:** `["//garnet/packages/config:kernel_crash_checker", "//garnet/packages/prod:crashpad_agent", "//garnet/packages/prod:feedback_agent", "//garnet/packages/prod:kernel_crash_checker", "//garnet/packages/products:base", "//bundles:kitchen_sink"]` +**Current value for `target_cpu = "arm64"`:** `["//garnet/packages/prod:drivers", "//garnet/packages/prod:sysmem-assistant"]` -From //root_build_dir/args.gn:3 +From //boards/arm64.gni:9 **Overridden from the default:** `[]` -From //BUILD.gn:14 +From //BUILD.gn:34 -**Current value for `target_cpu = "x64"`:** `["//garnet/packages/config:kernel_crash_checker", "//garnet/packages/prod:crashpad_agent", "//garnet/packages/prod:feedback_agent", "//garnet/packages/prod:kernel_crash_checker", "//garnet/packages/products:base", "//bundles:kitchen_sink"]` +**Current value for `target_cpu = "x64"`:** `["//garnet/packages/prod:drivers"]` -From //root_build_dir/args.gn:3 +From //boards/x64.gni:13 **Overridden from the default:** `[]` -From //BUILD.gn:14 - -### build_libvulkan_qcom_adreno -This is a list of targets that will be built as verisilicon vulkan ICDS. - -**Current value (from the default):** `[]` - -From //garnet/lib/magma/gnbuild/magma.gni:44 - -### dart_snapshot_kind - -**Current value (from the default):** `"kernel"` - -From //third_party/dart/utils/application_snapshot.gni:14 +From //BUILD.gn:34 ### current_os **Current value (from the default):** `""` -### clang_lib_dir -Path to Clang lib directory. +### dart_core_snapshot_kind +Controls the kind of core snapshot linked into the standalone VM. Using a +core-jit snapshot breaks the ability to change various flags that affect +code generation. -**Current value (from the default):** `"../build/buildtools/linux-x64/clang/lib"` +**Current value (from the default):** `"core"` -From //build/images/manifest.gni:19 +From //third_party/dart/runtime/runtime_args.gni:56 -### use_ccache -Set to true to enable compiling with ccache +### sdk_id +Identifier for the Core SDK. -**Current value (from the default):** `false` +**Current value (from the default):** `""` -From //build/toolchain/ccache.gni:9 +From //sdk/config.gni:7 -### dart_vm_code_coverage -Whether to enable code coverage for the standalone VM. +### zedboot_cmdline_args +List of kernel command line arguments to bake into the Zedboot image. +See //zircon/docs/kernel_cmdline.md and +[`zedboot_devmgr_config`](#zedboot_devmgr_config). -**Current value (from the default):** `false` +**Current value (from the default):** `[]` -From //third_party/dart/runtime/runtime_args.gni:39 +From //build/images/zedboot/BUILD.gn:17 -### skia_enable_skottie +### concurrent_link_jobs +Maximum number of concurrent link jobs. -**Current value (from the default):** `true` +We often want to run fewer links at once than we do compiles, because +linking is memory-intensive. The default to use varies by platform and by +the amount of memory available, so we call out to a script to get the right +value. -From //third_party/skia/modules/skottie/BUILD.gn:9 +**Current value (from the default):** `16` -### build_info_version -Logical version of the current build. If not set, defaults to the timestamp -of the most recent update. +From //build/toolchain/BUILD.gn:15 -**Current value (from the default):** `""` +### linux_runner_gateway -From //garnet/BUILD.gn:28 +**Current value (from the default):** `"10.0.0.1"` -### dart_core_snapshot_kind -Controls the kind of core snapshot linked into the standalone VM. Using a -core-jit snapshot breaks the ability to change various flags that affect -code generation. +From //garnet/bin/guest/pkg/biscotti_guest/linux_runner/BUILD.gn:18 -**Current value (from the default):** `"core"` +### skia_enable_discrete_gpu -From //third_party/dart/runtime/runtime_args.gni:56 +**Current value (from the default):** `true` -### kernel_cmdline_files -Files containing additional kernel command line arguments to bake into -the boot image. The contents of these files (in order) come after any -arguments directly in [`kernel_cmdline_args`](#kernel_cmdline_args). -These can be GN `//` source pathnames or absolute system pathnames. +From //third_party/skia/BUILD.gn:43 -**Current value (from the default):** `[]` +### target_os -From //build/images/BUILD.gn:476 +**Current value (from the default):** `""` -### linux_runner_gateway +### experimental_wlan_client_mlme +Selects the SoftMAC client implementation to use. Choices: + false (default) - C++ Client MLME implementation + true - Rust Client MLME implementation +This argument is temporary until Rust MLME is ready to be used. -**Current value (from the default):** `"10.0.0.1"` +**Current value (from the default):** `false` -From //garnet/bin/guest/pkg/biscotti_guest/linux_runner/BUILD.gn:18 +From //src/connectivity/wlan/lib/mlme/cpp/BUILD.gn:10 -### skia_enable_fontmgr_fuchsia +### dart_force_product +Forces all Dart and Flutter apps to build in a specific configuration that +we use to build products. **Current value (from the default):** `false` -From //third_party/skia/BUILD.gn:70 +From [//topaz/runtime/dart/config.gni:10](https://fuchsia.googlesource.com/topaz/+/ff9f85507acd416f76801f1a561574b28c48446d/runtime/dart/config.gni#10) -### dart_platform_bytecode -Whether the VM's platform dill file contains bytecode. +### skia_enable_atlas_text **Current value (from the default):** `false` -From //third_party/dart/runtime/runtime_args.gni:84 +From //third_party/skia/BUILD.gn:64 -### enable_value_subsystem +### skia_enable_fontmgr_empty **Current value (from the default):** `false` -From //garnet/bin/ui/scenic/BUILD.gn:11 +From //third_party/skia/BUILD.gn:65 -### skia_enable_fontmgr_win +### build_info_board +Board configuration of the current build -**Current value (from the default):** `false` +**Current value (from the default):** `""` -From //third_party/skia/BUILD.gn:71 +From //garnet/BUILD.gn:24 -### auto_login_to_guest -Whether basemgr should automatically login as a persistent guest user. +### fuchsia_use_vulkan +Consolidated build toggle for use of Vulkan across Fuchsia -**Current value (from the default):** `false` +**Current value (from the default):** `true` -From //peridot/bin/basemgr/BUILD.gn:13 +From //build/vulkan/config.gni:7 -### build_libvulkan_arm_mali -This is a list of targets that will be built as mali vulkan ICDS. +### prebuilt_dart_sdk +Directory containing prebuilt Dart SDK. +This must have in its `bin/` subdirectory `gen_snapshot.OS-CPU` binaries. +Set to empty for a local build. -**Current value (from the default):** `[]` +**Current value (from the default):** `"//topaz/tools/prebuilt-dart-sdk/linux-x64"` -From //garnet/lib/magma/gnbuild/magma.gni:38 +From //build/dart/dart.gni:9 -### flutter_aot_sharing_basis -When AOT compiling, an app will reference objects in the sharing basis's -snapshot when available instead of writing the objects in its own snapshot. -The snapshot of the sharing basis app will be included in every other app's -package and deduplicated by blobfs. +### concurrent_rust_jobs +Maximum number of Rust processes to run in parallel. -**Current value (from the default):** `""` +We run multiple rustc jobs in parallel, each of which can cause significant +amount of memory, especially when using LTO. To avoid out-of-memory errors +we explicitly reduce the number of jobs. -From [//topaz/runtime/dart/dart_component.gni:27](https://fuchsia.googlesource.com/topaz/+/ff9f85507acd416f76801f1a561574b28c48446d/runtime/dart/dart_component.gni#27) +**Current value (from the default):** `14` -### prebuilt_libvulkan_arm_path +From //build/rust/BUILD.gn:15 + +### dart_version **Current value (from the default):** `""` -From //garnet/lib/magma/gnbuild/magma.gni:23 +From //third_party/flutter/shell/version/version.gni:10 -### skia_use_fontconfig +### scenic_use_views2 +Temporary flag, switches Flutter to using Scenic's new View API. -**Current value for `target_cpu = "arm64"`:** `false` +**Current value (from the default):** `false` -From //.gn:28 +From //garnet/bin/ui/scenic/config.gni:7 -**Overridden from the default:** `true` +### use_prebuilt_dart_sdk +Whether to use the prebuilt Dart SDK for everything. +When setting this to false, the preubilt Dart SDK will not be used in +situations where the version of the SDK matters, but may still be used as an +optimization where the version does not matter. -From //third_party/skia/BUILD.gn:23 +**Current value (from the default):** `true` -**Current value for `target_cpu = "x64"`:** `false` +From //build/dart/dart.gni:15 -From //.gn:28 +### crash_diagnostics_dir +Clang crash reports directory path. Use empty path to disable altogether. -**Overridden from the default:** `false` +**Current value (from the default):** `"//root_build_dir/clang-crashreports"` -From //third_party/skia/BUILD.gn:23 +From //build/config/BUILD.gn:9 -### target_cpu +### skia_llvm_lib -**Current value for `target_cpu = "arm64"`:** `"arm64"` +**Current value (from the default):** `"LLVM"` -From //boards/arm64.gni:5 +From //third_party/skia/BUILD.gn:57 -**Overridden from the default:** `""` +### skia_use_angle -**Current value for `target_cpu = "x64"`:** `"x64"` +**Current value (from the default):** `false` -From //boards/x64.gni:5 +From //third_party/skia/BUILD.gn:20 -**Overridden from the default:** `""` +### skia_enable_fontmgr_fuchsia -### build_libvulkan_vsl_gc -This is a list of targets that will be built as verisilicon vulkan ICDS. +**Current value (from the default):** `false` -**Current value (from the default):** `[]` +From //third_party/skia/BUILD.gn:70 -From //garnet/lib/magma/gnbuild/magma.gni:41 +### enable_sketchy_subsystem -### icu_use_data_file -Tells icu to load an external data file rather than rely on the icudata -being linked directly into the binary. +**Current value (from the default):** `false` -This flag is a bit confusing. As of this writing, icu.gyp set the value to -0 but common.gypi sets the value to 1 for most platforms (and the 1 takes -precedence). +From //garnet/bin/ui/scenic/BUILD.gn:13 -TODO(GYP) We'll probably need to enhance this logic to set the value to -true or false in similar circumstances. +### escher_use_null_vulkan_config_on_host +Using Vulkan on host (i.e. Linux) is an involved affair that involves +downloading the Vulkan SDK, setting environment variables, and so forth... +all things that are difficult to achieve in a CQ environment. Therefore, +by default we use a stub implementation of Vulkan which fails to create a +VkInstance. This allows everything to build, and also allows running Escher +unit tests which don't require Vulkan. **Current value (from the default):** `true` -From [//third_party/icu/config.gni:15](https://fuchsia.googlesource.com/third_party/icu/+/65e4aa3b8cc6b41cf31136b9474a9c97bdc27739/config.gni#15) +From //garnet/public/lib/escher/BUILD.gn:16 -### select_variant_canonical -*This should never be set as a build argument.* -It exists only to be set in `toolchain_args`. -See //build/toolchain/clang_toolchain.gni for details. +### ledger_sync_credentials_file -**Current value (from the default):** `[]` +**Current value (from the default):** `""` -From //build/config/BUILDCONFIG.gn:627 +From //src/ledger/bin/testing/sync_params.gni:6 -### skia_use_libjpeg_turbo +### skia_use_icu **Current value (from the default):** `true` -From //third_party/skia/BUILD.gn:27 +From //third_party/skia/gn/skia.gni:13 -### zircon_extra_args -[Zircon GN build arguments](../../../zircon/docs/gen/build_arguments.md). -This is included in the default value of [`zircon_args`](#zircon_args) so -you can set this to add things there without wiping out the defaults. -When you set `zircon_args` directly, then this has no effect at all. -Arguments you set here override any arguments in the default -`zircon_args`. There is no way to append to a value from the defaults. -Note that for just setting simple (string-only) values in Zircon GN's -[`variants`](../../../zircon/docs/gen/build_arguments.md#variants), the -default [`zircon_args`](#zircon_args) uses a `variants` value derived from -[`select_variant`](#select_variant) so for simple cases there is no need -to explicitly set Zircon's `variants` here. +### dart_debug +Instead of using is_debug, we introduce a different flag for specifying a +Debug build of Dart so that clients can still use a Release build of Dart +while themselves doing a Debug build. -**Current value (from the default):** `{ }` +**Current value (from the default):** `false` -From //build/config/fuchsia/zircon.gni:27 +From //third_party/dart/runtime/runtime_args.gni:9 -### bootfs_extra -List of extra manifest entries for files to add to the BOOTFS. -Each entry can be a "TARGET=SOURCE" string, or it can be a scope -with `sources` and `outputs` in the style of a copy() target: -`outputs[0]` is used as `TARGET` (see `gn help source_expansion`). +### extra_manifest_args +Extra args to globally apply to the manifest generation script. **Current value (from the default):** `[]` -From //build/images/BUILD.gn:482 - -### clang_prefix -The default clang toolchain provided by the buildtools. This variable is -additionally consumed by the Go toolchain. - -**Current value (from the default):** `"../buildtools/linux-x64/clang/bin"` - -From //build/config/clang/clang.gni:11 +From //build/images/manifest.gni:22 -### concurrent_dart_jobs -Maximum number of Dart processes to run in parallel. +### skia_enable_vulkan_debug_layers -Dart analyzer uses a lot of memory which may cause issues when building -with many parallel jobs e.g. when using goma. To avoid out-of-memory -errors we explicitly reduce the number of jobs. +**Current value (from the default):** `false` -**Current value (from the default):** `16` +From //third_party/skia/BUILD.gn:48 -From //build/dart/BUILD.gn:15 +### skia_use_egl -### universe_package_labels -If you add package labels to this variable, the packages will be included -in the 'universe' package set, which represents all software that is -produced that is to be published to a package repository or to the SDK by -the build. The build system ensures that the universe package set includes -the base and cache package sets, which means you do not need to redundantly -include those labels in this variable. +**Current value (from the default):** `false` -**Current value for `target_cpu = "arm64"`:** `["//garnet/packages/prod:vboot_reference", "//bundles:tools"]` +From //third_party/skia/BUILD.gn:21 -From //products/core.gni:26 +### vbmeta_b_partition -**Overridden from the default:** `[]` +**Current value (from the default):** `""` -From //BUILD.gn:30 +From //build/images/BUILD.gn:43 -**Current value for `target_cpu = "x64"`:** `["//garnet/packages/prod:vboot_reference", "//bundles:tools"]` +### vbmeta_r_partition -From //products/core.gni:26 +**Current value (from the default):** `""` -**Overridden from the default:** `[]` +From //build/images/BUILD.gn:44 -From //BUILD.gn:30 +### zedboot_cmdline_files +Files containing additional kernel command line arguments to bake into +the Zedboot image. The contents of these files (in order) come after any +arguments directly in [`zedboot_cmdline_args`](#zedboot_cmdline_args). +These can be GN `//` source pathnames or absolute system pathnames. -### dart_runtime_mode -Set the runtime mode. This affects how the runtime is built and what -features it has. Valid values are: -'develop' (the default) - VM is built to run as a JIT with all development -features enabled. -'profile' - The VM is built to run with AOT compiled code with only the -CPU profiling features enabled. -'release' - The VM is built to run with AOT compiled code with no developer -features enabled. +**Current value (from the default):** `[]` -These settings are only used for Flutter, at the moment. A standalone build -of the Dart VM should leave this set to "develop", and should set -'is_debug', 'is_release', or 'is_product'. +From //build/images/zedboot/BUILD.gn:23 -TODO(rmacnak): dart_runtime_mode no longer selects whether libdart is build -for JIT or AOT, since libdart waw split into libdart_jit and -libdart_precompiled_runtime. We should remove this flag and just set -dart_debug/dart_product. +### concurrent_go_jobs +Maximum number of Go processes to run in parallel. -**Current value (from the default):** `"develop"` +**Current value (from the default):** `16` -From //third_party/dart/runtime/runtime_args.gni:28 +From //build/go/BUILD.gn:11 -### dart_target_arch -Explicitly set the target architecture to use a simulator. -Available options are: arm, arm64, x64, ia32, and dbc. +### dart_default_app +Controls whether dart_app() targets generate JIT or AOT Dart snapshots. +This defaults to JIT, use `fx set <ARCH> --args +'dart_default_app="dart_aot_app"' to switch to AOT. -**Current value (from the default):** `"arm64"` +**Current value (from the default):** `"dart_jit_app"` -From //third_party/dart/runtime/runtime_args.gni:32 +From [//topaz/runtime/dart/dart_component.gni:19](https://fuchsia.googlesource.com/topaz/+/ff9f85507acd416f76801f1a561574b28c48446d/runtime/dart/dart_component.gni#19) -### fuchsia_use_vulkan -Consolidated build toggle for use of Vulkan across Fuchsia +### dart_version_git_info +Whether the Dart binary version string should include the git hash and +git commit time. **Current value (from the default):** `true` -From //build/vulkan/config.gni:7 +From //third_party/dart/runtime/runtime_args.gni:60 -### prebuilt_framework_path +### data_partition_manifest +Path to manifest file containing data to place into the initial /data +partition. **Current value (from the default):** `""` -From [//topaz/runtime/flutter_runner/prebuilt_framework.gni:6](https://fuchsia.googlesource.com/topaz/+/ff9f85507acd416f76801f1a561574b28c48446d/runtime/flutter_runner/prebuilt_framework.gni#6) - -### rust_warnings -Sets whether Rust compiler warnings cause errors or not. -"deny" will make all warnings into errors, while "allow" will ignore warnings - -**Current value (from the default):** `"deny"` - -From //build/rust/config.gni:27 +From //build/images/BUILD.gn:28 -### vbmeta_a_partition +### export_x64_sdk_images -**Current value (from the default):** `""` +**Current value (from the default):** `false` -From //build/images/BUILD.gn:42 +From //sdk/BUILD.gn:12 -### prebuilt_framework_name +### prebuilt_framework_path **Current value (from the default):** `""` -From [//topaz/runtime/flutter_runner/prebuilt_framework.gni:7](https://fuchsia.googlesource.com/topaz/+/ff9f85507acd416f76801f1a561574b28c48446d/runtime/flutter_runner/prebuilt_framework.gni#7) +From [//topaz/runtime/flutter_runner/prebuilt_framework.gni:6](https://fuchsia.googlesource.com/topaz/+/ff9f85507acd416f76801f1a561574b28c48446d/runtime/flutter_runner/prebuilt_framework.gni#6) -### skia_lex +### rust_toolchain_triple_suffix +Sets the fuchsia toolchain target triple suffix (after arch) -**Current value (from the default):** `false` +**Current value (from the default):** `"fuchsia"` -From //third_party/skia/BUILD.gn:52 +From //build/rust/config.gni:23 -### warn_on_sdk_changes -Whether to only warn when an SDK has been modified. -If false, any unacknowledged SDK change will cause a build failure. +### skia_use_libheif **Current value (from the default):** `false` -From //build/sdk/config.gni:8 +From //third_party/skia/BUILD.gn:36 -### zircon_r_partition +### build_info_product +Product configuration of the current build **Current value (from the default):** `""` -From //build/images/BUILD.gn:41 +From //garnet/BUILD.gn:21 -### ledger_sync_credentials_file +### minfs_minimum_data_bytes **Current value (from the default):** `""` -From //src/ledger/bin/testing/sync_params.gni:6 - -### skia_enable_skpicture - -**Current value (from the default):** `true` - -From //third_party/skia/BUILD.gn:47 - -### toolchain_variant -*This should never be set as a build argument.* -It exists only to be set in `toolchain_args`. -See //build/toolchain/clang_toolchain.gni for details. -This variable is a scope giving details about the current toolchain: - `toolchain_variant.base` - [label] The "base" toolchain for this variant, *often the - right thing to use in comparisons, not `current_toolchain`.* - This is the toolchain actually referenced directly in GN - source code. If the current toolchain is not - `shlib_toolchain` or a variant toolchain, this is the same - as `current_toolchain`. In one of those derivative - toolchains, this is the toolchain the GN code probably - thought it was in. This is the right thing to use in a test - like `toolchain_variant.base == target_toolchain`, rather - rather than comparing against `current_toolchain`. - `toolchain_variant.name` - [string] The name of this variant, as used in `variant` fields - in [`select_variant`](#select_variant) clauses. In the base - toolchain and its `shlib_toolchain`, this is `""`. - `toolchain_variant.suffix` - [string] This is "-${toolchain_variant.name}", "" if name is empty. - `toolchain_variant.is_pic_default` - [bool] This is true in `shlib_toolchain`. -The other fields are the variant's effects as defined in -[`known_variants`](#known_variants). - -**Current value (from the default):** -``` -{ - base = "//build/toolchain/fuchsia:arm64" -} -``` - -From //build/config/BUILDCONFIG.gn:74 +From //build/images/fvm.gni:37 -### build_info_product -Product configuration of the current build +### blobfs_minimum_data_bytes +Number of bytes to reserve for data in the fs. This is in addition +to what is reserved, if any, for the inodes. Data bytes constitutes +"usable" space of the fs. +An empty string does not reserve any additional space than minimum +required for the filesystem. **Current value (from the default):** `""` -From //garnet/BUILD.gn:21 - -### dart_space_dart -Whether experimental space dart mode is enabled for Dart applications. +From //build/images/fvm.gni:36 -**Current value (from the default):** `false` +### engine_version -From [//topaz/runtime/dart/dart_component.gni:41](https://fuchsia.googlesource.com/topaz/+/ff9f85507acd416f76801f1a561574b28c48446d/runtime/dart/dart_component.gni#41) +**Current value (from the default):** `""` -### zedboot_devmgr_config -List of arguments to populate /boot/config/devmgr in the Zedboot image. +From //third_party/flutter/shell/version/version.gni:6 -**Current value (from the default):** `["netsvc.netboot=true"]` +### host_tools_dir +This is the directory where host tools intended for manual use by +developers get installed. It's something a developer might put +into their shell's $PATH. Host tools that are just needed as part +of the build do not get copied here. This directory is only for +things that are generally useful for testing or debugging or +whatnot outside of the GN build itself. These are only installed +by an explicit install_host_tools() rule (see //build/host.gni). -From //build/images/zedboot/BUILD.gn:26 +**Current value (from the default):** `"//root_build_dir/tools"` -### dart_default_app -Controls whether dart_app() targets generate JIT or AOT Dart snapshots. -This defaults to JIT, use `fx set <ARCH> --args -'dart_default_app="dart_aot_app"' to switch to AOT. +From //build/host.gni:13 -**Current value (from the default):** `"dart_jit_app"` +### wlancfg_config_type +Selects the wlan configuration type to use. Choices: + "client" - client mode + "ap" - access point mode + "" (empty string) - no configuration -From [//topaz/runtime/dart/dart_component.gni:19](https://fuchsia.googlesource.com/topaz/+/ff9f85507acd416f76801f1a561574b28c48446d/runtime/dart/dart_component.gni#19) +**Current value (from the default):** `"client"` -### flutter_default_app +From //src/connectivity/wlan/wlancfg/BUILD.gn:15 -**Current value (from the default):** `"flutter_jit_app"` +### build_libvulkan_vsl_gc +This is a list of targets that will be built as verisilicon vulkan ICDS. -From [//topaz/runtime/dart/dart_component.gni:12](https://fuchsia.googlesource.com/topaz/+/ff9f85507acd416f76801f1a561574b28c48446d/runtime/dart/dart_component.gni#12) +**Current value (from the default):** `[]` -### flutter_runtime_mode -The runtime mode ("debug", "profile", "release", "dynamic_profile", or "dynamic_release") +From //garnet/lib/magma/gnbuild/magma.gni:41 -**Current value (from the default):** `"debug"` +### full_dart_sdk -From //third_party/flutter/common/config.gni:15 +**Current value (from the default):** `false` -### linux_runner_extras -If `true`, the extras.img will be built and mounted inside the container -at /mnt/chromeos. +From //third_party/flutter/BUILD.gn:10 -This is useful for including some GN-built binaries into the guest image -without modifying the termina images. +### select_variant +List of "selectors" to request variant builds of certain targets. +Each selector specifies matching criteria and a chosen variant. +The first selector in the list to match a given target determines +which variant is used for that target. -**Current value (from the default):** `false` +Each selector is either a string or a scope. A shortcut selector is +a string; it gets expanded to a full selector. A full selector is a +scope, described below. -From //garnet/bin/guest/pkg/biscotti_guest/linux_runner/BUILD.gn:26 +A string selector can match a name in +[`select_variant_shortcuts`](#select_variant_shortcuts). If it's not a +specific shortcut listed there, then it can be the name of any variant +described in [`known_variants`](#known_variants) and +[`universal_variants`](#universal_variants) (and combinations thereof). +A `selector` that's a simple variant name selects for every binary +built in the target toolchain: `{ host=false variant=selector }`. -### skia_compile_processors +If a string selector contains a slash, then it's `"shortcut/filename"` +and selects only the binary in the target toolchain whose `output_name` +matches `"filename"`, i.e. it adds `output_name=["filename"]` to each +selector scope that the shortcut's name alone would yield. -**Current value (from the default):** `false` +The scope that forms a full selector defines some of these: -From //third_party/skia/BUILD.gn:50 + variant (required) + [string or `false`] The variant that applies if this selector + matches. This can be `false` to choose no variant, or a string + that names the variant. See + [`known_variants`](#known_variants) and + [`universal_variants`](#universal_variants). -### skia_use_fixed_gamma_text +The rest below are matching criteria. All are optional. +The selector matches if and only if all of its criteria match. +If none of these is defined, then the selector always matches. -**Current value (from the default):** `false` +The first selector in the list to match wins and then the rest of +the list is ignored. So construct more complex rules by using a +"blacklist" selector with `variant=false` before a catch-all or +"whitelist" selector that names a variant. -From //third_party/skia/BUILD.gn:26 +Each "[strings]" criterion is a list of strings, and the criterion +is satisfied if any of the strings matches against the candidate string. -### zircon_args -[Zircon GN build arguments](../../../zircon/docs/gen/build_arguments.md). -The default passes through GOMA settings and -[`select_variant`](#select_variant) shorthand selectors. -**Only set this if you want to wipe out all the defaults that -propagate from Fuchsia GN to Zircon GN.** The default value -folds in [`zircon_extra_args`](#zircon_extra_args), so usually -it's better to just set `zircon_extra_args` and leave `zircon_args` alone. -Any individual Zircon build argument set in `zircon_extra_args` will -silently clobber the default value shown here. + host + [boolean] If true, the selector matches in the host toolchain. + If false, the selector matches in the target toolchain. -**Current value (from the default):** -``` -{ - default_deps = [":legacy-arm64"] - enable_kernel_debugging_features = false - goma_dir = "/home/swarming/goma" - use_goma = false - variants = [] -} -``` + testonly + [boolean] If true, the selector matches targets with testonly=true. + If false, the selector matches in targets without testonly=true. -From //build/config/fuchsia/zircon.gni:45 + target_type + [strings]: `"executable"`, `"loadable_module"`, or `"driver_module"` -### expat_build_root + output_name + [strings]: target's `output_name` (default: its `target name`) -**Current value (from the default):** `"//third_party/expat"` + label + [strings]: target's full label with `:` (without toolchain suffix) -From //garnet/lib/magma/gnbuild/magma.gni:9 + name + [strings]: target's simple name (label after last `/` or `:`) -### universal_variants + dir + [strings]: target's label directory (`//dir` for `//dir:name`). -**Current value (from the default):** -``` -[{ - configs = [] - name = "release" - toolchain_args = { - is_debug = false -} -}] -``` +**Current value (from the default):** `[]` -From //build/config/BUILDCONFIG.gn:422 +From //build/config/BUILDCONFIG.gn:622 -### use_vboot -Use vboot images +### dart_platform_bytecode +Whether the VM's platform dill file contains bytecode. **Current value (from the default):** `false` -From //build/images/boot.gni:11 +From //third_party/dart/runtime/runtime_args.gni:84 -### blobfs_maximum_bytes -In addition to reserving space for inodes and data, fs needs additional -space for maintaining some internal data structures. So the -space required to reserve inodes and data may exceed sum of the space -needed for inodes and data. -maximum_bytes puts an upper bound on the total bytes reserved for inodes, -data bytes and reservation for all other internal fs metadata. -An empty string does not put any upper bound. A filesystem may -reserve few blocks required for its operations. +### build_libvulkan_arm_mali +This is a list of targets that will be built as mali vulkan ICDS. -**Current value (from the default):** `""` +**Current value (from the default):** `[]` -From //build/images/fvm.gni:47 +From //garnet/lib/magma/gnbuild/magma.gni:38 -### crashpad_dependencies +### gocache_dir + gocache_dir + Directory GOCACHE environment variable will be set to. This directory + will have build and test results cached, and is safe to be written to + concurrently. If overridden, this directory must be a full path. -**Current value (from the default):** `"fuchsia"` +**Current value (from the default):** `"/b/s/w/ir/k/root_build_dir/host_x64/.gocache"` -From [//third_party/crashpad/build/crashpad_buildconfig.gni:22](https://chromium.googlesource.com/crashpad/crashpad/+/5081a90207ec5e39aefeeab4ccc3e4690ee5c1e5/build/crashpad_buildconfig.gni#22) +From //build/go/go_build.gni:16 -### known_variants -List of variants that will form the basis for variant toolchains. -To make use of a variant, set [`select_variant`](#select_variant). +### select_variant_canonical +*This should never be set as a build argument.* +It exists only to be set in `toolchain_args`. +See //build/toolchain/clang_toolchain.gni for details. -Normally this is not set as a build argument, but it serves to -document the available set of variants. -See also [`universal_variants`](#universal_variants). -Only set this to remove all the default variants here. -To add more, set [`extra_variants`](#extra_variants) instead. +**Current value (from the default):** `[]` -Each element of the list is one variant, which is a scope defining: +From //build/config/BUILDCONFIG.gn:627 - `configs` (optional) - [list of labels] Each label names a config that will be - automatically used by every target built in this variant. - For each config `${label}`, there must also be a target - `${label}_deps`, which each target built in this variant will - automatically depend on. The `variant()` template is the - recommended way to define a config and its `_deps` target at - the same time. +### zedboot_devmgr_config +List of arguments to populate /boot/config/devmgr in the Zedboot image. - `remove_common_configs` (optional) - `remove_shared_configs` (optional) - [list of labels] This list will be removed (with `-=`) from - the `default_common_binary_configs` list (or the - `default_shared_library_configs` list, respectively) after - all other defaults (and this variant's configs) have been - added. +**Current value (from the default):** `["netsvc.netboot=true"]` - `deps` (optional) - [list of labels] Added to the deps of every target linked in - this variant (as well as the automatic `${label}_deps` for - each label in configs). +From //build/images/zedboot/BUILD.gn:26 - `name` (required if configs is omitted) - [string] Name of the variant as used in - [`select_variant`](#select_variant) elements' `variant` fields. - It's a good idea to make it something concise and meaningful when - seen as e.g. part of a directory name under `$root_build_dir`. - If name is omitted, configs must be nonempty and the simple names - (not the full label, just the part after all `/`s and `:`s) of these - configs will be used in toolchain names (each prefixed by a "-"), - so the list of config names forming each variant must be unique - among the lists in `known_variants + extra_variants`. +### zxcrypt_key_source +This argument specifies from where the system should obtain the zxcrypt +master key to the system data partition. - `toolchain_args` (optional) - [scope] Each variable defined in this scope overrides a - build argument in the toolchain context of this variant. +This value be reified as /boot/config/zxcrypt in both the zircon boot image +and the zedboot boot image, for consumption by fshost and the paver, +respectively. - `host_only` (optional) - `target_only` (optional) - [scope] This scope can contain any of the fields above. - These values are used only for host or target, respectively. - Any fields included here should not also be in the outer scope. +Acceptable values are: +* "null": the device should use an all-0's master key, as we lack support +for any secure on-device storage. +* "tee": the device is required to have a Trusted Execution Environment +(TEE) which includes the "keysafe" Trusted Application (associated with the +KMS service). The zxcrypt master key should be derived from a per-device +key accessible only to trusted apps running in the TEE. +In the future, we may consider adding support for TPMs, or additional logic +to explicitly support fallback behavior. -**Current value (from the default):** -``` -[{ - configs = ["//build/config/lto"] -}, { - configs = ["//build/config/lto:thinlto"] -}, { - configs = ["//build/config/profile"] -}, { - configs = ["//build/config/scudo"] -}, { - configs = ["//build/config/sanitizers:ubsan"] -}, { - configs = ["//build/config/sanitizers:ubsan", "//build/config/sanitizers:sancov"] -}, { - configs = ["//build/config/sanitizers:asan"] - host_only = { - remove_shared_configs = ["//build/config:symbol_no_undefined"] -} - toolchain_args = { - use_scudo = false -} -}, { - configs = ["//build/config/sanitizers:asan", "//build/config/sanitizers:sancov"] - host_only = { - remove_shared_configs = ["//build/config:symbol_no_undefined"] -} - toolchain_args = { - use_scudo = false -} -}, { - configs = ["//build/config/sanitizers:asan"] - host_only = { - remove_shared_configs = ["//build/config:symbol_no_undefined"] -} - name = "asan_no_detect_leaks" - toolchain_args = { - asan_default_options = "detect_leaks=0" - use_scudo = false -} -}, { - configs = ["//build/config/sanitizers:asan", "//build/config/sanitizers:fuzzer"] - host_only = { - remove_shared_configs = ["//build/config:symbol_no_undefined"] -} - remove_shared_configs = ["//build/config:symbol_no_undefined"] - toolchain_args = { - asan_default_options = "alloc_dealloc_mismatch=0" - use_scudo = false -} -}, { - configs = ["//build/config/sanitizers:ubsan", "//build/config/sanitizers:fuzzer"] - remove_shared_configs = ["//build/config:symbol_no_undefined"] -}] -``` +**Current value (from the default):** `"null"` + +From //build/images/zxcrypt.gni:23 -From //build/config/BUILDCONFIG.gn:337 +### bootfs_extra +List of extra manifest entries for files to add to the BOOTFS. +Each entry can be a "TARGET=SOURCE" string, or it can be a scope +with `sources` and `outputs` in the style of a copy() target: +`outputs[0]` is used as `TARGET` (see `gn help source_expansion`). -### skia_gl_standard +**Current value (from the default):** `[]` -**Current value (from the default):** `""` +From //build/images/BUILD.gn:482 -From //third_party/skia/BUILD.gn:79 +### skia_use_fixed_gamma_text -### use_prebuilt_dart_sdk -Whether to use the prebuilt Dart SDK for everything. -When setting this to false, the preubilt Dart SDK will not be used in -situations where the version of the SDK matters, but may still be used as an -optimization where the version does not matter. +**Current value (from the default):** `false` -**Current value (from the default):** `true` +From //third_party/skia/BUILD.gn:26 -From //build/dart/dart.gni:15 +### update_kernels +List of kernel images to include in the update (OTA) package. +If no list is provided, all built kernels are included. The names in the +list are strings that must match the filename to be included in the update +package. -### skia_use_icu +**Current value (from the default):** `[]` + +From //build/images/BUILD.gn:488 + +### is_debug +Debug build. **Current value (from the default):** `true` -From //third_party/skia/gn/skia.gni:13 +From //build/config/BUILDCONFIG.gn:11 -### skia_use_vulkan +### build_libvulkan_qcom_adreno +This is a list of targets that will be built as verisilicon vulkan ICDS. -**Current value (from the default):** `false` +**Current value (from the default):** `[]` -From //third_party/skia/BUILD.gn:87 +From //garnet/lib/magma/gnbuild/magma.gni:44 -### board_package_labels -A list of package labels to include in the 'base' package set. Used by the -board definition rather than the product definition. +### system_package_key +The package key to use for signing Fuchsia packages made by the +`package()` template (and the `system_image` package). If this +doesn't exist yet when it's needed, it will be generated. New +keys can be generated with the `pm -k FILE genkey` host command. -**Current value for `target_cpu = "arm64"`:** `["//garnet/packages/prod:drivers", "//garnet/packages/prod:sysmem-assistant"]` +**Current value (from the default):** `"//build/development.key"` -From //boards/arm64.gni:9 +From //build/package.gni:18 + +### toolchain_variant +*This should never be set as a build argument.* +It exists only to be set in `toolchain_args`. +See //build/toolchain/clang_toolchain.gni for details. +This variable is a scope giving details about the current toolchain: + `toolchain_variant.base` + [label] The "base" toolchain for this variant, *often the + right thing to use in comparisons, not `current_toolchain`.* + This is the toolchain actually referenced directly in GN + source code. If the current toolchain is not + `shlib_toolchain` or a variant toolchain, this is the same + as `current_toolchain`. In one of those derivative + toolchains, this is the toolchain the GN code probably + thought it was in. This is the right thing to use in a test + like `toolchain_variant.base == target_toolchain`, rather + rather than comparing against `current_toolchain`. + `toolchain_variant.name` + [string] The name of this variant, as used in `variant` fields + in [`select_variant`](#select_variant) clauses. In the base + toolchain and its `shlib_toolchain`, this is `""`. + `toolchain_variant.suffix` + [string] This is "-${toolchain_variant.name}", "" if name is empty. + `toolchain_variant.is_pic_default` + [bool] This is true in `shlib_toolchain`. +The other fields are the variant's effects as defined in +[`known_variants`](#known_variants). + +**Current value (from the default):** +``` +{ + base = "//build/toolchain/fuchsia:arm64" +} +``` + +From //build/config/BUILDCONFIG.gn:74 + +### universe_package_labels +If you add package labels to this variable, the packages will be included +in the 'universe' package set, which represents all software that is +produced that is to be published to a package repository or to the SDK by +the build. The build system ensures that the universe package set includes +the base and cache package sets, which means you do not need to redundantly +include those labels in this variable. + +**Current value for `target_cpu = "arm64"`:** `["//garnet/packages/prod:vboot_reference", "//bundles:tools"]` + +From //products/core.gni:26 **Overridden from the default:** `[]` -From //BUILD.gn:34 +From //BUILD.gn:30 -**Current value for `target_cpu = "x64"`:** `["//garnet/packages/prod:drivers"]` +**Current value for `target_cpu = "x64"`:** `["//garnet/packages/prod:vboot_reference", "//bundles:tools"]` -From //boards/x64.gni:13 +From //products/core.gni:26 **Overridden from the default:** `[]` -From //BUILD.gn:34 +From //BUILD.gn:30 -### build_info_board -Board configuration of the current build +### auto_login_to_guest +Whether basemgr should automatically login as a persistent guest user. -**Current value (from the default):** `""` +**Current value (from the default):** `false` -From //garnet/BUILD.gn:24 +From //peridot/bin/basemgr/BUILD.gn:13 -### linux_runner_ip -Default values for the guest network configuration. +### dart_debug_optimization_level +The optimization level to use for debug builds. Defaults to 0 for builds with +code coverage enabled. -These are currently hard-coded to match what is setup in the virtio-net -device. +**Current value (from the default):** `"2"` -See //garnet/bin/guest/vmm/device/virtio_net.cc for more details. +From //third_party/dart/runtime/runtime_args.gni:36 -**Current value (from the default):** `"10.0.0.2"` +### flutter_space_dart +Whether experimental space dart mode is enabled for Flutter applications. -From //garnet/bin/guest/pkg/biscotti_guest/linux_runner/BUILD.gn:17 +**Current value (from the default):** `false` -### rust_toolchain_triple_suffix -Sets the fuchsia toolchain target triple suffix (after arch) +From [//topaz/runtime/dart/dart_component.gni:38](https://fuchsia.googlesource.com/topaz/+/ff9f85507acd416f76801f1a561574b28c48446d/runtime/dart/dart_component.gni#38) -**Current value (from the default):** `"fuchsia"` +### skia_enable_ccpr -From //build/rust/config.gni:23 +**Current value (from the default):** `true` -### select_variant_shortcuts -List of short names for commonly-used variant selectors. Normally this -is not set as a build argument, but it serves to document the available -set of short-cut names for variant selectors. Each element of this list -is a scope where `.name` is the short name and `.select_variant` is a -a list that can be spliced into [`select_variant`](#select_variant). +From //third_party/skia/BUILD.gn:41 -**Current value (from the default):** -``` -[{ - name = "host_asan" - select_variant = [{ - dir = ["//third_party/yasm", "//third_party/vboot_reference", "//garnet/tools/vboot_reference"] - host = true - variant = "asan_no_detect_leaks" -}, { - host = true - variant = "asan" -}] -}, { - name = "asan" - select_variant = [{ - target_type = ["driver_module"] - variant = false -}, { - host = false - variant = "asan" -}] -}] -``` +### auto_update_packages +Whether the component loader should automatically update packages. -From //build/config/BUILDCONFIG.gn:448 +**Current value (from the default):** `true` -### skia_enable_flutter_defines +From //garnet/bin/sysmgr/BUILD.gn:10 -**Current value for `target_cpu = "arm64"`:** `true` +### prebuilt_framework_name -From //.gn:24 +**Current value (from the default):** `""` -**Overridden from the default:** `false` +From [//topaz/runtime/flutter_runner/prebuilt_framework.gni:7](https://fuchsia.googlesource.com/topaz/+/ff9f85507acd416f76801f1a561574b28c48446d/runtime/flutter_runner/prebuilt_framework.gni#7) -From //third_party/skia/BUILD.gn:16 +### skia_use_sfntly -**Current value for `target_cpu = "x64"`:** `true` +**Current value for `target_cpu = "arm64"`:** `false` -From //.gn:24 +From //.gn:30 + +**Overridden from the default:** `true` + +From //third_party/skia/BUILD.gn:63 + +**Current value for `target_cpu = "x64"`:** `false` + +From //.gn:30 **Overridden from the default:** `false` -From //third_party/skia/BUILD.gn:16 +From //third_party/skia/BUILD.gn:63 -### flutter_profile +### custom_signing_script +If non-empty, the given script will be invoked to produce a signed ZBI +image. The given script must accept -z for the input zbi path, and -o for +the output signed zbi path. The path must be in GN-label syntax (i.e. +starts with //). -**Current value (from the default):** `true` +**Current value (from the default):** `""` -From [//topaz/runtime/dart/dart_component.gni:32](https://fuchsia.googlesource.com/topaz/+/ff9f85507acd416f76801f1a561574b28c48446d/runtime/dart/dart_component.gni#32) +From //build/images/custom_signing.gni:12 -### skia_use_egl +### skia_lex **Current value (from the default):** `false` -From //third_party/skia/BUILD.gn:21 +From //third_party/skia/BUILD.gn:52 -### toolchain_manifests -Manifest files describing target libraries from toolchains. -Can be either // source paths or absolute system paths. +### skia_use_zlib -**Current value (from the default):** `["/b/s/w/ir/k/buildtools/linux-x64/clang/lib/aarch64-fuchsia.manifest"]` +**Current value (from the default):** `true` -From //build/images/manifest.gni:11 +From //third_party/skia/BUILD.gn:34 -## `target_cpu = "arm64"` +### zircon_args +[Zircon GN build arguments](../../../zircon/docs/gen/build_arguments.md). +The default passes through GOMA settings and +[`select_variant`](#select_variant) shorthand selectors. +**Only set this if you want to wipe out all the defaults that +propagate from Fuchsia GN to Zircon GN.** The default value +folds in [`zircon_extra_args`](#zircon_extra_args), so usually +it's better to just set `zircon_extra_args` and leave `zircon_args` alone. +Any individual Zircon build argument set in `zircon_extra_args` will +silently clobber the default value shown here. -### amlogic_decoder_tests +**Current value (from the default):** +``` +{ + default_deps = [":legacy-arm64"] + enable_kernel_debugging_features = false + goma_dir = "/home/swarming/goma" + use_goma = false + variants = [] +} +``` + +From //build/config/fuchsia/zircon.gni:45 + +### skia_enable_fontmgr_custom_empty **Current value (from the default):** `false` -From //garnet/drivers/video/amlogic-decoder/BUILD.gn:11 +From //third_party/skia/BUILD.gn:68 + +## `target_cpu = "arm64"` ### arm_float_abi The ARM floating point mode. This is either the string "hard", "soft", or @@ -2342,6 +2336,12 @@ From //build/config/arm.gni:28 From //build/config/arm.gni:12 +### amlogic_decoder_tests + +**Current value (from the default):** `false` + +From //garnet/drivers/video/amlogic-decoder/BUILD.gn:11 + ## `target_cpu = "x64"` ### msd_intel_enable_mapping_cache diff --git a/zircon/docs/gen/build_arguments.md b/zircon/docs/gen/build_arguments.md index 56cbc069a73d9b4958eee10b61a829ade4b740a5..c3621ccfc7ff7c8c041c058b436ff84a7ed4b132 100644 --- a/zircon/docs/gen/build_arguments.md +++ b/zircon/docs/gen/build_arguments.md @@ -2,20 +2,67 @@ ## All builds -### enable_kernel_debugging_features -Whether to include various features (non-shipping, insecure, etc.) in the -kernel build. +### build_id_dir +Directory to populate with `xx/yyy` and `xx/yyy.debug` links to ELF +files. For every ELF binary built, with build ID `xxyyy` (lowercase +hexadecimal of any length), `xx/yyy` is a hard link to the stripped +file and `xx/yyy.debug` is a hard link to the unstripped file. +Symbolization tools and debuggers find symbolic information this way. -**Current value (from the default):** `false` +**Current value (from the default):** `"/b/s/w/ir/k/out/build-zircon/.build-id"` -From //BUILD.gn:27 +From //public/gn/toolchain/c_toolchain.gni:17 -### enable_lock_dep -Enable kernel lock dependency tracking. +### crash_diagnostics_dir +Clang crash reports directory path. Use empty path to disable altogether. + +**Current value (from the default):** `"/b/s/w/ir/k/out/build-zircon/clang-crashreports"` + +From //public/gn/config/BUILD.gn:10 + +### enable_fair_scheduler +Enable fair scheduler by default on all architectures. + +**Current value (from the default):** `true` + +From //kernel/params.gni:35 + +### kernel_version_string +Version string embedded in the kernel for `zx_system_get_version`. +If set to the default "", a string is generated based on the +Zircon git revision of the checkout. + +**Current value (from the default):** `""` + +From //kernel/lib/version/BUILD.gn:9 + +### current_cpu + +**Current value (from the default):** `""` + +### enable_user_pci +Enable userspace PCI and disable kernel PCI. **Current value (from the default):** `false` -From //kernel/params.gni:32 +From //kernel/params.gni:41 + +### kernel_extra_defines +Extra macro definitions for kernel code, e.g. "DISABLE_KASLR", +"ENABLE_KERNEL_LL_DEBUG". + +**Current value (from the default):** `[]` + +From //kernel/params.gni:45 + +### clang_tool_dir +Directory where the Clang toolchain binaries ("clang", "llvm-nm", etc.) are +found. If this is "", then the behavior depends on $use_prebuilt_clang. +This toolchain is expected to support both Fuchsia targets and the host. + +**Current value (from the default):** `""` + +From //public/gn/toolchain/clang.gni:14 ### enable_lock_dep_tests Enable kernel lock dependency tracking tests. By default this is @@ -27,6 +74,25 @@ disabled. From //kernel/params.gni:53 +### malloc + +**Current value (from the default):** `"scudo"` + +From //third_party/ulib/musl/BUILD.gn:6 + +### zx +*This must never be set as a build argument*. + +"$zx/" is the prefix for GN "source-absolute" paths in the Zircon +build. When Zircon is built standalone, the Zircon repository is the +root of the build (where `.gn` is found) so "$zx/" becomes "//". When +Zircon is part of a larger unified build, there is a higher-level `.gn` +file that uses `default_args` to set "$zx/" to "//zircon/". + +**Current value (from the default):** `"/"` + +From //public/gn/BUILDCONFIG.gn:13 + ### variants List of "selectors" to request variant builds of certain targets. Each selector specifies matching criteria and a chosen variant. The first @@ -245,28 +311,16 @@ Variant scope parameters From //public/gn/toolchain/environment.gni:221 -### use_prebuilt_gcc -If $gcc_tool_dir is "", then this controls how the GCC toolchain -binaries are found. If true, the standard prebuilt is used. If false, -the tools are just expected to be found in PATH. - -**Current value (from the default):** `true` - -From //public/gn/toolchain/gcc.gni:9 - -### enable_fair_scheduler -Enable fair scheduler by default on all architectures. - -**Current value (from the default):** `true` +### current_os -From //kernel/params.gni:35 +**Current value (from the default):** `""` -### enable_user_pci -Enable userspace PCI and disable kernel PCI. +### enable_acpi_debug +Enable debug output in the ACPI library (used by the ACPI bus driver). **Current value (from the default):** `false` -From //kernel/params.gni:41 +From //third_party/lib/acpica/BUILD.gn:9 ### ethernet_c This is used to temporarily enable building with the C driver @@ -276,71 +330,12 @@ and will be removed once cpp driver is stabilized From //system/dev/ethernet/ethernet/BUILD.gn:8 -### goma_dir -Absolute directory containing the Goma source code. - -**Current value (from the default):** `"/home/swarming/goma"` - -From //public/gn/toolchain/goma.gni:12 - -### malloc - -**Current value (from the default):** `"scudo"` - -From //third_party/ulib/musl/BUILD.gn:6 - -### opt_level -* -1 means really unoptimized (-O0), usually only build-tested and not run. -* 0 means "optimized for debugging" (-Og), light enough to avoid confusion. - 1, 2, and 3 are increasing levels of optimization. -* 4 is optimized for space rather than purely for speed. - -**Current value (from the default):** `2` - -From //public/gn/config/levels.gni:15 - -### target_cpu - -**Current value (from the default):** `""` - -### build_id_dir -Directory to populate with `xx/yyy` and `xx/yyy.debug` links to ELF -files. For every ELF binary built, with build ID `xxyyy` (lowercase -hexadecimal of any length), `xx/yyy` is a hard link to the stripped -file and `xx/yyy.debug` is a hard link to the unstripped file. -Symbolization tools and debuggers find symbolic information this way. - -**Current value (from the default):** `"/b/s/w/ir/k/out/build-zircon/.build-id"` - -From //public/gn/toolchain/c_toolchain.gni:17 - -### default_deps -Defines the `//:default` target: what `ninja` with no arguments does. - -**Current value (from the default):** `[":ids", ":images", ":tools"]` - -From //BUILD.gn:19 - -### detailed_scheduler_tracing -Enable detailed scheduler traces. - -**Current value (from the default):** `false` - -From //kernel/params.gni:38 - -### kernel_extra_defines -Extra macro definitions for kernel code, e.g. "DISABLE_KASLR", -"ENABLE_KERNEL_LL_DEBUG". - -**Current value (from the default):** `[]` - -From //kernel/params.gni:45 - -### smp_max_cpus +### netsvc_debug_commands +Whether to enable debug commands in netsvc. -**Current value (from the default):** `16` +**Current value (from the default):** `true` -From //kernel/params.gni:10 +From //system/core/netsvc/BUILD.gn:7 ### sysroot The `--sysroot` directory for host compilations. @@ -363,75 +358,6 @@ The empty list (or empty string) means don't use `--sysroot` at all. From //public/gn/config/BUILD.gn:16 -### current_cpu - -**Current value (from the default):** `""` - -### enable_acpi_debug -Enable debug output in the ACPI library (used by the ACPI bus driver). - -**Current value (from the default):** `false` - -From //third_party/lib/acpica/BUILD.gn:9 - -### kernel_version_string -Version string embedded in the kernel for `zx_system_get_version`. -If set to the default "", a string is generated based on the -Zircon git revision of the checkout. - -**Current value (from the default):** `""` - -From //kernel/lib/version/BUILD.gn:9 - -### tests_in_image -Whether to include all the Zircon tests in the main standalone ZBI. -TODO(mcgrathr): This will be replaced by a more sophisticated plan for -what images to build rather than a single "everything" image that needs -to be pared down. - -**Current value (from the default):** `true` - -From //BUILD.gn:16 - -### use_goma -Set to true to enable distributed compilation using Goma. - -**Current value (from the default):** `false` - -From //public/gn/toolchain/goma.gni:9 - -### zx -*This must never be set as a build argument*. - -"$zx/" is the prefix for GN "source-absolute" paths in the Zircon -build. When Zircon is built standalone, the Zircon repository is the -root of the build (where `.gn` is found) so "$zx/" becomes "//". When -Zircon is part of a larger unified build, there is a higher-level `.gn` -file that uses `default_args` to set "$zx/" to "//zircon/". - -**Current value (from the default):** `"/"` - -From //public/gn/BUILDCONFIG.gn:13 - -### asan_default_options -Default [AddressSanitizer](https://llvm.org/docs/AddressSanitizer.html) -options (before the `ASAN_OPTIONS` environment variable is read at -runtime). This can be set as a build argument to affect most "asan" -variants in $variants (which see), or overridden in $toolchain_args in -one of those variants. Note that setting this nonempty may conflict -with programs that define their own `__asan_default_options` C -function. - -**Current value (from the default):** `""` - -From //public/gn/config/instrumentation/BUILD.gn:13 - -### kernel_aspace_base - -**Current value (from the default):** `"0xffff000000000000"` - -From //kernel/params.gni:26 - ### toolchain *This must never be set as a build argument.* It exists only to be set via c_toolchain(). @@ -449,40 +375,45 @@ See environment() for more information. From //public/gn/BUILDCONFIG.gn:20 -### crash_diagnostics_dir -Clang crash reports directory path. Use empty path to disable altogether. +### use_goma +Set to true to enable distributed compilation using Goma. -**Current value (from the default):** `"/b/s/w/ir/k/out/build-zircon/clang-crashreports"` +**Current value (from the default):** `false` -From //public/gn/config/BUILD.gn:10 +From //public/gn/toolchain/goma.gni:9 -### current_os +### goma_dir +Absolute directory containing the Goma source code. -**Current value (from the default):** `""` +**Current value (from the default):** `"/home/swarming/goma"` -### host_cpu +From //public/gn/toolchain/goma.gni:12 -**Current value (from the default):** `"x64"` +### kernel_aspace_base -### netsvc_debug_commands -Whether to enable debug commands in netsvc. +**Current value (from the default):** `"0xffff000000000000"` + +From //kernel/params.gni:26 + +### use_prebuilt_gcc +If $gcc_tool_dir is "", then this controls how the GCC toolchain +binaries are found. If true, the standard prebuilt is used. If false, +the tools are just expected to be found in PATH. **Current value (from the default):** `true` -From //system/core/netsvc/BUILD.gn:7 +From //public/gn/toolchain/gcc.gni:9 -### target_os +### default_deps +Defines the `//:default` target: what `ninja` with no arguments does. -**Current value (from the default):** `""` +**Current value (from the default):** `[":ids", ":images", ":tools"]` -### clang_tool_dir -Directory where the Clang toolchain binaries ("clang", "llvm-nm", etc.) are -found. If this is "", then the behavior depends on $use_prebuilt_clang. -This toolchain is expected to support both Fuchsia targets and the host. +From //BUILD.gn:19 -**Current value (from the default):** `""` +### host_os -From //public/gn/toolchain/clang.gni:14 +**Current value (from the default):** `"linux"` ### symbol_level * 0 means no debugging information. @@ -493,6 +424,10 @@ From //public/gn/toolchain/clang.gni:14 From //public/gn/config/levels.gni:20 +### target_cpu + +**Current value (from the default):** `""` + ### use_prebuilt_clang If $clang_tool_dir is "", then this controls how the Clang toolchain binaries are found. If true, then the standard prebuilt is used. @@ -502,14 +437,25 @@ Otherwise the tools are just expected to be found by the shell via `PATH`. From //public/gn/toolchain/clang.gni:9 -### assert_level -* 0 means no assertions, not even standard C `assert()`. -* 1 means `ZX_ASSERT` but not `ZX_DEBUG_ASSERT`. -* 2 means both `ZX_ASSERT` and `ZX_DEBUG_ASSERT`. +### asan_default_options +Default [AddressSanitizer](https://llvm.org/docs/AddressSanitizer.html) +options (before the `ASAN_OPTIONS` environment variable is read at +runtime). This can be set as a build argument to affect most "asan" +variants in $variants (which see), or overridden in $toolchain_args in +one of those variants. Note that setting this nonempty may conflict +with programs that define their own `__asan_default_options` C +function. -**Current value (from the default):** `2` +**Current value (from the default):** `""` -From //public/gn/config/levels.gni:9 +From //public/gn/config/instrumentation/BUILD.gn:13 + +### detailed_scheduler_tracing +Enable detailed scheduler traces. + +**Current value (from the default):** `false` + +From //kernel/params.gni:38 ### gcc_tool_dir Directory where the GCC toolchain binaries ("gcc", "nm", etc.) are @@ -523,15 +469,23 @@ system-installed tools found by the shell via `PATH` will be used. From //public/gn/toolchain/gcc.gni:17 -### host_os +### host_cpu -**Current value (from the default):** `"linux"` +**Current value (from the default):** `"x64"` -### kernel_base +### opt_level +* -1 means really unoptimized (-O0), usually only build-tested and not run. +* 0 means "optimized for debugging" (-Og), light enough to avoid confusion. + 1, 2, and 3 are increasing levels of optimization. +* 4 is optimized for space rather than purely for speed. -**Current value (from the default):** `"0xffffffff00000000"` +**Current value (from the default):** `2` -From //kernel/params.gni:18 +From //public/gn/config/levels.gni:15 + +### target_os + +**Current value (from the default):** `""` ### use_ccache Set to true to enable compiling with ccache. @@ -540,3 +494,49 @@ Set to true to enable compiling with ccache. From //public/gn/toolchain/ccache.gni:9 +### assert_level +* 0 means no assertions, not even standard C `assert()`. +* 1 means `ZX_ASSERT` but not `ZX_DEBUG_ASSERT`. +* 2 means both `ZX_ASSERT` and `ZX_DEBUG_ASSERT`. + +**Current value (from the default):** `2` + +From //public/gn/config/levels.gni:9 + +### enable_kernel_debugging_features +Whether to include various features (non-shipping, insecure, etc.) in the +kernel build. + +**Current value (from the default):** `false` + +From //BUILD.gn:27 + +### enable_lock_dep +Enable kernel lock dependency tracking. + +**Current value (from the default):** `false` + +From //kernel/params.gni:32 + +### kernel_base + +**Current value (from the default):** `"0xffffffff00000000"` + +From //kernel/params.gni:18 + +### smp_max_cpus + +**Current value (from the default):** `16` + +From //kernel/params.gni:10 + +### tests_in_image +Whether to include all the Zircon tests in the main standalone ZBI. +TODO(mcgrathr): This will be replaced by a more sophisticated plan for +what images to build rather than a single "everything" image that needs +to be pared down. + +**Current value (from the default):** `true` + +From //BUILD.gn:16 +