File: CMakeLists.txt

package info (click to toggle)
kde-gtk-config 4%3A6.3.4-1
  • links: PTS, VCS
  • area: main
  • in suites: sid, trixie
  • size: 620 kB
  • sloc: cpp: 2,272; ansic: 188; sh: 24; xml: 7; makefile: 5
file content (73 lines) | stat: -rw-r--r-- 2,389 bytes parent folder | download
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
cmake_minimum_required(VERSION 3.16)

project(kde-gtk-config)
set(PROJECT_VERSION "6.3.4")

set(QT_MIN_VERSION "6.7.0")
set(KF6_MIN_VERSION "6.10.0")
set(KDE_COMPILERSETTINGS_LEVEL "5.82")

set(CMAKE_CXX_STANDARD 20)
set(CMAKE_CXX_STANDARD_REQUIRED ON)

find_package(ECM ${KF6_MIN_VERSION} REQUIRED NO_MODULE)
set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake/modules" ${ECM_MODULE_PATH})

include(ECMSetupVersion)
include(ECMInstallIcons)
include(ECMMarkAsTest)
include(GenerateExportHeader)
include(FeatureSummary)
include(KDEInstallDirs)
include(KDECMakeSettings)
include(KDECompilerSettings NO_POLICY_SCOPE)
include(KDEClangFormat)
include(KDEGitCommitHooks)
include(ECMQtDeclareLoggingCategory)

find_package(Qt6 ${QT_MIN_VERSION} REQUIRED NO_MODULE COMPONENTS DBus Svg)
find_package(KF6 ${KF6_MIN_VERSION} REQUIRED COMPONENTS ColorScheme CoreAddons Config GuiAddons DBusAddons WindowSystem)
find_package(PkgConfig REQUIRED)
find_package(KDecoration3 REQUIRED)
find_package(GSettingSchemas REQUIRED)
find_package(Sass REQUIRED)
find_package(XSettingsd)

pkg_check_modules(GTK+3 REQUIRED IMPORTED_TARGET gtk+-3.0)
pkg_check_modules(GLib2 REQUIRED IMPORTED_TARGET glib-2.0)
pkg_check_modules(GObject REQUIRED IMPORTED_TARGET gobject-2.0)
pkg_check_modules(GIO REQUIRED IMPORTED_TARGET gio-2.0)


set_package_properties(XSettingsd PROPERTIES
    DESCRIPTION "XSettingsd daemon"
    TYPE RUNTIME
    PURPOSE "Required to apply settings to GTK applications on the fly"
)

set_package_properties(Sass PROPERTIES
    DESCRIPTION "SASS compiler"
    URL "https://sass-lang.com/"
    PURPOSE "Required for building a modification, that allows Breeze GTK to change it's window decorations' appearance"
)

configure_file(${CMAKE_CURRENT_SOURCE_DIR}/config.h.cmake kded/config.h)

add_subdirectory(gtk3proxies)
add_subdirectory(kded)
add_subdirectory(kconf_update)
add_subdirectory(color-reload-module)
add_subdirectory(window-decorations-reload-module)

ecm_qt_install_logging_categories(
    EXPORT KDE_GTK_CONFIG
    FILE kde-gtk-config.categories
    DESTINATION ${KDE_INSTALL_LOGGINGCATEGORIESDIR}
)

# add clang-format target for all our real source files
file(GLOB_RECURSE ALL_CLANG_FORMAT_SOURCE_FILES *.cpp *.h)
kde_clang_format(${ALL_CLANG_FORMAT_SOURCE_FILES})
kde_configure_git_pre_commit_hook(CHECKS CLANG_FORMAT)

feature_summary(WHAT ALL FATAL_ON_MISSING_REQUIRED_PACKAGES)