blob: 938d0f4489c0a9f87c2f1f3091334e40d29237e2 [file] [log] [blame]
# Codec common sources
add_subdirectory(apigen-codec-common)
add_subdirectory(compressedTextureFormats)
# Vulkan
add_subdirectory(vulkan)
# GLES translator
add_subdirectory(glestranslator)
add_subdirectory(libGLSnapshot)
# GLES decoder
add_subdirectory(gles1_dec)
add_subdirectory(gles2_dec)
# GLES dispatch based on Translator
add_subdirectory(OpenGLESDispatch)
# RenderControl decoder
add_subdirectory(renderControl_dec)
# Stream server core
set(gfxstream_backend-common-sources
ChannelStream.cpp
ColorBuffer.cpp
FbConfig.cpp
FenceSync.cpp
GLESVersionDetector.cpp
PostWorker.cpp
ReadbackWorker.cpp
ReadBuffer.cpp
render_api.cpp
RenderChannelImpl.cpp
RenderThreadInfo.cpp
RingStream.cpp
SyncThread.cpp
TextureDraw.cpp
TextureResize.cpp
WindowSurface.cpp
YUVConverter.cpp
RenderThread.cpp
RenderWindow.cpp
RenderLibImpl.cpp
RendererImpl.cpp
FrameBuffer.cpp
GfxStreamAgents.cpp
GfxStreamBackend.cpp
virtio-gpu-gfxstream-renderer.cpp)
if (APPLE)
set(gfxstream_backend-platform-sources NativeSubWindow_cocoa.m)
elseif (WIN32)
set(gfxstream_backend-platform-sources NativeSubWindow_win32.cpp)
else()
set(gfxstream_backend-platform-sources NativeSubWindow_x11.cpp)
endif()
add_library(
gfxstream_backend
SHARED
${gfxstream_backend-common-sources}
${gfxstream_backend-platform-sources})
target_link_libraries(
gfxstream_backend
PUBLIC
gfxstream-host-common
gfxstream-base
OpenGLESDispatch
gles1_dec
gles2_dec
renderControl_dec
gfxstream-vulkan-server
apigen-codec-common)
target_include_directories(
gfxstream_backend
PUBLIC
${GFXSTREAM_REPO_ROOT}
${GFXSTREAM_REPO_ROOT}/include
${GFXSTREAM_REPO_ROOT}/stream-servers
${GFXSTREAM_REPO_ROOT}/stream-servers/apigen-codec-common
${GFXSTREAM_REPO_ROOT}/stream-servers/vulkan)
# Testing libraries
add_subdirectory(testlibs)
# Backend unit tests
add_executable(
gfxstream_backend_unittests
gfxstream_unittest.cpp)
target_link_libraries(
gfxstream_backend_unittests
PRIVATE
OSWindow
gfxstream_backend
gfxstream-base
gtest_main)