-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
41 lines (33 loc) · 1.01 KB
/
CMakeLists.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
cmake_minimum_required(VERSION 3.26)
project(rtsp-viewer-widget)
set(CMAKE_CXX_STANDARD 20)
set(CMAKE_CXX_STANDARD_REQUIRED True)
set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTORCC ON)
set(CMAKE_AUTOUIC ON)
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
set(IPCAM_QT_PREFIX_PATH "C:/Qt/6.5.2/msvc2019_64" CACHE STRING "Prefix path to Qt 6.5.2 installation")
set(IPCAM_GST_PREFIX_PATH "C:/gstreamer/1.0/msvc_x86_64" CACHE STRING "Prefix path to GStreamer 1.22.5 installation")
set(CMAKE_PREFIX_PATH
${IPCAM_QT_PREFIX_PATH}
${IPCAM_GST_PREFIX_PATH}
)
find_package(Qt6 COMPONENTS
Core
Gui
Widgets
REQUIRED
)
# use FindGStreamer.cmake from Qt prefix path
find_package(GStreamer REQUIRED)
add_executable(App)
target_link_libraries(App PRIVATE
Qt::Core
Qt::Gui
Qt::Widgets
GStreamer::GStreamer
)
target_include_directories(App PRIVATE Sources)
add_subdirectory(Sources)