| # Copyright 2018 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/package.gni") |
| import("//build/rust/rustc_binary.gni") |
| import("//build/test/test_package.gni") |
| import("//build/testing/environments.gni") |
| |
| rustc_binary("bin") { |
| name = "ril_qmi" |
| edition = "2018" |
| with_unit_tests = true |
| |
| deps = [ |
| "//sdk/fidl/fuchsia.telephony.ril:fuchsia.telephony.ril-rustc", |
| "//src/connectivity/telephony/lib/qmi-protocol", |
| "//src/lib/fidl/rust/fidl", |
| "//src/lib/fuchsia-async", |
| "//src/lib/fuchsia-component", |
| "//src/lib/syslog/rust:syslog", |
| "//src/lib/zircon/rust:fuchsia-zircon", |
| "//third_party/rust_crates:anyhow", |
| "//third_party/rust_crates:bytes", |
| "//third_party/rust_crates:futures", |
| "//third_party/rust_crates:log", |
| "//third_party/rust_crates:parking_lot", |
| "//third_party/rust_crates:pretty_assertions", |
| "//third_party/rust_crates:slab", |
| "//third_party/rust_crates:thiserror", |
| ] |
| |
| sources = [ |
| "src/client.rs", |
| "src/errors.rs", |
| "src/main.rs", |
| "src/transport.rs", |
| ] |
| } |
| |
| package("ril-qmi") { |
| deps = [ ":bin" ] |
| |
| binaries = [ |
| { |
| name = "ril_qmi" |
| }, |
| ] |
| meta = [ |
| { |
| path = rebase_path("meta/ril-qmi.cmx") |
| dest = "ril-qmi.cmx" |
| }, |
| ] |
| } |
| |
| unittest_package("ril-qmi-tests") { |
| package_name = "ril-qmi-tests" |
| |
| deps = [ ":bin_test" ] |
| |
| tests = [ |
| { |
| name = "ril_qmi_bin_test" |
| dest = "ril-qmi-tests" |
| environments = basic_envs |
| }, |
| ] |
| } |