blob: 348f56d5e0b443c4691628868eebafc8d1eb8792 (
plain)
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
|
From e5927c7250afd6b715a9de520851b26e41b7f422 Mon Sep 17 00:00:00 2001
From: Andreas Sturmlechner <asturm@gentoo.org>
Date: Wed, 9 Dec 2020 01:28:25 +0100
Subject: [PATCH] Move Qt test dependencies into test dir
Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
---
CMakeLists.txt | 8 ++++----
qt5/CMakeLists.txt | 7 +++++--
qt6/CMakeLists.txt | 6 ++++--
3 files changed, 13 insertions(+), 8 deletions(-)
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -212,15 +212,15 @@
find_soft_mandatory_package(ENABLE_QT5 Qt5Core ${QT5_VERSION})
find_soft_mandatory_package(ENABLE_QT5 Qt5Gui ${QT5_VERSION})
find_soft_mandatory_package(ENABLE_QT5 Qt5Xml ${QT5_VERSION})
-find_soft_mandatory_package(ENABLE_QT5 Qt5Widgets ${QT5_VERSION})
-find_soft_mandatory_package(ENABLE_QT5 Qt5Test ${QT5_VERSION})
+find_soft_mandatory_package(BUILD_QT5_TESTS Qt5Widgets ${QT5_VERSION})
+find_soft_mandatory_package(BUILD_QT5_TESTS Qt5Test ${QT5_VERSION})
set(QT6_VERSION "6.2")
SET(QT_NO_CREATE_VERSIONLESS_TARGETS ON)
find_soft_mandatory_package(ENABLE_QT6 Qt6Core ${QT6_VERSION})
find_soft_mandatory_package(ENABLE_QT6 Qt6Gui ${QT6_VERSION})
-find_soft_mandatory_package(ENABLE_QT6 Qt6Widgets ${QT6_VERSION})
-find_soft_mandatory_package(ENABLE_QT6 Qt6Test ${QT6_VERSION})
+find_soft_mandatory_package(ENABLE_QT6_TESTS Qt6Widgets ${QT6_VERSION})
+find_soft_mandatory_package(ENABLE_QT6_TESTS Qt6Test ${QT6_VERSION})
# Check for Cairo rendering backend
macro_optional_find_package(Cairo ${CAIRO_VERSION})
--- a/qt5/CMakeLists.txt
+++ b/qt5/CMakeLists.txt
@@ -9,5 +9,8 @@
add_definitions(-DQT_NO_DEPRECATED_WARNINGS)
add_subdirectory(src)
-add_subdirectory(tests)
-add_subdirectory(demos)
+
+if(BUILD_QT5_TESTS)
+ add_subdirectory(tests)
+ add_subdirectory(demos)
+endif()
--- a/qt6/CMakeLists.txt
+++ b/qt6/CMakeLists.txt
@@ -7,5 +7,7 @@
add_subdirectory(src)
-add_subdirectory(tests)
-add_subdirectory(demos)
+if(BUILD_QT5_TESTS)
+ add_subdirectory(tests)
+ add_subdirectory(demos)
+endif()
--
2.29.2
|