blob: b315ec2349363a01460d0d29719f92a9d1362803 [file] [log] [blame]
# 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.
import("//build/components.gni")
import("//build/rust/rustc_library.gni")
group("rust") {
public_deps = [ ":lib" ]
}
group("tests") {
testonly = true
deps = [ ":diagnostics-message-tests" ]
}
rustc_library("lib") {
edition = "2021"
name = "diagnostics_message"
with_unit_tests = true
deps = [
"//sdk/fidl/fuchsia.logger:fuchsia.logger_rust",
"//src/lib/diagnostics/data/rust",
"//src/lib/diagnostics/log/encoding/rust",
"//src/lib/zircon/rust:fuchsia-zircon",
"//third_party/rust_crates:byteorder",
"//third_party/rust_crates:libc",
"//third_party/rust_crates:serde",
"//third_party/rust_crates:thiserror",
]
test_deps = [
"//sdk/fidl/fuchsia.diagnostics:fuchsia.diagnostics_rust",
"//src/lib/fuchsia",
"//third_party/rust_crates:assert_matches",
"//third_party/rust_crates:lazy_static",
]
sources = [
"src/constants.rs",
"src/error.rs",
"src/lib.rs",
"src/test.rs",
]
}
fuchsia_unittest_package("diagnostics-message-tests") {
deps = [ ":lib_test" ]
}