2016-05-26 23:44:27 +02:00
|
|
|
# Find the BCM-package (VC control)
|
2022-03-20 14:42:21 +01:00
|
|
|
if( "${PLATFORM}" MATCHES rpi)
|
|
|
|
find_package(BCM)
|
|
|
|
if(BCM_FOUND)
|
|
|
|
add_definitions(-DBCM_FOUND)
|
|
|
|
endif()
|
|
|
|
else()
|
|
|
|
set(BCM_INCLUDE_DIR "")
|
|
|
|
set(BCM_LIBRARY "")
|
|
|
|
endif()
|
2016-05-26 23:44:27 +02:00
|
|
|
|
|
|
|
# Define the current source locations
|
2022-03-20 14:42:21 +01:00
|
|
|
set(CURRENT_HEADER_DIR ${CMAKE_SOURCE_DIR}/include/grabber)
|
|
|
|
set(CURRENT_SOURCE_DIR ${CMAKE_SOURCE_DIR}/libsrc/grabber/dispmanx)
|
2016-05-26 23:44:27 +02:00
|
|
|
|
2017-08-04 23:08:15 +02:00
|
|
|
FILE ( GLOB DispmanxGrabberSOURCES "${CURRENT_HEADER_DIR}/Dispmanx*.h" "${CURRENT_SOURCE_DIR}/*.h" "${CURRENT_SOURCE_DIR}/*.cpp" )
|
2016-05-26 23:44:27 +02:00
|
|
|
|
2022-03-20 14:42:21 +01:00
|
|
|
add_library(dispmanx-grabber ${DispmanxGrabberSOURCES})
|
|
|
|
add_definitions(-DBCM_LIBRARY="${BCM_LIBRARY}")
|
|
|
|
|
|
|
|
target_include_directories(dispmanx-grabber PUBLIC
|
|
|
|
${BCM_INCLUDE_DIR}
|
|
|
|
)
|
2016-05-26 23:44:27 +02:00
|
|
|
|
|
|
|
target_link_libraries(dispmanx-grabber
|
|
|
|
hyperion
|
|
|
|
${QT_LIBRARIES}
|
2022-03-20 14:42:21 +01:00
|
|
|
${CMAKE_DL_LIBS}
|
2016-05-26 23:44:27 +02:00
|
|
|
)
|