--- /dev/null
+diff -Naur qt-3.3.3-original/src/opengl/qgl_x11.cpp qt-3.3.3-patched/src/opengl/qgl_x11.cpp
+--- qt-3.3.3-original/src/opengl/qgl_x11.cpp 2004-08-05 18:42:12.000000000 +0400
++++ qt-3.3.3-patched/src/opengl/qgl_x11.cpp 2006-12-14 16:26:33.000000000 +0300
+@@ -125,7 +125,7 @@
+ if (gl_syms_resolved)
+ return TRUE;
+
+- QLibrary gl("GL");
++ QLibrary gl("libGL.so.1");
+ gl.setAutoUnload(FALSE);
+
+ qt_glCallLists = (_glCallLists) gl.resolve("glCallLists");
+diff -Naur qt-3.3.3-original/src/tools/qlibrary.cpp qt-3.3.3-patched/src/tools/qlibrary.cpp
+--- qt-3.3.3-original/src/tools/qlibrary.cpp 2004-08-05 18:41:55.000000000 +0400
++++ qt-3.3.3-patched/src/tools/qlibrary.cpp 2006-12-14 16:29:26.000000000 +0300
+@@ -39,6 +39,7 @@
+ #include "qplatformdefs.h"
+ #include <private/qlibrary_p.h>
+ #include <qstringlist.h>
++#include <qregexp.h>
+ #include <qfile.h>
+
+ #ifndef QT_NO_LIBRARY
+@@ -393,6 +394,8 @@
+ return libfile;
+
+ QString filename = libfile;
++ if (QFile::exists(filename))
++ return filename;
+
+ #if defined(Q_WS_WIN)
+ if ( filename.findRev( '.' ) <= filename.findRev( '/' ) )
+@@ -422,10 +425,11 @@
+ QString path = tmpfilename.left( x + 1 );
+ QString file = tmpfilename.right( tmpfilename.length() - x - 1 );
+ tmpfilename = QString( "%1lib%2" ).arg( path ).arg( file );
+- } else {
++ } else if (tmpfilename.left(3) != QString("lib")) {
+ tmpfilename = QString( "lib%1" ).arg( filename );
+ }
+- tmpfilename += filter;
++ if (!tmpfilename.contains(QRegExp(filter + "((\\.[0-9]+)+)?$")))
++ tmpfilename += filter;
+ if(QFile::exists(tmpfilename) || it == filters.end()) {
+ filename = tmpfilename;
+ break;
makedir ${PRODUCT_DIR}
check_jb tar xfz ${SOURCE_DIR}/qt-3.3.3.tar.gz -C ${INSTALL_WORK}
+
+# apply patch : fix pb of libGL loading
+if [ -f patches/qt-3.3.3-load-gl.patch ] ; then
+ cp patches/qt-3.3.3-load-gl.patch ${PRODUCT_WORK}
+ ( cd ${PRODUCT_WORK} ; patch -p1 < qt-3.3.3-load-gl.patch )
+ patched_for_gl="yes"
+fi
+
cd ${PRODUCT_WORK}
mv -f configure configure-orig
# use all plugin styles except -plugin-style-windows
QT_FLAGS=$QT_FLAGS" -plugin-style-cde -plugin-style-compact -plugin-style-motif -plugin-style-motifplus -plugin-style-platinum -plugin-style-sgi"
-# prefix
+# add -dlopen-opengl flag (ONLY if the corresponding patch was applied)
+if [ "$patched_for_gl" == "yes" ] ; then
+ QT_FLAGS=$QT_FLAGS" -dlopen-opengl"
+fi
+# configure
check_job ${PRODUCT_DIR}/CONFIGURE.LOG ./configure $QT_FLAGS -prefix ${PRODUCT_DIR}
sed -e "s%^all: symlinks src-qmake src-moc sub-src sub-tools sub-tutorial sub-examples%all: symlinks src-qmake src-moc sub-src sub-tools%g" Makefile > _Makefile
check_jb tar xfz ${SOURCE_DIR}/qt-3.3.4.tar.gz -C ${INSTALL_WORK}
+# apply patch : fix pb of libGL loading
+if [ -f patches/qt-3.3.3-load-gl.patch ] ; then
+ cp patches/qt-3.3.3-load-gl.patch ${PRODUCT_WORK}
+ ( cd ${PRODUCT_WORK} ; patch -p1 < qt-3.3.3-load-gl.patch )
+ patched_for_gl="yes"
+fi
+
# apply patch for 64-bit platforms
if test `uname -m` = "x86_64" ; then
if [ -f patches/qt-3.3.4-lib64.patch ] ; then
fi
# use system graphics libraries
QT_FLAGS=$QT_FLAGS" -system-libjpeg -system-libpng -system-libmng -qt-imgfmt-jpeg -qt-imgfmt-png -qt-imgfmt-mng -lpng -lmng -ljpeg"
-# prefix
+# add -dlopen-opengl flag (ONLY if the corresponding patch was applied)
+if [ "$patched_for_gl" == "yes" ] ; then
+ QT_FLAGS=$QT_FLAGS" -dlopen-opengl"
+fi
+
+# plugins
if [ -e /etc/mandriva-release ] ; then
version=`cat /etc/mandriva-release | awk '{print $1$4}'`
if [ "$version" == "Mandriva2006.0" ] ; then
fi
fi
+# configure
check_job ${PRODUCT_DIR}/CONFIGURE.LOG ./configure $QT_FLAGS -prefix ${PRODUCT_DIR}
sed -e "s%^all: symlinks src-qmake src-moc sub-src sub-tools sub-tutorial sub-examples%all: symlinks src-qmake src-moc sub-src sub-tools%g" Makefile > _Makefile