-
Notifications
You must be signed in to change notification settings - Fork 1
/
CMakeLists.txt
54 lines (43 loc) · 1.09 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
42
43
44
45
46
47
48
49
50
51
52
53
54
cmake_minimum_required(VERSION 3.7)
set(VERSION 1.0)
set(BIN_NAME qeyes)
project(${BIN_NAME})
#set(CMAKE_VERBOSE_MAKEFILE ON)
set(CMAKE_INCLUDE_CURRENT_DIR ON)
set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTORCC ON)
set(CMAKE_CXX_FLAGS "-g -Wall")
set(CMAKE_INSTALL_PREFIX /usr)
# Sources files
set(SRCS main.cpp
common.h
qeyes.h
qeyes.cpp
cursorpostionmonitor.h
cursorpostionmonitor.cpp
)
# Find the library
find_package(PkgConfig REQUIRED)
find_package(Qt5Widgets REQUIRED)
find_package(Qt5X11Extras REQUIRED)
find_package(DtkWidget REQUIRED)
pkg_check_modules(X11 REQUIRED x11)
pkg_check_modules(XI REQUIRED xi)
add_executable(${BIN_NAME} ${SRCS})
target_include_directories(${BIN_NAME} PUBLIC
${Qt5Widgets_INCLUDE_DIRS}
${Qt5X11Extras_INCLUDE_DIRS}
${DtkWidget_INCLUDE_DIRS}
${X11_INCLUDE_DIRS}
${XI_INCLUDE_DIRS}
)
target_link_libraries(${BIN_NAME} PUBLIC
${Qt5Widgets_LIBRARIES}
${Qt5X11Extras_LIBRARIES}
${DtkWidget_LIBRARIES}
${X11_LIBRARIES}
${XI_LIBRARIES}
)
add_subdirectory("dde-dock-qeyes-plugin")
# bin
install(TARGETS ${BIN_NAME} DESTINATION bin)