blob: d7ea789dac2f37cbc50a91f7eeef5603d42e52e2 [file] [log] [blame]
# Copyright 2020 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/product.gni")
import("//build/security.gni")
import("//build/security/policies.gni")
import("//build/security/policies_swd.gni")
if (is_host) {
group("host") {
testonly = true
# This causes all labels listed in the GN arg to be assumed to be in the
# host toolchain, but if a different toolchain is specified, it is
# preserved.
#
# [ "//some/label", "//some/other:label(//some/toolchain)" ]
#
# becomes
#
# [ "//some/label($host_toolchain)", "//some/other:label(//some/toolchain)"]
#
# This is for cases where the product needs to build "host tools" for
# specific platforms that aren't necessarily the one that the compilation
# is running on.
deps = product_host_labels
}
} else {
## These should only be in the default toolchain.
assert(current_toolchain == default_toolchain)
group("bootfs_labels") {
testonly = fuchsia_zbi_testonly
deps = product_bootfs_labels
}
group("system_image_deps") {
testonly = fuchsia_zbi_testonly
deps = product_system_image_deps
if (defined(policy_labels.swd)) {
foreach(policy, policies_swd) {
if (policy.name == policy_labels.swd) {
deps += policy.system_image_deps
}
}
}
}
}