blob: 04dac037d980784d4fc6fa873839edf80d83011f [file] [log] [blame] [edit]
# Copyright 2023 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")
rustc_library("delivery_blob") {
edition = "2021"
name = "delivery_blob"
version = "0.1.0"
visibility = [
"//src/developer/ffx/plugins/package/blob/*",
"//src/developer/ffx/plugins/product/*",
"//src/lib/assembly/*",
"//src/security/lib/scrutiny/*",
"//src/storage/*",
"//src/sys/lib/fidl-fuchsia-pkg-ext/*",
"//src/sys/pkg/*",
]
sources = [
"src/compression.rs",
"src/format.rs",
"src/lib.rs",
]
deps = [
"//src/sys/pkg/lib/fuchsia-merkle",
"//third_party/rust_crates:bitflags",
"//third_party/rust_crates:crc",
"//third_party/rust_crates:itertools",
"//third_party/rust_crates:rayon",
"//third_party/rust_crates:serde",
"//third_party/rust_crates:static_assertions",
"//third_party/rust_crates:thiserror",
"//third_party/rust_crates:zerocopy",
"//third_party/rust_crates:zstd",
"//third_party/zstd",
]
if (is_fuchsia) {
deps += [ "//sdk/rust/zx" ]
}
test_deps = [ "//third_party/rust_crates:rand" ]
with_unit_tests = true
}
fuchsia_unittest_package("delivery-blob-test") {
deps = [ ":delivery_blob_test" ]
}
group("tests") {
testonly = true
deps = [
":delivery-blob-test",
":delivery_blob_test($host_toolchain)",
]
}