| # Copyright 2022 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") |
| import("//src/recovery/system/system_recovery_args.gni") |
| |
| rustc_library("recovery-ui") { |
| edition = "2021" |
| with_unit_tests = true |
| deps = [ |
| "//sdk/fidl/fuchsia.wlan.policy:fuchsia.wlan.policy_rust", |
| "//src/graphics/lib/compute/rive-rs", |
| "//src/lib/fuchsia-async", |
| "//src/lib/ui/carnelian", |
| "//src/lib/zircon/rust:fuchsia-zircon", |
| "//src/recovery/lib/recovery-util", |
| "//third_party/rust_crates:anyhow", |
| "//third_party/rust_crates:derivative", |
| "//third_party/rust_crates:euclid", |
| "//third_party/rust_crates:futures", |
| "//third_party/rust_crates:lazy_static", |
| "//third_party/rust_crates:num-traits", |
| ] |
| sources = [ |
| "src/button.rs", |
| "src/check_network.rs", |
| "src/console.rs", |
| "src/constants.rs", |
| "src/font.rs", |
| "src/generic_view.rs", |
| "src/keyboard.rs", |
| "src/keys.rs", |
| "src/lib.rs", |
| "src/network.rs", |
| "src/progress_bar.rs", |
| "src/proxy_view_assistant.rs", |
| "src/screens.rs", |
| "src/text_field.rs", |
| ] |
| inputs = [ "//prebuilt/third_party/fonts/robotoslab/RobotoSlab-Regular.ttf" ] |
| test_deps = [ |
| "//third_party/rust_crates:mockall", |
| "//third_party/rust_crates:once_cell", |
| ] |
| features = [ |
| # b/255342472 Always enable debug_console until proxy_view_assistant supports a generic overlay ViewAssistantPtr |
| "debug_console", |
| ] |
| if (enable_recovery_ui_v2) { |
| features += [ "ota_ui" ] |
| } |
| } |
| |
| fuchsia_unittest_package("recovery-ui-test") { |
| deps = [ ":recovery-ui_test" ] |
| } |
| |
| group("tests") { |
| testonly = true |
| deps = [ ":recovery-ui-test" ] |
| } |