qimage/configure: let qimage first attempt to use Qt4 through pkg-config (canonical...
authorddennedy <ddennedy@d19143bc-622f-0410-bfdd-b5b2a6649095>
Thu, 12 Feb 2009 00:58:34 +0000 (00:58 +0000)
committerddennedy <ddennedy@d19143bc-622f-0410-bfdd-b5b2a6649095>
Thu, 12 Feb 2009 00:58:34 +0000 (00:58 +0000)
git-svn-id: https://mlt.svn.sourceforge.net/svnroot/mlt/trunk/mlt@1351 d19143bc-622f-0410-bfdd-b5b2a6649095

src/modules/qimage/configure

index 2a2f582..f10f4ac 100755 (executable)
@@ -65,7 +65,17 @@ else
                esac
        done
 
-       if [ -d "$qimage_libdir" -a -d "$qimage_includedir" ]
+       pkg-config --exists 'QtGui >= 4'
+       if [ $? -eq 0 ] && [ "$force_qt3" = "" ]
+       then
+               echo "Qt version 4.x detected, will compile Qt4 qimage producer"
+               qt4_found=true
+               echo "#define USE_QT4" > config.h
+               echo "USE_QT4=1" > config.mak
+               echo QTCXXFLAGS=$(pkg-config --cflags QtGui) >> config.mak
+               echo QTLIBS=$(pkg-config --libs QtGui) >> config.mak
+               
+       elif [ -d "$qimage_libdir" -a -d "$qimage_includedir" ]
        then
 
                # test if we have a Qt3 or Qt4