| # 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/rust/rustc_binary.gni") |
| |
| assert(is_host) |
| |
| rustc_binary("pbtool") { |
| name = "pbtool" |
| with_unit_tests = true |
| edition = "2021" |
| |
| deps = [ |
| "//build/sdk/meta:rust", |
| "//src/lib/assembly/assembly_manifest", |
| "//src/lib/fuchsia", |
| "//src/lib/product_description", |
| "//src/lib/transfer_manifest", |
| "//third_party/rust_crates:anyhow", |
| "//third_party/rust_crates:argh", |
| "//third_party/rust_crates:camino", |
| "//third_party/rust_crates:pathdiff", |
| "//third_party/rust_crates:serde_json", |
| "//third_party/rust_crates:walkdir", |
| ] |
| |
| test_deps = [ |
| "//src/developer/ffx/lib/pkg:empty-repo-keys", |
| "//src/developer/ffx/lib/pkg:empty-repo-metadata", |
| "//src/lib/assembly/partitions_config", |
| "//src/sys/pkg/lib/fuchsia-repo", |
| "//third_party/rust_crates:camino", |
| "//third_party/rust_crates:tempfile", |
| ] |
| |
| sources = [ |
| "src/build_archive.rs", |
| "src/main.rs", |
| "src/product_description.rs", |
| "src/transfer_manifest.rs", |
| ] |
| } |
| |
| group("tests") { |
| testonly = true |
| deps = [ ":pbtool_test($host_toolchain)" ] |
| } |