| # Copyright 2019 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/bind/bind.gni") |
| import("//build/drivers.gni") |
| |
| driver_bind_rules("gpio-light-bind") { |
| rules = "gpio-light.bind" |
| header_output = "gpio-light-bind.h" |
| bind_output = "gpio-light.bindbc" |
| tests = "bind-tests.json" |
| deps = [ "//src/devices/bind/fuchsia.platform" ] |
| } |
| |
| fuchsia_driver("gpio-light-driver") { |
| output_name = "gpio-light" |
| configs += [ |
| "//build/config:all_source", |
| "//build/config/fuchsia:enable_zircon_asserts", |
| ] |
| sources = [ "gpio-light.cc" ] |
| deps = [ |
| ":gpio-light-bind", |
| "//sdk/banjo/fuchsia.hardware.gpio:fuchsia.hardware.gpio_banjo_cpp", |
| "//sdk/banjo/fuchsia.hardware.gpioimpl:fuchsia.hardware.gpioimpl_banjo_cpp", |
| "//sdk/fidl/fuchsia.hardware.light:fuchsia.hardware.light_llcpp", |
| "//src/devices/lib/driver", |
| "//src/lib/ddk", |
| "//src/lib/ddktl", |
| "//zircon/system/ulib/fbl", |
| "//zircon/system/ulib/fidl", |
| "//zircon/system/ulib/sync", |
| "//zircon/system/ulib/zx", |
| ] |
| } |
| |
| fuchsia_driver_component("gpio-light") { |
| component_name = "gpio-light" |
| deps = [ ":gpio-light-driver" ] |
| info = "gpio-light-info.json" |
| colocate = true |
| } |
| |
| group("tests") { |
| testonly = true |
| deps = [ ":gpio-light-bind_test" ] |
| } |