summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>2023-03-06 14:37:17 +0100
committerEskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>2023-03-06 14:56:32 +0100
commit83599e16789f945ef15954f2a2aabb37b245e596 (patch)
treee5cc2f2c595d9f06d83f66c36f5177b83db03fae
parenta53f022393a1276dbf8eccbae04cb0bd6cea0160 (diff)
downloadqtwayland-83599e16789f945ef15954f2a2aabb37b245e596.tar.gz
Compile with -no-opengl
A few of the tests were including Qt OpenGL for no good reason, and the link step should be optional. Pick-to: 6.2 6.5 6.5.0 Fixes: QTBUG-110420 Change-Id: Icb78c15e49070c6938bf9bb75abfed677af6785b Reviewed-by: Inho Lee <inho.lee@qt.io> Reviewed-by: David Edmundson <davidedmundson@kde.org>
-rw-r--r--tests/auto/client/datadevicev1/tst_datadevicev1.cpp1
-rw-r--r--tests/auto/client/primaryselectionv1/tst_primaryselectionv1.cpp1
-rw-r--r--tests/auto/client/scaling/tst_scaling.cpp1
-rw-r--r--tests/auto/client/seat/tst_seat.cpp1
-rw-r--r--tests/auto/client/seatv4/tst_seatv4.cpp1
-rw-r--r--tests/auto/client/seatv7/tst_seatv7.cpp1
-rw-r--r--tests/auto/client/shared/CMakeLists.txt6
-rw-r--r--tests/auto/client/xdgdecorationv1/tst_xdgdecorationv1.cpp1
-rw-r--r--tests/auto/client/xdgoutput/tst_xdgoutput.cpp1
-rw-r--r--tests/auto/client/xdgshell/tst_xdgshell.cpp1
10 files changed, 5 insertions, 10 deletions
diff --git a/tests/auto/client/datadevicev1/tst_datadevicev1.cpp b/tests/auto/client/datadevicev1/tst_datadevicev1.cpp
index d78255e9..cdbf7379 100644
--- a/tests/auto/client/datadevicev1/tst_datadevicev1.cpp
+++ b/tests/auto/client/datadevicev1/tst_datadevicev1.cpp
@@ -3,7 +3,6 @@
#include "mockcompositor.h"
-#include <QtOpenGL/QOpenGLWindow>
#include <QtGui/QRasterWindow>
#include <QtGui/QClipboard>
#include <QtGui/QDrag>
diff --git a/tests/auto/client/primaryselectionv1/tst_primaryselectionv1.cpp b/tests/auto/client/primaryselectionv1/tst_primaryselectionv1.cpp
index 558e4676..b9e12873 100644
--- a/tests/auto/client/primaryselectionv1/tst_primaryselectionv1.cpp
+++ b/tests/auto/client/primaryselectionv1/tst_primaryselectionv1.cpp
@@ -5,7 +5,6 @@
#include <qwayland-server-wp-primary-selection-unstable-v1.h>
-#include <QtOpenGL/QOpenGLWindow>
#include <QtGui/QRasterWindow>
#include <QtGui/QClipboard>
#include <QtCore/private/qcore_unix_p.h>
diff --git a/tests/auto/client/scaling/tst_scaling.cpp b/tests/auto/client/scaling/tst_scaling.cpp
index bceea92d..f94c37cc 100644
--- a/tests/auto/client/scaling/tst_scaling.cpp
+++ b/tests/auto/client/scaling/tst_scaling.cpp
@@ -2,7 +2,6 @@
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
#include "mockcompositor.h"
-#include <QtOpenGL/QOpenGLWindow>
#include <QtGui/QRasterWindow>
#include <QtGui/qpa/qplatformnativeinterface.h>
#include <QtWaylandClient/private/wayland-wayland-client-protocol.h>
diff --git a/tests/auto/client/seat/tst_seat.cpp b/tests/auto/client/seat/tst_seat.cpp
index 8a9375d6..9db10d55 100644
--- a/tests/auto/client/seat/tst_seat.cpp
+++ b/tests/auto/client/seat/tst_seat.cpp
@@ -2,7 +2,6 @@
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
#include "mockcompositor.h"
-#include <QtOpenGL/QOpenGLWindow>
#include <QtGui/QRasterWindow>
#include <QtGui/QEventPoint>
diff --git a/tests/auto/client/seatv4/tst_seatv4.cpp b/tests/auto/client/seatv4/tst_seatv4.cpp
index 314569a1..8d78c2b3 100644
--- a/tests/auto/client/seatv4/tst_seatv4.cpp
+++ b/tests/auto/client/seatv4/tst_seatv4.cpp
@@ -3,7 +3,6 @@
#include "mockcompositor.h"
-#include <QtOpenGL/QOpenGLWindow>
#include <QtGui/QRasterWindow>
#if QT_CONFIG(cursor)
#include <wayland-cursor.h>
diff --git a/tests/auto/client/seatv7/tst_seatv7.cpp b/tests/auto/client/seatv7/tst_seatv7.cpp
index c341ec96..e423456c 100644
--- a/tests/auto/client/seatv7/tst_seatv7.cpp
+++ b/tests/auto/client/seatv7/tst_seatv7.cpp
@@ -2,7 +2,6 @@
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
#include "mockcompositor.h"
-#include <QtOpenGL/QOpenGLWindow>
#include <QtGui/QRasterWindow>
#include <QtGui/QEventPoint>
diff --git a/tests/auto/client/shared/CMakeLists.txt b/tests/auto/client/shared/CMakeLists.txt
index 8112ffb7..a1f150c2 100644
--- a/tests/auto/client/shared/CMakeLists.txt
+++ b/tests/auto/client/shared/CMakeLists.txt
@@ -53,10 +53,14 @@ qt6_generate_wayland_protocol_server_sources(SharedClientTest
${PROJECT_SOURCE_DIR}/src/3rdparty/protocol/xdg-shell.xml
)
+if(QT_FEATURE_opengl)
+ set(optional_libraries Qt::OpenGL)
+endif()
+
target_link_libraries(SharedClientTest
PUBLIC
Qt::Gui
- Qt::OpenGL
+ ${optional_libraries}
Qt::WaylandClientPrivate
Wayland::Server
Threads::Threads # special case
diff --git a/tests/auto/client/xdgdecorationv1/tst_xdgdecorationv1.cpp b/tests/auto/client/xdgdecorationv1/tst_xdgdecorationv1.cpp
index 8adc9dd0..ba91514d 100644
--- a/tests/auto/client/xdgdecorationv1/tst_xdgdecorationv1.cpp
+++ b/tests/auto/client/xdgdecorationv1/tst_xdgdecorationv1.cpp
@@ -5,7 +5,6 @@
#include <qwayland-server-xdg-decoration-unstable-v1.h>
-#include <QtOpenGL/QOpenGLWindow>
#include <QtGui/QRasterWindow>
#include <QtGui/QClipboard>
#include <QtCore/private/qcore_unix_p.h>
diff --git a/tests/auto/client/xdgoutput/tst_xdgoutput.cpp b/tests/auto/client/xdgoutput/tst_xdgoutput.cpp
index ea8719f1..bb104dd5 100644
--- a/tests/auto/client/xdgoutput/tst_xdgoutput.cpp
+++ b/tests/auto/client/xdgoutput/tst_xdgoutput.cpp
@@ -4,7 +4,6 @@
#include "xdgoutputv1.h"
#include "mockcompositor.h"
-#include <QtOpenGL/QOpenGLWindow>
#include <QtGui/QRasterWindow>
#include <QtGui/QScreen>
diff --git a/tests/auto/client/xdgshell/tst_xdgshell.cpp b/tests/auto/client/xdgshell/tst_xdgshell.cpp
index efaa6a8f..101baecc 100644
--- a/tests/auto/client/xdgshell/tst_xdgshell.cpp
+++ b/tests/auto/client/xdgshell/tst_xdgshell.cpp
@@ -2,7 +2,6 @@
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
#include "mockcompositor.h"
-#include <QtOpenGL/QOpenGLWindow>
#include <QtGui/QRasterWindow>
#include <QtGui/qpa/qplatformnativeinterface.h>
#include <QtWaylandClient/private/wayland-wayland-client-protocol.h>