-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCMakeLists.txt
30 lines (20 loc) · 1001 Bytes
/
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
project(qtpropertybrowser)
cmake_minimum_required(VERSION 3.5)
include(GenerateExportHeader)
find_package(Qt5Core REQUIRED)
find_package(Qt5Gui REQUIRED)
find_package(Qt5Widgets REQUIRED)
# Instruct CMake to run moc automatically when needed.
set(CMAKE_AUTOMOC ON)
file(GLOB QTPROPERTYBROWSER_SOURCES src/qtpropertybrowser/*.cpp)
file(GLOB QTPROPERTYBROWSER_HEADERS src/qtpropertybrowser/*.h)
add_library(qtpropertybrowser SHARED ${QTPROPERTYBROWSER_SOURCES} ${QTPROPERTYBROWSER_HEADERS})
generate_export_header(qtpropertybrowser)
set_property(TARGET qtpropertybrowser PROPERTY WINDOWS_EXPORT_ALL_SYMBOLS ON)
target_link_libraries(qtpropertybrowser PRIVATE Qt5::Widgets)
target_include_directories(qtpropertybrowser INTERFACE src)
target_include_directories(qtpropertybrowser INTERFACE ${CMAKE_CURRENT_BINARY_DIR})
install(TARGETS qtpropertybrowser DESTINATION lib)
if(PREON_RPATH_SAMEDIR)
set_target_properties(qtpropertybrowser PROPERTIES INSTALL_RPATH ${PREON_RPATH_SAMEDIR})
endif()