| # Copyright 2021 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. |
| |
| if (is_host) { |
| import("//build/rust/rustc_library.gni") |
| import("//build/rust/rustc_test.gni") |
| import("//build/testing/test_spec.gni") |
| |
| rustc_library("lib") { |
| name = "ffx_fastboot" |
| edition = "2018" |
| with_unit_tests = true |
| |
| deps = [ |
| "//build/sdk/meta:rust", |
| "//sdk/fidl/fuchsia.developer.ffx:fuchsia.developer.ffx-rustc", |
| "//src/developer/ffx/config:lib", |
| "//src/developer/ffx/lib/errors:lib", |
| "//src/developer/ffx/lib/fms:lib", |
| "//src/lib/fidl/rust/fidl", |
| "//src/lib/fuchsia-async", |
| "//src/lib/gcs:lib", |
| "//third_party/rust_crates:anyhow", |
| "//third_party/rust_crates:async-fs", |
| "//third_party/rust_crates:async-trait", |
| "//third_party/rust_crates:base64", |
| "//third_party/rust_crates:blocking", |
| "//third_party/rust_crates:byteorder", |
| "//third_party/rust_crates:chrono", |
| "//third_party/rust_crates:flate2", |
| "//third_party/rust_crates:futures", |
| "//third_party/rust_crates:glob", |
| "//third_party/rust_crates:log", |
| "//third_party/rust_crates:regex", |
| "//third_party/rust_crates:ring", |
| "//third_party/rust_crates:serde", |
| "//third_party/rust_crates:serde_json", |
| "//third_party/rust_crates:tar", |
| "//third_party/rust_crates:tempfile", |
| "//third_party/rust_crates:termion", |
| "//third_party/rust_crates:url", |
| "//third_party/rust_crates:walkdir", |
| "//third_party/rust_crates:zip", |
| ] |
| |
| sources = [ |
| "src/boot/mod.rs", |
| "src/common/cmd.rs", |
| "src/common/crypto.rs", |
| "src/common/file.rs", |
| "src/common/gcs.rs", |
| "src/common/mod.rs", |
| "src/info/mod.rs", |
| "src/lib.rs", |
| "src/lock/mod.rs", |
| "src/manifest/mod.rs", |
| "src/manifest/sdk.rs", |
| "src/manifest/v1.rs", |
| "src/manifest/v2.rs", |
| "src/manifest/v3.rs", |
| "src/unlock/mod.rs", |
| ] |
| } |
| |
| group("fastboot") { |
| deps = [ ":lib" ] |
| } |
| |
| group("tests") { |
| testonly = true |
| deps = [ ":lib_test" ] |
| } |
| } |