[vlc-commits] commit: Contribs: make Qt4 available on mac (Jean-Baptiste Kempf )

git at videolan.org git at videolan.org
Tue Nov 30 13:21:29 CET 2010


vlc | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Tue Nov 30 13:21:02 2010 +0100| [fb09bf19a0e55209092a991d0cb6708e0e1679c9] | committer: Jean-Baptiste Kempf 

Contribs: make Qt4 available on mac

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=fb09bf19a0e55209092a991d0cb6708e0e1679c9
---

 extras/contrib/src/Patches/QtCoreMac.pc.in |   14 ++++++++
 extras/contrib/src/Patches/QtGuiMac.pc.in  |   14 ++++++++
 extras/contrib/src/contrib-src.mak         |   47 ++++-----------------------
 extras/contrib/src/packages.mak            |    6 +--
 4 files changed, 37 insertions(+), 44 deletions(-)

diff --git a/extras/contrib/src/Patches/QtCoreMac.pc.in b/extras/contrib/src/Patches/QtCoreMac.pc.in
new file mode 100644
index 0000000..44a665f
--- /dev/null
+++ b/extras/contrib/src/Patches/QtCoreMac.pc.in
@@ -0,0 +1,14 @@
+prefix=/Library/Frameworks/QtCore.framework/Versions/4/
+exec_prefix=${prefix}
+libdir=${prefix}/lib
+includedir=${prefix}/Headers
+
+Name: Qtcore
+Description: Qtcore Library
+Version: 4.6.1
+Libs: -F/Library/Frameworks -L/Library/Frameworks -framework QtGui -framework QtCore 
+Cflags: -I/usr/local/Qt4.6/mkspecs/macx-g++ -I. -I${includedir} -DQT_CORE_LIB -DQT_SHARED
+
+
+
+
diff --git a/extras/contrib/src/Patches/QtGuiMac.pc.in b/extras/contrib/src/Patches/QtGuiMac.pc.in
new file mode 100644
index 0000000..9e83b25
--- /dev/null
+++ b/extras/contrib/src/Patches/QtGuiMac.pc.in
@@ -0,0 +1,14 @@
+prefix=/Library/Frameworks/QtGui.framework/Versions/4/
+exec_prefix=${prefix}
+libdir=${prefix}/lib
+includedir=${prefix}/Headers
+
+Name: Qtgui
+Description: Qtgui Library
+Version: 4.6.1
+Libs: -F/Library/Frameworks -L/Library/Frameworks -framework QtGui -framework QtCore 
+Cflags: -I/usr/local/Qt4.6/mkspecs/macx-g++ -I. -I${includedir} -DQT_GUI_LIB -DQT_SHARED
+
+
+
+
diff --git a/extras/contrib/src/contrib-src.mak b/extras/contrib/src/contrib-src.mak
index 4900a77..45ec644 100644
--- a/extras/contrib/src/contrib-src.mak
+++ b/extras/contrib/src/contrib-src.mak
@@ -1599,55 +1599,22 @@ CLEAN_PKG += qt4_win32
 DISTCLEAN_PKG += qt4-$(QT4_VERSION)-win32-bin.tar.bz2
 
 # ***************************************************************************
-# qt4 (trolltech binaries)
+# qt4 (Mac)
 # ***************************************************************************
-
-qt-win-opensource-$(QT4T_VERSION)-mingw.exe:
-	wget $(QT4T_URL)
-
-Qt_win32: qt-win-opensource-$(QT4T_VERSION)-mingw.exe
-	mkdir Qt
-	7z -oQt x qt-win-opensource-$(QT4T_VERSION)-mingw.exe \$$OUTDIR/bin\ /bin \$$OUTDIR/bin\ /lib \$$OUTDIR/bin\ /include/QtCore \$$OUTDIR/bin\ /include/QtGui \$$OUTDIR/bin\ /src/gui \$$OUTDIR/bin\ /src/corelib \$$OUTDIR/bin\ /translations
-	mv Qt/\$$OUTDIR/bin\ /* Qt/ && rmdir Qt/\$$OUTDIR/bin\  Qt/\$$OUTDIR
-	find Qt -name '* ' -exec sh -c "mv \"{}\" `echo {}`" \;
-	find Qt/src -name '*.cpp' -exec rm {} \;
-	find Qt/translations -type f -a ! -name 'qt_*.qm' -exec rm {} \;
-	find Qt/include -name '*.h' -exec sh -c "mv {} {}.tmp; sed 's,..\/..\/src,..\/src,' {}.tmp > {}; rm -f {}.tmp" \;
-	mkdir Qt/lib/pkgconfig
-	sed -e s,@@VERSION@@,$(QT4T_VERSION), -e s,@@PREFIX@@,$(PREFIX), Patches/QtCore.pc.in > Qt/lib/pkgconfig/QtCore.pc
-	sed -e s,@@VERSION@@,$(QT4T_VERSION), -e s,@@PREFIX@@,$(PREFIX), Patches/QtGui.pc.in > Qt/lib/pkgconfig/QtGui.pc
-
-.Qt_win32: Qt_win32
-	mkdir -p $(PREFIX)/bin $(PREFIX)/include/qt4/src $(PREFIX)/lib/pkgconfig $(PREFIX)/share/qt4/translations
-	cp Qt/bin/moc.exe Qt/bin/rcc.exe Qt/bin/uic.exe $(PREFIX)/bin
-	cp -r Qt/include/QtCore Qt/include/QtGui $(PREFIX)/include/qt4
-	cp -r Qt/src/corelib Qt/src/gui $(PREFIX)/include/qt4/src
-	cp Qt/lib/libQtCore4.a Qt/lib/libQtGui4.a $(PREFIX)/lib
-	cp Qt/lib/pkgconfig/* $(PREFIX)/lib/pkgconfig
-	cp Qt/translations/* $(PREFIX)/share/qt4/translations
-	touch $@
-
-CLEAN_FILE += .Qt_win32
-CLEAN_PKG += Qt_win32
-DISTCLEAN_PKG += qt-win-opensource-$(QT4T_VERSION)-mingw.exe
-
-# ***************************************************************************
-# qt4 (source-code compilation for Mac)
-# ***************************************************************************
-
-qt-everywhere-opensource-src-$(QT4_MAC_VERSION).tar.gz:
+ 
+qt-mac-opensource-$(QT4_MAC_VERSION).dmg: 
 	$(WGET) $(QT4_MAC_URL)
 
-qt4_mac: qt-everywhere-opensource-src-$(QT4_MAC_VERSION).tar.gz
-	$(EXTRACT_GZ)
+qt4_mac: qt-mac-opensource-$(QT4_MAC_VERSION).dmg
 
 .qt4_mac: qt4_mac
-	(cd qt4_mac; ./configure -prefix $(PREFIX) -release -fast -no-qt3support -nomake "examples demos" -sdk $(MACOSX_SDK) -no-framework -arch $(ARCH) && make && make install)
+	cp Patches/QtCoreMac.pc.in $(PREFIX)/lib/pkgconfig/QtCore.pc
+	cp Patches/QtGuiMac.pc.in $(PREFIX)/lib/pkgconfig/QtGui.pc
 	touch $@
 
 CLEAN_FILE += .qt4_mac
 CLEAN_PKG += qt4_mac
-DISTCLEAN_PKG += qt-mac-opensource-src-$(QT4_MAC_VERSION).tar.gz
+DISTCLEAN_PKG += qt-mac-opensource-$(QT4_MAC_VERSION).dmg
 
 # ***************************************************************************
 # zlib
diff --git a/extras/contrib/src/packages.mak b/extras/contrib/src/packages.mak
index a118d7c..c7a0fe9 100644
--- a/extras/contrib/src/packages.mak
+++ b/extras/contrib/src/packages.mak
@@ -173,10 +173,8 @@ MUSE_URL=http://files.musepack.net/source/libmpcdec-$(MUSE_VERSION).tar.bz2
 #MUSE_URL=http://files2.musepack.net/source/libmpcdec-$(MUSE_VERSION).tar.bz2
 QT4_VERSION=4.6.2
 QT4_URL=$(CONTRIB_VIDEOLAN)/qt4-$(QT4_VERSION)-win32-bin.tar.bz2
-QT4_MAC_VERSION=4.6.3
-QT4_MAC_URL=http://get.qt.nokia.com/qt/source/qt-everywhere-opensource-src-$(QT4_MAC_VERSION).tar.gz
-QT4T_VERSION=4.3.2
-QT4T_URL=ftp://ftp.trolltech.com/pub/qt/source/qt-win-opensource-$(QT4T_VERSION)-mingw.exe
+QT4_MAC_VERSION=4.7.1
+QT4_MAC_URL=http://get.qt.nokia.com/qt/source/qt-mac-opensource-$(QT4_MAC_VERSION).dmg
 ZLIB_VERSION=1.2.5
 ZLIB_URL=$(SF)/libpng/zlib-$(ZLIB_VERSION).tar.gz
 XML_VERSION=2.7.7



More information about the vlc-commits mailing list