blob: 1a5516348cee92e4db09232b8bc04cdf58ecbaa8 [file] [log] [blame]
# Copyright 2017 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/rust/rustc_library.gni")
rustc_library("fuchsia-component") {
version = "0.1.0"
edition = "2021"
with_unit_tests = true
deps = [
"//sdk/fidl/fuchsia.component:fuchsia.component_rust",
"//sdk/fidl/fuchsia.component.decl:fuchsia.component.decl_rust",
"//sdk/fidl/fuchsia.io:fuchsia.io_rust",
"//src/lib/detect-stall",
"//src/lib/fdio/rust:fdio",
"//src/lib/fidl/rust/fidl",
"//src/lib/fuchsia-async",
"//src/lib/fuchsia-fs",
"//src/lib/fuchsia-runtime",
"//src/lib/zircon/rust:fuchsia-zircon",
"//src/storage/lib/vfs/rust:vfs",
"//third_party/rust_crates:anyhow",
"//third_party/rust_crates:futures",
"//third_party/rust_crates:pin-project",
"//third_party/rust_crates:thiserror",
"//third_party/rust_crates:tracing",
]
test_deps = [
"tests:fuchsia.component.client.test_rust",
"//src/lib/fuchsia",
"//src/lib/fuchsia-async",
"//src/lib/fuchsia-fs",
"//src/lib/test_util",
"//third_party/rust_crates:assert_matches",
]
sources = [
"src/client.rs",
"src/directory.rs",
"src/lib.rs",
"src/server/mod.rs",
"src/server/service.rs",
"src/server/until_stalled.rs",
]
}
fuchsia_unittest_package("fuchsia-component-unittests") {
deps = [ ":fuchsia-component_test" ]
}
group("tests") {
testonly = true
deps = [ ":fuchsia-component-unittests" ]
}