| # 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/config/fuchsia/rules.gni") |
| import("//build/test.gni") |
| import("//src/sys/build/components.gni") |
| |
| bind_rules("amlogic_display_bind") { |
| rules = "amlogic-display.bind" |
| output = "amlogic-display-bind.h" |
| tests = "bind_tests.json" |
| deps = [ "//src/devices/bind/amlogic.platform" ] |
| } |
| |
| source_set("common_srcs") { |
| configs += [ |
| "//build/config:all_source", |
| "//build/config/fuchsia:enable_zircon_asserts", |
| ] |
| configs += [ "//build/unification/config:zircon-migrated" ] |
| sources = [ |
| "aml-dsi-host.cc", |
| "aml-hdmi-host.cc", |
| "aml-hdmitx-clk.cc", |
| "aml-hdmitx.cc", |
| "aml-mipi-phy.cc", |
| "amlogic-clock.cc", |
| "amlogic-display.cc", |
| "lcd.cc", |
| "osd.cc", |
| "vout.cc", |
| "vpu.cc", |
| ] |
| public_deps = [ |
| ":amlogic_display_bind", |
| "//sdk/banjo/fuchsia.hardware.amlogiccanvas", |
| "//sdk/banjo/fuchsia.hardware.display.capture", |
| "//sdk/banjo/fuchsia.hardware.display.clamprgb", |
| "//sdk/banjo/fuchsia.hardware.display.controller", |
| "//sdk/banjo/fuchsia.hardware.dsiimpl", |
| "//sdk/banjo/fuchsia.hardware.gpio:fuchsia.hardware.gpio_banjo_cpp", |
| "//sdk/banjo/fuchsia.hardware.i2cimpl", |
| "//sdk/banjo/fuchsia.hardware.platform.device:fuchsia.hardware.platform.device_banjo_cpp", |
| "//sdk/banjo/fuchsia.hardware.sysmem", |
| "//sdk/fidl/fuchsia.sysmem:fuchsia.sysmem_llcpp", |
| "//src/devices/bus/lib/device-protocol-pdev", |
| "//src/devices/bus/lib/device-protocol-platform-device", |
| "//src/devices/lib/driver", |
| "//src/devices/lib/mmio", |
| "//src/graphics/display/lib/device-protocol-display", |
| "//src/lib/ddk", |
| "//src/lib/ddk:ddk-metadata-headers", |
| "//src/lib/ddktl", |
| "//zircon/public/lib/bitmap", |
| "//zircon/public/lib/fbl", |
| "//zircon/public/lib/hwreg", |
| "//zircon/public/lib/sync", |
| "//zircon/public/lib/zircon-internal", |
| "//zircon/public/lib/zx", |
| "//zircon/system/ulib/fzl", |
| "//zircon/system/ulib/image-format", |
| "//zircon/system/ulib/image-format:image-format-llcpp", |
| "//zircon/system/ulib/inspect", |
| "//zircon/system/ulib/mipi-dsi", |
| ] |
| |
| # TODO(fxbug.dev/69585): This target uses raw zx::channel with LLCPP which is deprecated. |
| # Please migrate to typed channel APIs (fidl::ClientEnd<T>, fidl::ServerEnd<T>). |
| # See linked bug for details. |
| configs += [ "//build/cpp:fidl-llcpp-deprecated-raw-channels" ] |
| } |
| |
| driver_module("amlogic-display") { |
| deps = [ ":common_srcs" ] |
| } |
| |
| test("amlogic-display-test") { |
| configs += [ |
| "//build/unification/config:zircon-migrated", |
| "//build/config:all_source", |
| ] |
| sources = [ "amlogic-display-test.cc" ] |
| deps = [ |
| ":common_srcs", |
| "//src/devices/sysmem/testing/mock-sysmem", |
| "//src/devices/testing/no_ddk", |
| "//zircon/public/lib/zxtest", |
| "//zircon/system/ulib/async-loop:async-loop-cpp", |
| "//zircon/system/ulib/async-loop:async-loop-default", |
| "//zircon/system/ulib/fidl-async:fidl-async-cpp", |
| "//zircon/system/ulib/fzl", |
| ] |
| |
| # TODO(fxbug.dev/69585): This target uses raw zx::channel with LLCPP which is deprecated. |
| # Please migrate to typed channel APIs (fidl::ClientEnd<T>, fidl::ServerEnd<T>). |
| # See linked bug for details. |
| configs += [ "//build/cpp:fidl-llcpp-deprecated-raw-channels" ] |
| } |
| |
| group("tests") { |
| testonly = true |
| deps = [ |
| ":amlogic-display-test-package", |
| ":amlogic_display_bind_test", |
| ] |
| } |
| |
| fuchsia_unittest_package("amlogic-display-test-package") { |
| package_name = "amlogic-display-test" |
| deps = [ ":amlogic-display-test" ] |
| } |