| # Copyright 2022 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/drivers.gni") |
| |
| group("drivers") { |
| deps = [ |
| ":child_component", |
| ":parent_component", |
| ] |
| } |
| |
| driver_bind_rules("parent_bind") { |
| rules = "meta/parent-driver.bind" |
| bind_output = "parent-driver.bindbc" |
| deps = [ "//src/devices/bind/fuchsia.test" ] |
| } |
| |
| fuchsia_cc_driver("parent_driver") { |
| legacy = true |
| output_name = "driver_transport_parent_v1" |
| sources = [ "parent-driver.cc" ] |
| deps = [ |
| ":parent_bind", |
| "//examples/drivers/transport/driver:fuchsia.examples.gizmo_cpp", |
| "//sdk/lib/driver/component/cpp", |
| "//sdk/lib/driver/runtime:driver_runtime_cpp", |
| "//src/devices/lib/driver", |
| "//src/devices/lib/driver:driver_runtime", |
| "//src/lib/ddktl", |
| ] |
| } |
| |
| fuchsia_driver_component("parent_component") { |
| component_name = "driver_transport_parent" |
| deps = [ ":parent_driver" ] |
| info = "meta/component-info.json" |
| manifest = "meta/parent_component.cml" |
| } |
| |
| driver_bind_rules("child_bind") { |
| rules = "meta/child-driver.bind" |
| bind_output = "child-driver.bindbc" |
| deps = |
| [ "//examples/drivers/transport/driver:fuchsia.examples.gizmo_bindlib" ] |
| } |
| |
| fuchsia_cc_driver("child_driver") { |
| legacy = true |
| output_name = "driver_transport_child_v1" |
| sources = [ "child-driver.cc" ] |
| deps = [ |
| ":child_bind", |
| "//examples/drivers/transport/driver:fuchsia.examples.gizmo_cpp", |
| "//sdk/lib/driver/runtime:driver_runtime_cpp", |
| "//src/devices/lib/driver", |
| "//src/devices/lib/driver:driver_runtime", |
| "//src/lib/ddktl", |
| ] |
| } |
| |
| fuchsia_driver_component("child_component") { |
| component_name = "driver_transport_child" |
| deps = [ ":child_driver" ] |
| info = "meta/component-info.json" |
| manifest = "meta/child_component.cml" |
| } |