blob: 255d0f2a6cbba955836bc2d1a942de2e220e0fcf [file] [log] [blame]
# Copyright 2021 The Fuchsia Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import("//build/components.gni")
import("//build/images/args.gni")
declare_args() {
# Set to one of "minfs", "fxfs", "f2fs" (unstable).
# If set to anything other than "minfs", any existing minfs partition will be
# migrated in-place to the specified format when fshost mounts it.
data_filesystem_format = "fxfs"
# Use Fxfs's blob implementation
# Changes the flashing logic because the outputs changed.
# Toggles a bunch of tests to use fxfs.
fxfs_blob = true
}
# Generates a structured config value file for fshost.
#
# Parameters:
#
# component_name (optional)
# [string] The name of the component for which to produce config, defaults to "fshost".
#
# options (optional)
# [scope] A block of fshost configuration options to include in the config file.
# Unrecognized options cause errors. Later options override earlier options. The provided
# values override all other values, including defaults and build args.
#
template("generated_fshost_config") {
_manifest_target = "${target_name}_manifest"
_component_name = "fshost"
if (defined(invoker.component_name)) {
_component_name = invoker.component_name
}
fuchsia_component_manifest(_manifest_target) {
component_name = _component_name
manifest = "//src/storage/fshost/meta/config.cml"
metadata = {
# we don't want this in the packaged output, it's just to give cmc something to work with
distribution_entries_barrier = []
}
}
fuchsia_structured_config_values(target_name) {
cm_label = ":$_manifest_target"
values = {
# Defaults
blobfs = true
blobfs_max_bytes = 0
bootpart = true
check_filesystems = true
data = true
data_max_bytes = 0
disable_block_watcher = false
factory = false
fvm = true
ramdisk_image = false
fxfs_blob = true
fxfs_crypt_url = "fuchsia-boot:///fxfs-crypt#meta/fxfs-crypt.cm"
gpt = true
gpt_all = false
mbr = false
netboot = false
no_zxcrypt = false
fvm_slice_size = 8388608
blobfs_initial_inodes = 0
blobfs_use_deprecated_padded_format = false
data_filesystem_format = "fxfs"
format_data_on_corruption = true
nand = false
use_disk_migration = false
if (defined(invoker.options)) {
forward_variables_from(invoker.options, "*")
}
}
}
}