blob: 661a88155b09aacc0acca9bed4cfea0abb4b5b5b [file] [log] [blame]
# Copyright 2017 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.
source_set("surface_header") {
sources = [ "image_pipe_surface.h" ]
public_deps = [
"//sdk/fidl/fuchsia.images",
"//src/lib/vulkan:headers",
]
}
loadable_module("swapchain") {
output_name = "VkLayer_image_pipe_swapchain"
sources = [
"fuchsia_platform_event.cc",
"image_pipe_surface_async.cc",
"image_pipe_surface_async.h",
"image_pipe_swapchain_layer.cc",
]
deps = [
":surface_header",
"//sdk/lib/fdio",
"//src/lib/fsl",
"//src/lib/vulkan:micro_layer_common",
"//zircon/system/ulib/async-loop:async-loop-cpp",
"//zircon/system/ulib/async-loop:async-loop-default",
"//zircon/system/ulib/trace",
]
ldflags = [ "-static-libstdc++" ]
}
source_set("display") {
sources = [
"fuchsia_platform_event.cc",
"image_pipe_surface_display.cc",
"image_pipe_surface_display.h",
]
deps = [
":surface_header",
"//sdk/fidl/fuchsia.hardware.display:fuchsia.hardware.display_c",
"//sdk/fidl/fuchsia.sysmem",
"//sdk/lib/fdio",
"//src/lib/fsl",
"//src/lib/vulkan:micro_layer_common",
"//zircon/public/lib/async-cpp",
"//zircon/public/lib/fbl",
"//zircon/system/ulib/fdio-caller",
"//zircon/system/ulib/fzl",
]
public_deps = [
"//sdk/fidl/fuchsia.hardware.display",
"//zircon/system/ulib/async-loop:async-loop-cpp",
"//zircon/system/ulib/async-loop:async-loop-default",
]
}
loadable_module("fb") {
output_name = "VkLayer_image_pipe_swapchain_fb"
defines = [ "USE_IMAGEPIPE_SURFACE_FB" ]
sources = [ "image_pipe_swapchain_layer.cc" ]
deps = [
":display",
":surface_header",
"//src/lib/vulkan:micro_layer_common",
"//zircon/system/ulib/trace",
]
ldflags = [ "-static-libstdc++" ]
}
loadable_module("fb_skip_present") {
output_name = "VkLayer_image_pipe_swapchain_fb_skip_present"
defines = [
"USE_IMAGEPIPE_SURFACE_FB",
"SKIP_PRESENT",
]
sources = [ "image_pipe_swapchain_layer.cc" ]
deps = [
":display",
":surface_header",
"//src/lib/vulkan:micro_layer_common",
"//zircon/system/ulib/trace",
]
ldflags = [ "-static-libstdc++" ]
}
loadable_module("copy") {
testonly = true # Not intended for production use
output_name = "VkLayer_image_pipe_swapchain_copy"
defines = [ "USE_SWAPCHAIN_SURFACE_COPY" ]
sources = [
"image_pipe_swapchain_layer.cc",
"swapchain_copy_surface.cc",
"swapchain_copy_surface.h",
]
deps = [
":surface_header",
"//src/lib/vulkan:micro_layer_common",
]
if (is_fuchsia) {
sources += [ "fuchsia_platform_event.cc" ]
deps += [ "//zircon/system/ulib/trace" ]
ldflags = [ "-static-libstdc++" ]
}
if (is_linux) {
sources += [ "linux_platform_event.cc" ]
}
}
loadable_module("wayland_copy") {
output_name = "VkLayer_wayland_swapchain_copy"
defines = [ "USE_SWAPCHAIN_SURFACE_COPY" ]
sources = [
"image_pipe_swapchain_layer.cc",
"linux_platform_event.cc",
"swapchain_copy_surface.cc",
"swapchain_copy_surface.h",
]
deps = [
":surface_header",
"//src/lib/vulkan:micro_layer_common",
]
}
group("wayland_copy_linux_x64") {
deps = [ ":wayland_copy(//build/toolchain:linux_x64)" ]
}