-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathCMakeLists.txt
53 lines (43 loc) · 1.11 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
cmake_minimum_required(VERSION 3.16)
cmake_policy(SET CMP0063 NEW)
project(kvkbd)
option(ENABLE_QT6 "Compile with Qt6" OFF)
if(ENABLE_QT6)
set(QT_VERSION 6)
set(KF_VERSION 6)
set(REQUIRED_QT_VERSION 6.6.0)
set(KF_MIN_VERSION 5.240.0)
else()
set(QT_VERSION 5)
set(KF_VERSION 5)
set(REQUIRED_QT_VERSION 5.9.0)
set(KF_MIN_VERSION 5.40.0)
set(qt_add_resources qt5_add_resources)
set(qt_add_dbus_adaptor qt5_add_dbus_adaptor)
endif()
find_package(ECM ${KF_MIN_VERSION} REQUIRED NO_MODULE)
set(CMAKE_MODULE_PATH ${ECM_MODULE_PATH})
include(KDEInstallDirs)
include(KDECMakeSettings)
include(KDECompilerSettings)
include(ECMQtDeclareLoggingCategory)
include(ECMSetupVersion)
if(NOT XDG_APPS_INSTALL_DIR)
set(XDG_APPS_INSTALL_DIR share/applications)
endif()
find_package(Qt${QT_VERSION} ${REQUIRED_QT_VERSION} REQUIRED COMPONENTS
Gui
Core
Widgets
Xml
DBus)
find_package(KF${KF_VERSION} ${KF_MIN_VERSION} REQUIRED COMPONENTS
I18n
Config
CoreAddons
XmlGui
WindowSystem
DocTools)
find_package(LibXslt REQUIRED)
add_subdirectory(doc)
add_subdirectory(src)