-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathCMakeLists.txt
84 lines (68 loc) · 1.92 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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
cmake_minimum_required(VERSION 3.16)
project(Disman VERSION 0.602.80)
set(QT_MIN_VERSION "6.4.0")
set(KF6_MIN_VERSION "5.240.0")
set(KDE_COMPILERSETTINGS_LEVEL "5.84")
find_package(ECM ${KF6_MIN_VERSION} REQUIRED NO_MODULE)
set(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake/modules ${ECM_MODULE_PATH})
include(KDEInstallDirs)
include(KDECMakeSettings)
include(KDECompilerSettings NO_POLICY_SCOPE)
include(ECMSetupVersion)
include(ECMMarkAsTest)
include(ECMQtDeclareLoggingCategory)
include(FeatureSummary)
include(CMakePackageConfigHelpers)
include(GenerateExportHeader)
# That is the common minimum version. Individual targets might require up to C++17 though.
set(CMAKE_CXX_STANDARD 11)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_CXX_EXTENSIONS OFF)
set(CMAKE_CXX_VISIBILITY_PRESET hidden)
find_package(Qt6 ${QT_MIN_VERSION} CONFIG REQUIRED
COMPONENTS
Core
DBus
Gui
Test
)
find_package(KF6 ${KF6_MIN_VERSION} COMPONENTS
CoreAddons
Wayland
)
set_package_properties(KF6CoreAddons PROPERTIES
TYPE REQUIRED
PURPOSE "For loading Wayland backend plugins"
)
set_package_properties(KF6Wayland PROPERTIES
TYPE OPTIONAL
PURPOSE "Required for KWin/KWayland backend"
)
find_package(Wrapland ${PROJECT_VERSION} CONFIG)
set_package_properties(Wrapland PROPERTIES
TYPE OPTIONAL
PURPOSE "Required for KWinFT and wlroots backends"
)
find_package(XCB COMPONENTS XCB RANDR)
set_package_properties(XCB PROPERTIES
TYPE OPTIONAL
PURPOSE "Required for X11/RandR backend"
)
add_subdirectory(lib)
add_subdirectory(service)
add_subdirectory(ctl)
add_subdirectory(backends)
if(BUILD_TESTING)
add_subdirectory(autotests)
add_subdirectory(tests)
endif()
add_custom_target(disman DEPENDS
disman::lib
disman::wllib
dismanctl
disman-launcher
disman-wayland
)
install(FILES disman.categories DESTINATION ${KDE_INSTALL_LOGGINGCATEGORIESDIR})
feature_summary(WHAT ALL FATAL_ON_MISSING_REQUIRED_PACKAGES)
include(Packing)