summaryrefslogtreecommitdiffstats
path: root/mkspecs/features
diff options
context:
space:
mode:
authorTrond Kjernåsen <trond@trolltech.com>2009-11-04 11:22:18 (GMT)
committerTrond Kjernåsen <trond@trolltech.com>2009-11-04 11:22:18 (GMT)
commit26ded29b31c71ff43036798015cb1c77aae427e3 (patch)
tree24e91fe6f38e6d6d126acc9735557ddd54851547 /mkspecs/features
parent47546dd3cae4cb6f1ca87621fb3752524f9d050d (diff)
downloadQt-26ded29b31c71ff43036798015cb1c77aae427e3.zip
Qt-26ded29b31c71ff43036798015cb1c77aae427e3.tar.gz
Qt-26ded29b31c71ff43036798015cb1c77aae427e3.tar.bz2
Fixed compilation and linking of EGL on Windows CE.
Moved duplicated and broken code for setting up the include and library paths into the egl.prf feature file, which egl.pri and opengl.pro now includes using the qmake feature system. Task-number: QTBUG-5148 Reviewed-by: Tom Cooksey
Diffstat (limited to 'mkspecs/features')
-rw-r--r--mkspecs/features/egl.prf32
1 files changed, 29 insertions, 3 deletions
diff --git a/mkspecs/features/egl.prf b/mkspecs/features/egl.prf
index 22002c3..00f70d3 100644
--- a/mkspecs/features/egl.prf
+++ b/mkspecs/features/egl.prf
@@ -1,3 +1,29 @@
-!isEmpty(QMAKE_INCDIR_EGL): INCLUDEPATH += $$QMAKE_INCDIR_EGL
-!isEmpty(QMAKE_LIBDIR_EGL): LIBS += -L$$QMAKE_LIBDIR_EGL
-!isEmpty(QMAKE_LIBS_EGL): LIBS += $$QMAKE_LIBS_EGL
+# On UNIX, we can use config tests to figure out if egl.h is in
+# EGL/egl.h or GLES/egl.h. Sadly, there are no config tests on WinCE
+# so we have to assume that for GLES 1.1 (CL), the EGL header is in
+# GLES/egl.h. We also assume there is no separate libEGL.lib library,
+# so we use the GL library instead.
+
+wince*:contains(QT_CONFIG, opengles1) {
+ INCLUDEPATH += $$QMAKE_INCDIR_OPENGL_ES1
+ LIBS_PRIVATE += $$QMAKE_LIBS_OPENGL_ES1
+ for(p, QMAKE_LIBDIR_OPENGL_ES1) {
+ exists($$p):LIBS_PRIVATE += -L$$p
+ }
+ DEFINES += QT_GLES_EGL
+} else:wince*:contains(QT_CONFIG, opengles1cl) {
+ INCLUDEPATH += $$QMAKE_INCDIR_OPENGL_ES1CL
+ LIBS_PRIVATE += $$QMAKE_LIBS_OPENGL_ES1CL
+ LIBS += $$QMAKE_LFLAGS_EGL
+ for(p, QMAKE_LIBDIR_OPENGL_ES1CL) {
+ exists($$p):LIBS_PRIVATE += -L$$p
+ }
+ DEFINES += QT_GLES_EGL
+} else {
+ INCLUDEPATH += $$QMAKE_INCDIR_EGL
+ LIBS_PRIVATE += $$QMAKE_LIBS_EGL
+ LIBS += $$QMAKE_LFLAGS_EGL
+ for(p, QMAKE_LIBDIR_EGL) {
+ exists($$p):LIBS_PRIVATE += -L$$p
+ }
+}