-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
38 lines (32 loc) · 1.03 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
cmake_minimum_required(VERSION 3.0)
set(CMAKE_INCLUDE_CURRENT_DIR ON)
set(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake)
set(CMAKE_CXX_STANDARD 11)
project(qepicspv)
set(VERSION 1.0)
find_package(EPICS COMPONENTS ca REQUIRED)
include_directories(${EPICS_INCLUDE_DIRS})
link_directories(${EPICS_LIB_DIR})
set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTOUIC ON)
set(CMAKE_AUTORCC ON)
find_package(Qt5 COMPONENTS Widgets REQUIRED)
include_directories(${Qt5Widgets_INCLUDE_DIRS})
add_subdirectory(qtpv)
add_subdirectory(qtpvwidgets)
find_package(Python3 MODULE COMPONENTS Interpreter Development)
find_package(PyQt5)
find_package(SIP)
if(POLICY CMP0071)
cmake_policy(SET CMP0071 OLD) # use MACOSX_RPATH
endif()
if (Python3_FOUND AND PYQT5_FOUND AND SIP_FOUND)
include(SIPMacros)
include_directories(${SIP_INCLUDE_DIR})
set(SIP_INCLUDES ${PYQT5_SIP_DIR})
set(SIP_EXTRA_OPTIONS ${PYQT5_SIP_FLAGS})
separate_arguments(PYQT5_SIP_FLAGS)
add_subdirectory(qtpvwidgets_py)
else()
message(WARNING "Python module will not be built: SIP is missing.")
endif()