blob: 84264a5ea93305365dc05d9b757026610c30f44c [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/rust/rustc_binary.gni")
import("//build/rust/rustc_test.gni")
import("//src/sys/build/components.gni")
rustc_binary("bin") {
name = "factoryctl"
edition = "2018"
with_unit_tests = true
deps = [
"//garnet/lib/rust/files_async",
"//garnet/lib/rust/io_util",
"//sdk/fidl/fuchsia.boot:fuchsia.boot-rustc",
"//sdk/fidl/fuchsia.factory:fuchsia.factory-rustc",
"//sdk/fidl/fuchsia.io:fuchsia.io-rustc",
"//src/lib/fdio/rust:fdio",
"//src/lib/fidl/rust/fidl",
"//src/lib/fuchsia-async",
"//src/lib/fuchsia-component",
"//src/lib/zircon/rust:fuchsia-zircon",
"//third_party/rust_crates:anyhow",
"//third_party/rust_crates:futures",
"//third_party/rust_crates:nom",
"//third_party/rust_crates:structopt",
"//third_party/rust_crates:thiserror",
]
test_deps = [ "//src/lib/storage/pseudo-fs" ]
sources = [ "src/main.rs" ]
}
fuchsia_component("factoryctl_comp") {
component_name = "factoryctl"
manifest = "meta/factoryctl.cmx"
deps = [ ":bin" ]
}
fuchsia_shell_package("factoryctl") {
deps = [ ":factoryctl_comp" ]
}
fuchsia_unittest_component("factoryctl_bin_test_comp") {
component_name = "factoryctl_bin_test"
manifest = "meta/factoryctl_bin_test.cmx"
deps = [ ":bin_test" ]
}
fuchsia_test_package("factoryctl_tests") {
test_components = [ ":factoryctl_bin_test_comp" ]
deps = [ ":factoryctl_comp" ]
}