| # 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/test.gni") |
| |
| group("tests") { |
| testonly = true |
| |
| deps = [ ":driver-restricted-symbols-tests" ] |
| } |
| |
| static_library("driver_symbols") { |
| sources = [ |
| "restricted_symbols.h", |
| "symbols.cc", |
| "symbols.h", |
| ] |
| deps = [ "//zircon/system/ulib/zircon-internal" ] |
| public_deps = [ |
| "//zircon/system/public", |
| "//zircon/system/ulib/zx", |
| ] |
| } |
| |
| test("driver_symbols_test") { |
| sources = [ "symbols_test.cc" ] |
| |
| deps = [ |
| ":driver_symbols", |
| "//zircon/system/ulib/zxtest", |
| ] |
| } |
| |
| fuchsia_unittest_component("driver_symbols_unittests") { |
| deps = [ ":driver_symbols_test" ] |
| } |
| |
| fuchsia_test_package("driver-restricted-symbols-tests") { |
| test_components = [ ":driver_symbols_unittests" ] |
| } |
| |
| rustc_library("driver_symbols_rust") { |
| name = "driver_symbols" |
| version = "0.1.0" |
| edition = "2021" |
| |
| deps = [ |
| "//sdk/rust/zx", |
| "//sdk/rust/zx-types", |
| ] |
| |
| non_rust_deps = [ ":driver_symbols" ] |
| |
| public_configs = [ "//build/config/fuchsia:static_cpp_standard_library" ] |
| |
| sources = [ |
| "src/bindings.rs", |
| "src/lib.rs", |
| "src/symbols.rs", |
| ] |
| } |