blob: 29ccd9cf96d189ae1464e9f7c38c053eca29ff51 [file] [log] [blame]
# Copyright 2019 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/config.gni")
# Define pkg_resolver configuration data to be included in the
# config-data package.
#
# enable_dynamic_configuration
# [bool] enable editing package URL rewrite rules and repository configs.
#
template("pkg_resolver_config") {
cfg = {
forward_variables_from(invoker, [ "enable_dynamic_configuration" ])
assert(defined(enable_dynamic_configuration),
"enable_dynamic_configuration must be defined")
}
config_path = "$target_gen_dir/pkg_resolver_config.json"
write_file(config_path, cfg, "json")
config_data(target_name) {
for_pkg = "pkg-resolver"
outputs = [ "config.json" ]
sources = [ config_path ]
}
}