mirror of
https://github.com/Sani7/remote-ui.git
synced 2026-10-27 06:01:14 +01:00
50 lines
1.2 KiB
CMake
50 lines
1.2 KiB
CMake
find_package(QT NAMES Qt6 REQUIRED COMPONENTS Widgets Svg Protobuf Grpc)
|
|
find_package(Qt${QT_VERSION_MAJOR} REQUIRED COMPONENTS Widgets Svg Protobuf Grpc)
|
|
|
|
include_directories(${CMAKE_CURRENT_SOURCE_DIR})
|
|
|
|
file(GLOB_RECURSE ui "ui/*")
|
|
file(GLOB_RECURSE sims "simulators/*")
|
|
|
|
set(PROJECT_SOURCES
|
|
${ui}
|
|
${sims}
|
|
IterableEnum.hpp
|
|
main.cpp
|
|
mainwindow.cpp
|
|
mainwindow.hpp
|
|
mainwindow.ui
|
|
factory.hpp
|
|
helpers.cpp
|
|
helpers.hpp
|
|
ui_base.cpp
|
|
ui_base.hpp
|
|
)
|
|
|
|
qt_add_executable(unisim_client
|
|
${PROJECT_SOURCES}
|
|
)
|
|
|
|
set_target_properties(
|
|
unisim_client
|
|
PROPERTIES
|
|
AUTOMOC ON
|
|
AUTOUIC ON
|
|
)
|
|
|
|
target_include_directories(unisim_client
|
|
PUBLIC
|
|
${CMAKE_CURRENT_LIST_DIR}
|
|
${CMAKE_CURRENT_LIST_DIR}/ui
|
|
${CMAKE_CURRENT_LIST_DIR}/simulators
|
|
${PROJECT_BINARY_DIR}/
|
|
)
|
|
|
|
target_link_libraries(unisim_client PUBLIC Qt${QT_VERSION_MAJOR}::Widgets Qt${QT_VERSION_MAJOR}::Protobuf Qt${QT_VERSION_MAJOR}::Grpc spdlog magic_enum::magic_enum qwt git_tag proto-ui-client)
|
|
|
|
include(GNUInstallDirs)
|
|
install(TARGETS unisim_client
|
|
BUNDLE DESTINATION .
|
|
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
|
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
|
|
) |