summaryrefslogtreecommitdiffstats
path: root/src/gui/egl/egl.pri
diff options
context:
space:
mode:
authorTom Cooksey <thomas.cooksey@nokia.com>2009-09-17 09:53:14 (GMT)
committerTom Cooksey <thomas.cooksey@nokia.com>2009-09-17 10:58:55 (GMT)
commit26e5792c84d15ca8fb90c2f3b0ba3a53e52f242d (patch)
tree971e69d7e7de271ce85e134ff4678697763ef47c /src/gui/egl/egl.pri
parent0ca968d2244214b465f1186628328f28caa33886 (diff)
downloadQt-26e5792c84d15ca8fb90c2f3b0ba3a53e52f242d.zip
Qt-26e5792c84d15ca8fb90c2f3b0ba3a53e52f242d.tar.gz
Qt-26e5792c84d15ca8fb90c2f3b0ba3a53e52f242d.tar.bz2
Add a QMAKE_LFLAGS_EGL and QMAKE_LFLAGS_OPENGL
When you link cross-compiled applications on Linux, the linker needs to be able to find not just the libraries the application links against (like libQtGui.so), but the libraries' dependencies. E.g. examples/widgets/wiggly links against QtGui. QtGui links against libEGL.so. Therefore, when you link wiggly, the linker has to be able to find libEGL.so, even though wiggly doesn't use EGL directly. To facilitate this, -Wl,rpath-link=/path/to/egl needs to be added to QMAKE_PRL_LIBS in libQtGui.prl and -Wl,rpath-link=/path/to/gl needs to be added to QMAKE_PRL_LIBS in libQtOpenGL.prl. This only needs to be done when the EGL/GL libs are not in the default search directories. As the paths will also change depending on the mkspec, two new variables have been added: QMAKE_LFLAGS_EGL & QMAKE_LFLAGS_OPENGL. These can be set in the mkspec and will be added to the relevent prls. E.g. QMAKE_LFLAGS_EGL += -Wl,-rpath-link=$${QMAKE_LIBDIR_EGL} QMAKE_LFLAGS_OPENGL += -Wl,-rpath-link=$${QMAKE_LIBDIR_OPENGL} Reviewed-by: Marius Storm-Olsen
Diffstat (limited to 'src/gui/egl/egl.pri')
-rw-r--r--src/gui/egl/egl.pri1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/gui/egl/egl.pri b/src/gui/egl/egl.pri
index 22c8bd7..ba991bd 100644
--- a/src/gui/egl/egl.pri
+++ b/src/gui/egl/egl.pri
@@ -26,3 +26,4 @@ for(p, QMAKE_LIBDIR_EGL) {
!isEmpty(QMAKE_INCDIR_EGL): INCLUDEPATH += $$QMAKE_INCDIR_EGL
!isEmpty(QMAKE_LIBS_EGL): LIBS_PRIVATE += $$QMAKE_LIBS_EGL
+!isEmpty(QMAKE_LFLAGS_EGL): LIBS += $$QMAKE_LFLAGS_EGL