SmartLockerTools/Analyser/CMakeLists.txt
2024-06-13 15:41:40 +08:00

65 lines
1.6 KiB
CMake

set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTORCC ON)
find_package(QT NAMES Qt6 Qt5 REQUIRED COMPONENTS Quick QuickTemplates2 Widgets SerialPort)
find_package(Qt${QT_VERSION_MAJOR} REQUIRED COMPONENTS Quick QuickTemplates2 Widgets SerialPort)
add_executable(Analyser Analyser.rc
main.cpp
Application.h Application.cpp
CategoryLogSinkBackend.h CategoryLogSinkBackend.cpp
Widget.h Widget.cpp
ModuleCommunication.h ModuleCommunication.cpp
PalmFeatureTableModel.h PalmFeatureTableModel.cpp
VideoFrameProvider.h VideoFrameProvider.cpp
VideoPlayer.h VideoPlayer.cpp
)
qt_add_qml_module(Analyser
URI Analyser
VERSION 1.0
QML_FILES
qml/main.qml
qml/ConnectionItem.qml
qml/OperationItem.qml
qml/StatusTip.qml
RESOURCES
resources/successfull.svg
resources/warning.svg
)
target_compile_definitions(Analyser
PRIVATE _CRT_SECURE_NO_WARNINGS
)
if(CMAKE_BUILD_TYPE STREQUAL "Release")
set_property(TARGET Analyser PROPERTY
WIN32_EXECUTABLE true
)
endif()
target_include_directories(Analyser
PRIVATE ${FFmpeg_INCLUDE_DIR}
)
target_link_directories(Analyser
PRIVATE ${FFmpeg_LIB_DIR}
)
target_link_libraries(Analyser
PRIVATE QtComponets
PRIVATE Encrypt
PRIVATE Database
PRIVATE Ws2_32
PRIVATE Peripheral
PRIVATE avcodec
PRIVATE swscale
PRIVATE avutil
PRIVATE avdevice
PRIVATE avformat
PRIVATE Qt${QT_VERSION_MAJOR}::Quick
PRIVATE Qt${QT_VERSION_MAJOR}::QuickTemplates2
PRIVATE Qt${QT_VERSION_MAJOR}::Widgets
PRIVATE Qt${QT_VERSION_MAJOR}::SerialPort
)