blob: 706369648329bcf3efa1fa47284172ce0b3ea0cf [file] [edit]
# Copyright 2026 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.
load(
"//build/bazel/rules/components:fx_component.bzl",
"fx_component",
"fx_component_manifest",
)
load(
"//build/bazel/rules/packages:fx_packaged_binary.bzl",
"fx_packaged_binary",
)
load("//build/bazel/rules/rust:rustc_binary.bzl", "rustc_binary")
package(default_applicable_licenses = ["//:license"])
rustc_binary(
name = "bin",
testonly = True,
srcs = ["src/main.rs"],
binary_name = "dev_time_source",
edition = "2024",
deps = [
"//sdk/fidl/fuchsia.time.external:fuchsia.time.external_rust",
"//sdk/rust/zx",
"//src/lib/fidl/rust/fidl",
"//src/lib/fuchsia",
"//src/lib/fuchsia-component",
"//src/sys/time/testing/fidl/test.time:fidl_rust",
"//third_party/rust_crates/vendor:futures",
"//third_party/rust_crates/vendor:log",
],
)
fx_packaged_binary(
name = "bin_packaged_bin",
testonly = True,
binary = ":bin",
binary_name = "dev_time_source",
)
fx_component_manifest(
name = "component-manifest",
testonly = True,
component_name = "dev_time_source",
includes = [
"//sdk/lib/syslog:client.shard",
],
manifest = "meta/service.cml",
)
fx_component(
name = "component",
testonly = True,
compiled_manifest = ":component-manifest",
component_name = "dev_time_source",
visibility = ["//src/sys/time/testing/realm-proxy:__pkg__"],
deps = [":bin_packaged_bin"],
)