Fix building with disabled OpenGL after switching to the syncqt tool

After switching qtbase to use the syncqt tool (in
b89d63515b), these OpenGL specific
headers aren't available at all, when the build is configured
to not use OpenGL.

In one case, add a missing check for QT_NO_OPENGL, and in another
case, include the necessary <QtGui/qtgui-config.h> header to
make the potential QT_NO_OPENGL define available, to make a
preexisting ifdef actually do what it was meant to do.

Change-Id: Ie12deff2eee8e3b59193175551fbb28b7480f1f8
Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
This commit is contained in:
Martin Storsjö 2022-09-29 10:39:07 +03:00
parent 42b66bd809
commit 11be4c5ce8
2 changed files with 3 additions and 0 deletions

View File

@ -10,7 +10,9 @@
#include <qpa/qplatformintegration.h>
#include <QtCore/qscopedpointer.h>
#include <QtGui/private/qwindowsfontdatabase_p.h>
#ifndef QT_NO_OPENGL
#include <QtGui/private/qopenglcontext_p.h>
#endif
#include <qpa/qplatformopenglcontext.h>
QT_BEGIN_NAMESPACE

View File

@ -15,6 +15,7 @@
#include <QtCore/qlibraryinfo.h>
#include <QtCore/qhash.h>
#include <private/qsystemlibrary_p.h>
#include <QtGui/qtgui-config.h>
#ifndef QT_NO_OPENGL
#include <private/qopengl_p.h>