summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/hardwareintegration/client/brcm-egl/brcm-egl.pri2
-rw-r--r--src/hardwareintegration/client/brcm-egl/qwaylandbrcmglcontext.cpp9
-rw-r--r--src/hardwareintegration/client/brcm-egl/qwaylandbrcmglcontext.h2
3 files changed, 10 insertions, 3 deletions
diff --git a/src/hardwareintegration/client/brcm-egl/brcm-egl.pri b/src/hardwareintegration/client/brcm-egl/brcm-egl.pri
index 64cb44677..3961f4f1e 100644
--- a/src/hardwareintegration/client/brcm-egl/brcm-egl.pri
+++ b/src/hardwareintegration/client/brcm-egl/brcm-egl.pri
@@ -3,6 +3,8 @@ INCLUDEPATH += $$PWD
QMAKE_USE += egl wayland-client
QT += egl_support-private
+LIBS_PRIVATE += $$QMAKE_LIBS_DYNLOAD
+
SOURCES += $$PWD/qwaylandbrcmeglintegration.cpp \
$$PWD/qwaylandbrcmglcontext.cpp \
$$PWD/qwaylandbrcmeglwindow.cpp
diff --git a/src/hardwareintegration/client/brcm-egl/qwaylandbrcmglcontext.cpp b/src/hardwareintegration/client/brcm-egl/qwaylandbrcmglcontext.cpp
index f5480b0ed..5c585746c 100644
--- a/src/hardwareintegration/client/brcm-egl/qwaylandbrcmglcontext.cpp
+++ b/src/hardwareintegration/client/brcm-egl/qwaylandbrcmglcontext.cpp
@@ -48,6 +48,8 @@
#include <qpa/qplatformopenglcontext.h>
#include <QtGui/QSurfaceFormat>
+#include <dlfcn.h>
+
QT_BEGIN_NAMESPACE
namespace QtWaylandClient {
@@ -92,9 +94,12 @@ void QWaylandBrcmGLContext::swapBuffers(QPlatformSurface *surface)
static_cast<QWaylandBrcmEglWindow *>(surface)->swapBuffers();
}
-void (*QWaylandBrcmGLContext::getProcAddress(const char *procName)) ()
+QFunctionPointer QWaylandBrcmGLContext::getProcAddress(const char *procName)
{
- return eglGetProcAddress(procName);
+ QFunctionPointer proc = (QFunctionPointer) eglGetProcAddress(procName);
+ if (!proc)
+ proc = (QFunctionPointer) dlsym(RTLD_DEFAULT, procName);
+ return proc;
}
EGLConfig QWaylandBrcmGLContext::eglConfig() const
diff --git a/src/hardwareintegration/client/brcm-egl/qwaylandbrcmglcontext.h b/src/hardwareintegration/client/brcm-egl/qwaylandbrcmglcontext.h
index a79cfcc68..7a1475e71 100644
--- a/src/hardwareintegration/client/brcm-egl/qwaylandbrcmglcontext.h
+++ b/src/hardwareintegration/client/brcm-egl/qwaylandbrcmglcontext.h
@@ -63,7 +63,7 @@ public:
bool makeCurrent(QPlatformSurface *surface) Q_DECL_OVERRIDE;
void doneCurrent() Q_DECL_OVERRIDE;
- void (*getProcAddress(const char *procName)) () Q_DECL_OVERRIDE;
+ QFunctionPointer getProcAddress(const char *procName) Q_DECL_OVERRIDE;
QSurfaceFormat format() const Q_DECL_OVERRIDE { return m_format; }