Warning, /plasma/plasma-mobile/CMakeLists.txt is written in an unsupported language. File is not indexed.

0001 # SPDX-FileCopyrightText: 2014-2020 Marco Martin <mart@kde.org>
0002 # SPDX-FileCopyrightText: 2017-2021 Bhushan Shah <bshah@kde.org>
0003 # SPDX-FileCopyrightText: 2019-2021 Nicolas Fella <nicolas.fella@kde.org>
0004 # SPDX-FileCopyrightText: 2022 Devin Lin <devin@kde.org>
0005 # SPDX-License-Identifier: GPL-2.0-or-later
0006 
0007 cmake_minimum_required(VERSION 3.16)
0008 
0009 project(plasma-mobile)
0010 set(PROJECT_VERSION "5.27.10")
0011 set(PROJECT_VERSION_MAJOR 5)
0012 
0013 set(QT_MIN_VERSION "5.15.2")
0014 set(KF5_MIN_VERSION "5.102.0")
0015 set(KDE_COMPILERSETTINGS_LEVEL "5.82")
0016 
0017 set(CMAKE_CXX_STANDARD 17)
0018 set(CMAKE_CXX_STANDARD_REQUIRED ON)
0019 
0020 find_package(ECM ${KF5_MIN_VERSION} REQUIRED NO_MODULE)
0021 set(CMAKE_MODULE_PATH ${ECM_MODULE_PATH})
0022 
0023 set(KF_IGNORE_PLATFORM_CHECK ON CACHE BOOL "Don't check platform that is being built on")
0024 
0025 option(QUICK_COMPILER "Use QtQuick compiler to improve performance" TRUE)
0026 
0027 include(KDEInstallDirs)
0028 include(KDECMakeSettings)
0029 include(KDECompilerSettings NO_POLICY_SCOPE)
0030 include(ECMOptionalAddSubdirectory)
0031 include(ECMInstallIcons)
0032 include(ECMSetupVersion)
0033 include(ECMMarkNonGuiExecutable)
0034 include(ECMGenerateHeaders)
0035 include(ECMQMLModules)
0036 include(ECMGenerateQmlTypes)
0037 include(ECMFindQmlModule)
0038 include(GenerateExportHeader)
0039 include(KDEGitCommitHooks)
0040 include(KDEClangFormat)
0041 include(FeatureSummary)
0042 
0043 add_definitions(-DQT_NO_URL_CAST_FROM_STRING)
0044 
0045 find_package(Qt${QT_MAJOR_VERSION} ${QT_MIN_VERSION} CONFIG REQUIRED
0046     Core
0047     Qml
0048     Quick
0049 )
0050 if (QT_MAJOR_VERSION STREQUAL "5")
0051     if (QUICK_COMPILER)
0052         find_package(Qt${QT_MAJOR_VERSION} ${QT_MIN_VERSION} CONFIG REQUIRED QuickCompiler)
0053     endif()
0054 endif()
0055 
0056 find_package(KF5 ${KF5_MIN_VERSION} REQUIRED COMPONENTS
0057     I18n
0058     KIO
0059     Plasma
0060     PlasmaQuick
0061     Service
0062     Notifications
0063     Wayland
0064     ModemManagerQt
0065     NetworkManagerQt
0066     KCMUtils
0067     Declarative
0068 )
0069 find_package(KF5KirigamiAddons 0.6 REQUIRED)
0070 
0071 find_package(LibKWorkspace CONFIG REQUIRED)
0072 
0073 find_package(KWinDBusInterface)
0074 set_package_properties(KWinDBusInterface PROPERTIES DESCRIPTION "KWin DBus interface"
0075     TYPE REQUIRED
0076     PURPOSE "Needed for virtual keyboard toggle button"
0077 )
0078 
0079 include(CheckIncludeFiles)
0080 
0081 ecm_find_qmlmodule(org.kde.pipewire 0.1)
0082 
0083 plasma_install_package(look-and-feel org.kde.plasma.phone look-and-feel)
0084 plasma_install_package(shell org.kde.plasma.phoneshell shells)
0085 
0086 install(FILES plasma_phone_components.notifyrc DESTINATION ${KDE_INSTALL_KNOTIFYRCDIR})
0087 
0088 add_subdirectory(bin)
0089 add_subdirectory(containments)
0090 add_subdirectory(components)
0091 add_subdirectory(quicksettings)
0092 add_subdirectory(kcms)
0093 
0094 find_program(PlasmaOpenSettings plasma-open-settings)
0095 set_package_properties(PlasmaOpenSettings PROPERTIES
0096                                           URL https://invent.kde.org/plasma/kde-cli-tools/
0097                                           DESCRIPTION "Opens KCMs properly"
0098                                           TYPE RUNTIME
0099                                           PURPOSE "Used on the top panel")
0100 
0101 feature_summary(WHAT ALL INCLUDE_QUIET_PACKAGES FATAL_ON_MISSING_REQUIRED_PACKAGES)
0102 
0103 # add clang-format target for all our real source files
0104 file(GLOB_RECURSE ALL_CLANG_FORMAT_SOURCE_FILES *.cpp *.h)
0105 kde_clang_format(${ALL_CLANG_FORMAT_SOURCE_FILES})
0106 kde_configure_git_pre_commit_hook(CHECKS CLANG_FORMAT)
0107 
0108 ki18n_install(po)