blob: b3a86d94d0b64c2f94e88921772043431de07b31 [file] [log] [blame]
# Copyright 2018 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/package.gni")
import("//build/rust/rustc_binary.gni")
import("//src/sys/build/components.gni")
rustc_binary("bin") {
name = "bt_cli"
edition = "2018"
with_unit_tests = true
deps = [
"//sdk/fidl/fuchsia.bluetooth:fuchsia.bluetooth-rustc",
"//sdk/fidl/fuchsia.bluetooth.control:fuchsia.bluetooth.control-rustc",
"//sdk/fidl/fuchsia.bluetooth.sys:fuchsia.bluetooth.sys-rustc",
"//src/connectivity/bluetooth/lib/bt-fidl-mocks",
"//src/connectivity/bluetooth/lib/fuchsia-bluetooth",
"//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:parking_lot",
"//third_party/rust_crates:pin-utils",
"//third_party/rust_crates:regex",
"//third_party/rust_crates:thiserror",
"//third_party/rust_crates/transitional/rustyline",
]
sources = [
"src/commands.rs",
"src/main.rs",
"src/types.rs",
]
}
package("bt-cli") {
name = "bt_cli"
deps = [ ":bin" ]
binaries = [
{
name = "bt_cli"
dest = "bt-cli"
shell = true
},
]
}
fuchsia_unittest_package("bt-cli-unittests") {
manifest = "meta/bt-cli-unittests.cmx"
deps = [ ":bin_test" ]
}
group("tests") {
testonly = true
deps = [ ":bt-cli-unittests" ]
}