kwin/plugins/platforms/drm/CMakeLists.txt
Martin Flöser c8ede9a5ff Build platform plugins in correct sub directory of build dir
Summary:
This brings KWin a step closer to be run from build dir without having
to install at all. The integration tests are adjusted so that the
virtual platform is still found which makes the code be closer to what
is used in normal kwin_wayland.

Test Plan: ctest passes, manually verified correct plugin is loaded

Reviewers: #kwin

Subscribers: kwin

Tags: #kwin

Differential Revision: https://phabricator.kde.org/D17388
2018-12-13 19:36:28 +01:00

39 lines
1 KiB
CMake

set(DRM_SOURCES
drm_backend.cpp
drm_object.cpp
drm_object_connector.cpp
drm_object_crtc.cpp
drm_object_plane.cpp
drm_output.cpp
drm_buffer.cpp
drm_inputeventfilter.cpp
logging.cpp
scene_qpainter_drm_backend.cpp
screens_drm.cpp
)
if(HAVE_GBM)
set(DRM_SOURCES ${DRM_SOURCES}
egl_gbm_backend.cpp
drm_buffer_gbm.cpp
gbm_surface.cpp
remoteaccess_manager.cpp
)
endif()
include_directories(${CMAKE_SOURCE_DIR}/platformsupport/scenes/opengl)
add_library(KWinWaylandDrmBackend MODULE ${DRM_SOURCES})
set_target_properties(KWinWaylandDrmBackend PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/org.kde.kwin.waylandbackends/")
target_link_libraries(KWinWaylandDrmBackend kwin Libdrm::Libdrm SceneQPainterBackend SceneOpenGLBackend)
if(HAVE_GBM)
target_link_libraries(KWinWaylandDrmBackend gbm::gbm)
endif()
install(
TARGETS
KWinWaylandDrmBackend
DESTINATION
${PLUGIN_INSTALL_DIR}/org.kde.kwin.waylandbackends/
)