kwin/backends/drm/CMakeLists.txt
Martin Gräßlin 2220ae44c4 Create a plugin for each of the wayland backends
Each of the backends becomes a plugin. This allows kwin_wayland to load
the requested plugin and kwin itself doesn't need to link all the
libraries needed. E.g. libdrm is no longer linked if running kwin_x11.
Also this allows to create backends for the non-standard EGL platforms
(examples could be raspberrypi or Android devices).
2015-05-06 10:31:39 +02:00

24 lines
520 B
CMake

set(DRM_SOURCES
drm_backend.cpp
logging.cpp
scene_qpainter_drm_backend.cpp
screens_drm.cpp
)
if(HAVE_GBM)
set(DRM_SOURCES ${DRM_SOURCES} egl_gbm_backend.cpp)
endif()
add_library(KWinWaylandDrmBackend MODULE ${DRM_SOURCES})
target_link_libraries(KWinWaylandDrmBackend kwin Libdrm::Libdrm)
if(HAVE_GBM)
target_link_libraries(KWinWaylandDrmBackend gbm::gbm)
endif()
install(
TARGETS
KWinWaylandDrmBackend
DESTINATION
${PLUGIN_INSTALL_DIR}/org.kde.kwin.waylandbackends/
)