Make QtWebEngine an optional requirement
authorPino Toscano <pino@debian.org>
Sat, 16 Jan 2021 15:49:46 +0000 (15:49 +0000)
committerPino Toscano <pino@debian.org>
Sat, 16 Jan 2021 15:49:46 +0000 (15:49 +0000)
Forwarded: no
Last-Update: 2021-01-16

This makes it possible to build kaccount-provides, albeith without the
nextcloud plugin, also on architectures that do not have QtWebEngine.

Gbp-Pq: Name optional-qtwebengine.diff

CMakeLists.txt
plugins/CMakeLists.txt

index 1c16b4d958e8e0b7d83f4047fb82f53702b1a17b..0e33cc643f0478b8c1586f11907f95ad9fdb4860 100644 (file)
@@ -19,7 +19,8 @@ set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake/modules" ${ECM_MODULE_P
 find_package(Intltool REQUIRED)
 find_package(KAccounts REQUIRED)
 
-find_package(Qt5 ${QT_REQUIRED_VERSION} CONFIG REQUIRED Core Qml WebEngine)
+find_package(Qt5 ${QT_REQUIRED_VERSION} CONFIG REQUIRED Core Qml)
+find_package(Qt5WebEngine ${QT_REQUIRED_VERSION} CONFIG)
 find_package(KF5 ${KF5_MIN_VERSION} REQUIRED KIO I18n Declarative Package)
 
 include(KDEInstallDirs)
index 3ea18172a071c5c0a27263d57ca1111f71224cd4..b95291c9599067be95a721c85d6861a61c2cb58b 100644 (file)
@@ -1,2 +1,4 @@
 add_subdirectory(owncloud-ui)
-add_subdirectory(nextcloud-ui)
\ No newline at end of file
+if (Qt5WebEngine_FOUND)
+  add_subdirectory(nextcloud-ui)
+endif()