| # 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/rust/rustc_library.gni") |
| |
| rustc_library("crypto") { |
| edition = "2021" |
| with_unit_tests = true |
| name = "fxfs-crypto" |
| |
| deps = [ |
| "//src/storage/fxfs/trace:trace", |
| "//src/storage/type-fprint:fprint", |
| "//third_party/rust_crates:aes", |
| "//third_party/rust_crates:anyhow", |
| "//third_party/rust_crates:async-trait", |
| "//third_party/rust_crates:byteorder", |
| "//third_party/rust_crates:chacha20", |
| "//third_party/rust_crates:futures", |
| "//third_party/rust_crates:serde", |
| "//third_party/rust_crates:static_assertions", |
| "//third_party/rust_crates:zerocopy", |
| ] |
| sources = [ |
| "src/ff1.rs", |
| "src/lib.rs", |
| ] |
| test_deps = [ "//third_party/rust_crates:rand" ] |
| visibility = [ "//src/storage/fxfs/*" ] |
| |
| # Default optimizations are for size, but that has a noticeable impact on speed. |
| if (!is_debug) { |
| configs -= [ "//build/config:default_optimize" ] |
| configs += [ "//build/config:optimize_speed" ] |
| } |
| } |