| # 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/rust:rustc_binary.bzl", "rustc_binary") | |
| package(default_applicable_licenses = ["//:license"]) | |
| rustc_binary( | |
| name = "bin", | |
| testonly = True, | |
| srcs = ["src/main.rs"], | |
| crate_name = "component_lifecycle_benchmark", | |
| edition = "2024", | |
| deps = [ | |
| "//sdk/fidl/fuchsia.component.decl:fuchsia.component.decl_rust", | |
| "//sdk/fidl/fuchsia.component:fuchsia.component_rust", | |
| "//sdk/fidl/fuchsia.io:fuchsia.io_rust", | |
| "//sdk/fidl/fuchsia.process:fuchsia.process_rust", | |
| "//sdk/rust/zx", | |
| "//src/developer/fuchsia-criterion", | |
| "//src/lib/fidl/rust/fidl", | |
| "//src/lib/fuchsia", | |
| "//src/lib/fuchsia-async", | |
| "//src/lib/fuchsia-component-test", | |
| "//src/lib/fuchsia-runtime", | |
| "//src/lib/fuchsia-sync", | |
| "//third_party/rust_crates/vendor:log", | |
| "//third_party/rust_crates/vendor:rand", | |
| ], | |
| ) | |
| fx_component_manifest( | |
| name = "root_component_manifest", | |
| testonly = True, | |
| component_name = "root_component", | |
| includes = ["//sdk/lib/syslog:offer.shard"], | |
| manifest = "meta/root_component.cml", | |
| ) | |
| fx_component( | |
| name = "root_component", | |
| testonly = True, | |
| compiled_manifest = ":root_component_manifest", | |
| ) |