summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastian Pipping <sping@gentoo.org>2011-09-21 13:13:19 +0000
committerSebastian Pipping <sping@gentoo.org>2011-09-21 13:13:19 +0000
commit03531ca6b02274371ed1181da265c2bb0b21bea3 (patch)
treef79f0bf689aed7f7d2e06021471324d871d43989 /media-video
parentMigrate to git-2. (diff)
downloadgentoo-2-03531ca6b02274371ed1181da265c2bb0b21bea3.tar.gz
gentoo-2-03531ca6b02274371ed1181da265c2bb0b21bea3.tar.bz2
gentoo-2-03531ca6b02274371ed1181da265c2bb0b21bea3.zip
media-video/smplayer: Unbundle quazip (bug #383309)
(Portage version: 2.1.10.19/cvs/Linux x86_64)
Diffstat (limited to 'media-video')
-rw-r--r--media-video/smplayer/ChangeLog8
-rw-r--r--media-video/smplayer/files/smplayer-0.6.9-quazip.patch96
-rw-r--r--media-video/smplayer/smplayer-0.6.9-r2.ebuild106
3 files changed, 209 insertions, 1 deletions
diff --git a/media-video/smplayer/ChangeLog b/media-video/smplayer/ChangeLog
index be3aa969b89f..148856e668b8 100644
--- a/media-video/smplayer/ChangeLog
+++ b/media-video/smplayer/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for media-video/smplayer
# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/media-video/smplayer/ChangeLog,v 1.94 2011/09/17 00:10:13 beandog Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-video/smplayer/ChangeLog,v 1.95 2011/09/21 13:13:19 sping Exp $
+
+*smplayer-0.6.9-r2 (21 Sep 2011)
+
+ 21 Sep 2011; Sebastian Pipping <sping@gentoo.org> +smplayer-0.6.9-r2.ebuild,
+ +files/smplayer-0.6.9-quazip.patch:
+ Unbundle quazip (bug #383309), re-keywording requested (bug #383945)
*smplayer-0.6.9-r1 (16 Sep 2011)
diff --git a/media-video/smplayer/files/smplayer-0.6.9-quazip.patch b/media-video/smplayer/files/smplayer-0.6.9-quazip.patch
new file mode 100644
index 000000000000..7e32c4bc014a
--- /dev/null
+++ b/media-video/smplayer/files/smplayer-0.6.9-quazip.patch
@@ -0,0 +1,96 @@
+From 6350ac5b99cccf4e45e334512bc64b5c71b06135 Mon Sep 17 00:00:00 2001
+From: Sebastian Pipping <sebastian@pipping.org>
+Date: Wed, 21 Sep 2011 14:23:08 +0200
+Subject: [PATCH] Move to system's quazip
+
+---
+ src/findsubtitles/findsubtitles.pro | 11 ++---------
+ src/findsubtitles/findsubtitleswindow.cpp | 4 ++--
+ src/smplayer.pro | 11 ++---------
+ 3 files changed, 6 insertions(+), 20 deletions(-)
+
+diff --git a/src/findsubtitles/findsubtitles.pro b/src/findsubtitles/findsubtitles.pro
+index bbfa8a1..ad0cefa 100644
+--- a/src/findsubtitles/findsubtitles.pro
++++ b/src/findsubtitles/findsubtitles.pro
+@@ -28,8 +28,8 @@ FORMS += ../filechooser.ui findsubtitleswindow.ui findsubtitlesconfigdialog.ui
+ DEFINES += NO_SMPLAYER_SUPPORT DOWNLOAD_SUBS
+
+ contains( DEFINES, DOWNLOAD_SUBS ) {
+- INCLUDEPATH += filedownloader quazip
+- DEPENDPATH += filedownloader quazip
++ INCLUDEPATH += filedownloader
++ DEPENDPATH += filedownloader
+
+ HEADERS += filedownloader.h subchooserdialog.h
+ SOURCES += filedownloader.cpp subchooserdialog.cpp
+@@ -38,17 +38,2 @@ contains( DEFINES, DOWNLOAD_SUBS ) {
+
+- HEADERS += crypt.h \
+- ioapi.h \
+- quazip.h \
+- quazipfile.h \
+- quazipfileinfo.h \
+- quazipnewinfo.h \
+- unzip.h \
+- zip.h
+-
+- SOURCES += ioapi.c \
+- quazip.cpp \
+- quazipfile.cpp \
+- quazipnewinfo.cpp \
+- unzip.c \
+- zip.c
+
+diff --git a/src/findsubtitles/findsubtitleswindow.cpp b/src/findsubtitles/findsubtitleswindow.cpp
+index 6d1d2c7..6defa5d 100644
+--- a/src/findsubtitles/findsubtitleswindow.cpp
++++ b/src/findsubtitles/findsubtitleswindow.cpp
+@@ -36,8 +36,8 @@
+ #ifdef DOWNLOAD_SUBS
+ #include "filedownloader.h"
+ #include "subchooserdialog.h"
+-#include "quazip.h"
+-#include "quazipfile.h"
++#include <quazip/quazip.h>
++#include <quazip/quazipfile.h>
+ #include <QTemporaryFile>
+ #include <QBuffer>
+ #endif
+diff --git a/src/smplayer.pro b/src/smplayer.pro
+index 9020e6c..9e995fc 100644
+--- a/src/smplayer.pro
++++ b/src/smplayer.pro
+@@ -249,8 +249,8 @@ TRANSLATIONS = translations/smplayer_es.ts translations/smplayer_de.ts \
+ translations/smplayer_et.ts translations/smplayer_lt.ts
+
+ contains( DEFINES, DOWNLOAD_SUBS ) {
+- INCLUDEPATH += findsubtitles/filedownloader findsubtitles/quazip
+- DEPENDPATH += findsubtitles/filedownloader findsubtitles/quazip
++ INCLUDEPATH += findsubtitles/filedownloader
++ DEPENDPATH += findsubtitles/filedownloader
+
+ HEADERS += filedownloader.h subchooserdialog.h
+ SOURCES += filedownloader.cpp subchooserdialog.cpp
+@@ -259,17 +259,3 @@ contains( DEFINES, DOWNLOAD_SUBS ) {
+
+- HEADERS += crypt.h \
+- ioapi.h \
+- quazip.h \
+- quazipfile.h \
+- quazipfileinfo.h \
+- quazipnewinfo.h \
+- unzip.h \
+- zip.h
+-
+- SOURCES += ioapi.c \
+- quazip.cpp \
+- quazipfile.cpp \
+- quazipnewinfo.cpp \
+- unzip.c \
+- zip.c
++ LIBS += -lquazip
+
+--
+1.7.6.1
+
diff --git a/media-video/smplayer/smplayer-0.6.9-r2.ebuild b/media-video/smplayer/smplayer-0.6.9-r2.ebuild
new file mode 100644
index 000000000000..aaa4d234897e
--- /dev/null
+++ b/media-video/smplayer/smplayer-0.6.9-r2.ebuild
@@ -0,0 +1,106 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/media-video/smplayer/smplayer-0.6.9-r2.ebuild,v 1.1 2011/09/21 13:13:19 sping Exp $
+
+EAPI="2"
+LANGS="bg ca cs de en_US es et eu fi fr gl hu it ja ka ko ku mk nl pl pt_BR
+pt sk sr sv tr zh_CN zh_TW"
+LANGSLONG="ar_SY el_GR ro_RO ru_RU sl_SI uk_UA vi_VN"
+
+inherit eutils qt4-r2
+
+MY_PV=${PV##*_p}
+if [[ "${MY_PV}" != "${PV}" ]]; then
+ # svn snapshot
+ MY_PV=r${MY_PV}
+ MY_P=${PN}-${MY_PV}
+ S="${WORKDIR}/${MY_P}"
+ SRC_URI="mirror://gentoo/${MY_P}.tar.bz2"
+else
+ # regular upstream release
+ SRC_URI="mirror://sourceforge/${PN}/${P}.tar.bz2"
+fi
+
+DESCRIPTION="Great Qt4 GUI front-end for mplayer"
+HOMEPAGE="http://smplayer.berlios.de/"
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="debug"
+
+DEPEND="x11-libs/qt-gui:4
+ dev-libs/quazip"
+MPLAYER_USE="[ass,png]"
+RDEPEND="${DEPEND}
+ || ( media-video/mplayer${MPLAYER_USE} media-video/mplayer2[libass,png] media-video/mplayer2${MPLAYER_USE} )"
+
+src_prepare() {
+ # Force Ctrl+Q as default quit shortcut
+ epatch "${FILESDIR}/${PN}-0.6.8-quit.patch"
+
+ # Unbundle dev-libs/quazip
+ rm -R src/findsubtitles/quazip/ || die
+ epatch "${FILESDIR}"/${P}-quazip.patch
+
+ # Upstream Makefile sucks
+ sed -i -e "/^PREFIX=/s:/usr/local:/usr:" \
+ -e "/^DOC_PATH=/s:packages/smplayer:${PF}:" \
+ -e '/\.\/get_svn_revision\.sh/,+2c\
+ cd src && $(DEFS) $(MAKE)' \
+ "${S}"/Makefile || die "sed failed"
+
+ # Turn debug message flooding off
+ if ! use debug ; then
+ sed -i 's:#\(DEFINES += NO_DEBUG_ON_CONSOLE\):\1:' \
+ "${S}"/src/smplayer.pro || die "sed failed"
+ fi
+}
+
+src_configure() {
+ cd "${S}"/src
+ echo "#define SVN_REVISION \"SVN-${MY_PV} (Gentoo)\"" > svn_revision.h
+ eqmake4
+}
+
+gen_translation() {
+ ebegin "Generating $1 translation"
+ lrelease ${PN}_${1}.ts
+ eend $? || die "failed to generate $1 translation"
+}
+
+src_compile() {
+ emake || die
+
+ # Generate translations
+ cd "${S}"/src/translations
+ local lang= nolangs= x=
+ for lang in ${LINGUAS}; do
+ if has ${lang} ${LANGS}; then
+ gen_translation ${lang}
+ continue
+ elif [[ " ${LANGSLONG} " == *" ${lang}_"* ]]; then
+ for x in ${LANGSLONG}; do
+ if [[ "${lang}" == "${x%_*}" ]]; then
+ gen_translation ${x}
+ continue 2
+ fi
+ done
+ fi
+ nolangs="${nolangs} ${lang}"
+ done
+ [[ -n ${nolangs} ]] && ewarn "Sorry, but ${PN} does not support the LINGUAS:" ${nolangs}
+ # install fails when no translation is present (bug 244370)
+ [[ -z $(ls *.qm 2>/dev/null) ]] && gen_translation en_US
+}
+
+src_install() {
+ # remove unneeded copies of GPL
+ rm -f Copying.txt docs/{cs,en,ja,ru}/gpl.html
+ rm -rf docs/{de,es,nl,ro}
+
+ # remove windows-only files
+ rm "${S}"/*.bat
+
+ emake DESTDIR="${D}" install || die
+ prepalldocs
+}