2014-11-21 21:24:33 +01:00
|
|
|
# Define the current source locations
|
|
|
|
SET(CURRENT_HEADER_DIR ${CMAKE_SOURCE_DIR}/include/grabber)
|
|
|
|
SET(CURRENT_SOURCE_DIR ${CMAKE_SOURCE_DIR}/libsrc/grabber/x11)
|
|
|
|
|
|
|
|
# Find X11
|
|
|
|
find_package(X11 REQUIRED)
|
|
|
|
|
|
|
|
include_directories(
|
|
|
|
${QT_INCLUDES}
|
|
|
|
${X11_INCLUDES}
|
|
|
|
)
|
|
|
|
|
|
|
|
SET(X11_QT_HEADERS
|
|
|
|
${CURRENT_HEADER_DIR}/X11Grabber.h
|
|
|
|
)
|
|
|
|
|
|
|
|
SET(X11_HEADERS
|
|
|
|
${CURRENT_HEADER_DIR}/X11Grabber.h
|
|
|
|
)
|
|
|
|
|
|
|
|
SET(X11_SOURCES
|
|
|
|
${CURRENT_SOURCE_DIR}/X11Grabber.cpp
|
|
|
|
)
|
|
|
|
|
2016-01-06 17:31:23 +01:00
|
|
|
if(ENABLE_QT5)
|
|
|
|
QT5_WRAP_CPP(X11_HEADERS_MOC ${X11_QT_HEADERS})
|
|
|
|
else(ENABLE_QT5)
|
2014-11-21 21:24:33 +01:00
|
|
|
QT4_WRAP_CPP(X11_HEADERS_MOC ${X11_QT_HEADERS})
|
2016-01-06 17:31:23 +01:00
|
|
|
endif(ENABLE_QT5)
|
2014-11-21 21:24:33 +01:00
|
|
|
|
|
|
|
add_library(x11-grabber
|
|
|
|
${X11_HEADERS}
|
|
|
|
${X11_SOURCES}
|
|
|
|
${X11_QT_HEADERS}
|
|
|
|
${X11_HEADERS_MOC}
|
|
|
|
)
|
|
|
|
|
|
|
|
target_link_libraries(x11-grabber
|
|
|
|
hyperion
|
|
|
|
${QT_LIBRARIES}
|
|
|
|
)
|