diff --git a/plugins/qpa/abstractplatformcontext.cpp b/plugins/qpa/abstractplatformcontext.cpp index 278669e910..b087591fb7 100644 --- a/plugins/qpa/abstractplatformcontext.cpp +++ b/plugins/qpa/abstractplatformcontext.cpp @@ -115,10 +115,17 @@ QSurfaceFormat AbstractPlatformContext::format() const return m_format; } +#if (QT_VERSION < QT_VERSION_CHECK(5, 7, 0)) QFunctionPointer AbstractPlatformContext::getProcAddress(const QByteArray &procName) { return eglGetProcAddress(procName.constData()); } +#else +QFunctionPointer AbstractPlatformContext::getProcAddress(const char *procName) +{ + return eglGetProcAddress(procName); +} +#endif bool AbstractPlatformContext::isValid() const { diff --git a/plugins/qpa/abstractplatformcontext.h b/plugins/qpa/abstractplatformcontext.h index 0eb474e1ce..e654a4232f 100644 --- a/plugins/qpa/abstractplatformcontext.h +++ b/plugins/qpa/abstractplatformcontext.h @@ -39,7 +39,11 @@ public: void doneCurrent() override; QSurfaceFormat format() const override; bool isValid() const override; +#if (QT_VERSION < QT_VERSION_CHECK(5, 7, 0)) QFunctionPointer getProcAddress(const QByteArray &procName) override; +#else + QFunctionPointer getProcAddress(const char *procName) override; +#endif protected: EGLDisplay eglDisplay() const {