diff options
author | Ben de Groot <yngwin@gentoo.org> | 2009-07-26 13:14:37 +0000 |
---|---|---|
committer | Ben de Groot <yngwin@gentoo.org> | 2009-07-26 13:14:37 +0000 |
commit | ef0e3fd0dcebb12702d445523311b1578bbbab04 (patch) | |
tree | f7973a055f086d1f7d08e8db2e57ae5c5b77db8d /media-video/smplayer | |
parent | Fix Musepack deps for SV8. (diff) | |
download | gentoo-2-ef0e3fd0dcebb12702d445523311b1578bbbab04.tar.gz gentoo-2-ef0e3fd0dcebb12702d445523311b1578bbbab04.tar.bz2 gentoo-2-ef0e3fd0dcebb12702d445523311b1578bbbab04.zip |
Version bump. Add Estonian and Vietnamese translations. Remove some old ebuilds.
(Portage version: 2.2_rc33/cvs/Linux x86_64)
Diffstat (limited to 'media-video/smplayer')
-rw-r--r-- | media-video/smplayer/ChangeLog | 11 | ||||
-rw-r--r-- | media-video/smplayer/smplayer-0.6.1-r1.ebuild | 106 | ||||
-rw-r--r-- | media-video/smplayer/smplayer-0.6.5-r1.ebuild | 92 | ||||
-rw-r--r-- | media-video/smplayer/smplayer-0.6.5.1.ebuild | 88 | ||||
-rw-r--r-- | media-video/smplayer/smplayer-0.6.6_p2776.ebuild | 85 | ||||
-rw-r--r-- | media-video/smplayer/smplayer-0.6.7_p2872-r1.ebuild | 91 | ||||
-rw-r--r-- | media-video/smplayer/smplayer-0.6.8.ebuild | 104 |
7 files changed, 114 insertions, 463 deletions
diff --git a/media-video/smplayer/ChangeLog b/media-video/smplayer/ChangeLog index cc09044f885a..4d2dd512de0d 100644 --- a/media-video/smplayer/ChangeLog +++ b/media-video/smplayer/ChangeLog @@ -1,6 +1,15 @@ # ChangeLog for media-video/smplayer # Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/media-video/smplayer/ChangeLog,v 1.71 2009/07/06 22:34:27 jer Exp $ +# $Header: /var/cvsroot/gentoo-x86/media-video/smplayer/ChangeLog,v 1.72 2009/07/26 13:14:37 yngwin Exp $ + +*smplayer-0.6.8 (26 Jul 2009) + + 26 Jul 2009; Ben de Groot <yngwin@gentoo.org> -smplayer-0.6.1-r1.ebuild, + -smplayer-0.6.5-r1.ebuild, -smplayer-0.6.5.1.ebuild, + -smplayer-0.6.6_p2776.ebuild, -smplayer-0.6.7_p2872-r1.ebuild, + +smplayer-0.6.8.ebuild: + Version bump. Add Estonian and Vietnamese translations. Remove some old + ebuilds. 06 Jul 2009; Jeroen Roovers <jer@gentoo.org> smplayer-0.6.6.ebuild: Stable for HPPA (bug #257852). diff --git a/media-video/smplayer/smplayer-0.6.1-r1.ebuild b/media-video/smplayer/smplayer-0.6.1-r1.ebuild deleted file mode 100644 index ee1a37bd6c53..000000000000 --- a/media-video/smplayer/smplayer-0.6.1-r1.ebuild +++ /dev/null @@ -1,106 +0,0 @@ -# Copyright 1999-2008 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/media-video/smplayer/smplayer-0.6.1-r1.ebuild,v 1.9 2008/12/18 07:44:50 yngwin Exp $ - -EAPI="1" -inherit eutils qt4 - -DESCRIPTION="Great Qt4 GUI front-end for mplayer" -HOMEPAGE="http://smplayer.sourceforge.net" -SRC_URI="mirror://sourceforge/${PN}/${P}.tar.bz2" -LICENSE="GPL-2" -SLOT="0" -KEYWORDS="alpha amd64 hppa ppc ppc64 sparc x86 ~x86-fbsd" -IUSE="" -DEPEND="|| ( x11-libs/qt-gui:4 - >=x11-libs/qt-4.3:4 )" -RDEPEND="${DEPEND} - >media-video/mplayer-1.0_rc1" - -LANGS="bg ca cs de en_US es eu fi fr hu it ja ka ko mk nl pl pt_BR pt_PT sk sr sv tr zh_CN zh_TW" -NOLONGLANGS="el_GR ro_RO ru_RU uk_UA" -for X in ${LANGS}; do - IUSE="${IUSE} linguas_${X}" -done -for X in ${NOLONGLANGS}; do - IUSE="${IUSE} linguas_${X%_*}" -done - -pkg_setup() { - if has_version ">=x11-libs/qt-4.3:4"; then - QT4_BUILT_WITH_USE_CHECK="qt3support" - else - if ! built_with_use "x11-libs/qt-gui:4" qt3support; then - eerror "You have to built x11-libs/qt-gui:4 with qt3support." - die "qt3support in qt-gui disabled" - fi - fi - qt4_pkg_setup - - if ! built_with_use --missing true media-video/mplayer ass \ - || ! built_with_use --missing true media-video/mplayer srt; then - echo - ewarn "SMPlayer needs MPlayer to be built with USE=ass or srt for subtitle" - ewarn "support. Please enable the ass or srt USE flag for mplayer and" - ewarn "re-emerge media-video/mplayer before emerging smplayer." - echo - die "media-video/mplayer needs USE=ass or srt enabled" - fi - if ! built_with_use media-video/mplayer png; then - echo - ewarn "SMPlayer needs MPlayer built with USE=png for screenshot support." - ewarn "Please enable the png USE flag for mplayer and re-emerge" - ewarn "media-video/mplayer before emergeing smplayer." - echo - die "media-video/mplayer needs USE=png enabled" - fi -} - -src_compile() { - local MY_SVNREV="1304" - echo "SVN-r${MY_SVNREV}" > svn_revision.txt - echo "#define SVN_REVISION \"SVN-r${MY_SVNREV}\"" > src/svn_revision.h - - # Fix paths in Makefile and allow parallel building - sed -i -e "/^PREFIX=/s:/usr/local:/usr:" \ - -e "/^CONF_PREFIX=/s:\$(PREFIX)::" \ - -e "/^DOC_PATH=/s:packages/smplayer:${PF}:" \ - -e '/get_svn_revision.sh/,+2c\ - cd src && $(DEFS) $(MAKE)' \ - "${S}"/Makefile || die "sed failed" - - eqmake4 src/${PN}.pro -o src/Makefile - emake || die "emake failed" - - # Generate translations - cd "${S}"/src/translations - local LANG= - for LANG in ${LINGUAS}; do - if has ${LANG} ${LANGS}; then - einfo "Generating ${LANG} translation ..." - lrelease ${PN}_${LANG}.ts || die "Failed to generate ${LANG} translation!" - continue - elif [[ " ${NOLONGLANGS} " == *" ${LANG}_"* ]]; then - local X= - for X in ${NOLONGLANGS}; do - if [[ "${LANG}" == "${X%_*}" ]]; then - einfo "Generating ${X} translation ..." - lrelease ${PN}_${X}.ts || die "Failed to generate ${X} translation!" - continue 2 - fi - done - fi - ewarn "Sorry, but ${PN} does not support the ${LANG} LINGUA." - done -} - -src_install() { - # remove unneeded copies of GPL - rm Copying.txt docs/en/gpl.html docs/ru/gpl.html - for i in de es ja ro ; do - rm -rf docs/$i - done - - emake DESTDIR="${D}" install || die "emake install failed" - prepalldocs -} diff --git a/media-video/smplayer/smplayer-0.6.5-r1.ebuild b/media-video/smplayer/smplayer-0.6.5-r1.ebuild deleted file mode 100644 index 1723767b1aa1..000000000000 --- a/media-video/smplayer/smplayer-0.6.5-r1.ebuild +++ /dev/null @@ -1,92 +0,0 @@ -# Copyright 1999-2009 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/media-video/smplayer/smplayer-0.6.5-r1.ebuild,v 1.9 2009/01/23 17:44:42 ranger Exp $ - -EAPI=2 -inherit eutils qt4 - -DESCRIPTION="Great Qt4 GUI front-end for mplayer" -HOMEPAGE="http://smplayer.sourceforge.net" -SRC_URI="mirror://sourceforge/${PN}/${P}.tar.bz2" -LICENSE="GPL-2" -SLOT="0" -KEYWORDS="alpha amd64 ~hppa ppc ppc64 sparc x86 ~x86-fbsd" -IUSE="debug" -DEPEND="|| ( x11-libs/qt-gui:4 - =x11-libs/qt-4.3* )" -RDEPEND="${DEPEND} - media-video/mplayer[ass,png]" - -LANGS="bg ca cs de en_US es eu fi fr gl hu it ja ka ko ku mk nl pl pt_BR pt_PT sk sr sv tr zh_CN zh_TW" -NOLONGLANGS="ar_SY el_GR ro_RO ru_RU sl_SI uk_UA" -for X in ${LANGS}; do - IUSE="${IUSE} linguas_${X}" -done -for X in ${NOLONGLANGS}; do - IUSE="${IUSE} linguas_${X%_*}" -done - -src_prepare() { - # Fix paths in Makefile and allow parallel building - sed -i -e "/^PREFIX=/s:/usr/local:/usr:" \ - -e "/^CONF_PREFIX=/s:\$(PREFIX)::" \ - -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:DEFINES += NO_DEBUG_ON_CONSOLE:" \ - "${S}"/src/smplayer.pro || die "sed failed" - fi -} - -src_configure() { - eqmake4 src/${PN}.pro -o src/Makefile -} - -src_compile() { - emake || die "emake failed" - - # Generate translations - cd "${S}"/src/translations - local LANG= - for LANG in ${LINGUAS}; do - if has ${LANG} ${LANGS}; then - einfo "Generating ${LANG} translation ..." - lrelease ${PN}_${LANG}.ts || die "Failed to generate ${LANG} translation!" - continue - elif [[ " ${NOLONGLANGS} " == *" ${LANG}_"* ]]; then - local X= - for X in ${NOLONGLANGS}; do - if [[ "${LANG}" == "${X%_*}" ]]; then - einfo "Generating ${X} translation ..." - lrelease ${PN}_${X}.ts || die "Failed to generate ${X} translation!" - continue 2 - fi - done - fi - ewarn "Sorry, but ${PN} does not support the ${LANG} LINGUA." - done - # install fails when no translation is present (bug 244370) - [[ -f *.qm ]] || lrelease ${PN}_en_US.ts -} - -src_install() { - # remove unneeded copies of GPL - rm Copying.txt docs/en/gpl.html docs/ru/gpl.html - for i in de es ja nl ro ; do - rm -rf docs/$i - done - - # remove windows-only files - rm "${S}"/*.bat - - emake DESTDIR="${D}" install || die "emake install failed" - prepalldocs - - einfo "Note that the default configuration files location has changed" - einfo "since 0.6.4. You may want to move your existing configuration:" - einfo "mv ~/.smplayer ~/.config/smplayer" -} diff --git a/media-video/smplayer/smplayer-0.6.5.1.ebuild b/media-video/smplayer/smplayer-0.6.5.1.ebuild deleted file mode 100644 index 65c446edc521..000000000000 --- a/media-video/smplayer/smplayer-0.6.5.1.ebuild +++ /dev/null @@ -1,88 +0,0 @@ -# Copyright 1999-2009 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/media-video/smplayer/smplayer-0.6.5.1.ebuild,v 1.2 2009/01/08 01:20:41 yngwin Exp $ - -EAPI=2 -inherit eutils qt4 - -DESCRIPTION="Great Qt4 GUI front-end for mplayer" -HOMEPAGE="http://smplayer.sourceforge.net" -SRC_URI="mirror://sourceforge/${PN}/${P}.tar.bz2" -LICENSE="GPL-2" -SLOT="0" -KEYWORDS="~alpha ~amd64 ~hppa ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd" -IUSE="debug" -DEPEND="|| ( x11-libs/qt-gui:4 - =x11-libs/qt-4.3* )" -RDEPEND="${DEPEND} - media-video/mplayer[ass,png]" - -LANGS="bg ca cs de en_US es eu fi fr gl hu it ja ka ko ku mk nl pl pt_BR pt_PT sk sr sv tr zh_CN zh_TW" -NOLONGLANGS="ar_SY el_GR ro_RO ru_RU sl_SI uk_UA" -for X in ${LANGS}; do - IUSE="${IUSE} linguas_${X}" -done -for X in ${NOLONGLANGS}; do - IUSE="${IUSE} linguas_${X%_*}" -done - -src_prepare() { - # Fix paths in Makefile and allow parallel building - sed -i -e "/^PREFIX=/s:/usr/local:/usr:" \ - -e "/^CONF_PREFIX=/s:\$(PREFIX)::" \ - -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:DEFINES += NO_DEBUG_ON_CONSOLE:" \ - "${S}"/src/smplayer.pro || die "sed failed" - fi -} - -src_configure() { - eqmake4 src/${PN}.pro -o src/Makefile -} - -src_compile() { - emake || die "emake failed" - - # Generate translations - cd "${S}"/src/translations - local LANG= - for LANG in ${LINGUAS}; do - if has ${LANG} ${LANGS}; then - einfo "Generating ${LANG} translation ..." - lrelease ${PN}_${LANG}.ts || die "Failed to generate ${LANG} translation!" - continue - elif [[ " ${NOLONGLANGS} " == *" ${LANG}_"* ]]; then - local X= - for X in ${NOLONGLANGS}; do - if [[ "${LANG}" == "${X%_*}" ]]; then - einfo "Generating ${X} translation ..." - lrelease ${PN}_${X}.ts || die "Failed to generate ${X} translation!" - continue 2 - fi - done - fi - ewarn "Sorry, but ${PN} does not support the ${LANG} LINGUA." - done - # install fails when no translation is present (bug 244370) - [[ -f *.qm ]] || lrelease ${PN}_en_US.ts -} - -src_install() { - # remove unneeded copies of GPL - rm Copying.txt docs/en/gpl.html docs/ru/gpl.html - for i in de es ja nl ro ; do - rm -rf docs/$i - done - - # remove windows-only files - rm "${S}"/*.bat - - emake DESTDIR="${D}" install || die "emake install failed" - prepalldocs -} diff --git a/media-video/smplayer/smplayer-0.6.6_p2776.ebuild b/media-video/smplayer/smplayer-0.6.6_p2776.ebuild deleted file mode 100644 index d0f6fbe2ce3c..000000000000 --- a/media-video/smplayer/smplayer-0.6.6_p2776.ebuild +++ /dev/null @@ -1,85 +0,0 @@ -# Copyright 1999-2009 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/media-video/smplayer/smplayer-0.6.6_p2776.ebuild,v 1.1 2009/02/14 14:45:54 yngwin Exp $ - -EAPI=2 -inherit eutils qt4 - -MY_P=${PN}-r${PV##*p} - -DESCRIPTION="Great Qt4 GUI front-end for mplayer" -HOMEPAGE="http://smplayer.sourceforge.net" -SRC_URI="mirror://gentoo/${MY_P}.tar.bz2" - -LICENSE="GPL-2" -SLOT="0" -KEYWORDS="~alpha ~amd64 ~hppa ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd" -IUSE="debug" - -DEPEND="x11-libs/qt-gui:4" -RDEPEND="${DEPEND} - media-video/mplayer[ass,png]" - -LANGS="bg ca cs de en_US es eu fi fr gl hu it ja ka ko ku mk nl pl pt_BR pt_PT sk sr sv tr zh_CN zh_TW" -NOLONGLANGS="ar_SY el_GR ro_RO ru_RU sl_SI uk_UA" -for X in ${LANGS}; do - IUSE="${IUSE} linguas_${X}" -done -for X in ${NOLONGLANGS}; do - IUSE="${IUSE} linguas_${X%_*}" -done - -S="${WORKDIR}/${MY_P}" - -src_prepare() { - # Turn debug message flooding off - if ! use debug ; then - sed -i "s:#DEFINES += NO_DEBUG_ON_CONSOLE:DEFINES += NO_DEBUG_ON_CONSOLE:" \ - "${S}"/src/smplayer.pro || die "sed failed" - fi -} - -src_configure() { - eqmake4 src/${PN}.pro -o src/Makefile -} - -src_compile() { - emake || die "emake failed" - - # Generate translations - cd "${S}"/src/translations - local LANG= - for LANG in ${LINGUAS}; do - if has ${LANG} ${LANGS}; then - einfo "Generating ${LANG} translation ..." - lrelease ${PN}_${LANG}.ts || die "Failed to generate ${LANG} translation!" - continue - elif [[ " ${NOLONGLANGS} " == *" ${LANG}_"* ]]; then - local X= - for X in ${NOLONGLANGS}; do - if [[ "${LANG}" == "${X%_*}" ]]; then - einfo "Generating ${X} translation ..." - lrelease ${PN}_${X}.ts || die "Failed to generate ${X} translation!" - continue 2 - fi - done - fi - ewarn "Sorry, but ${PN} does not support the ${LANG} LINGUA." - done - # install fails when no translation is present (bug 244370) - [[ -f *.qm ]] || lrelease ${PN}_en_US.ts -} - -src_install() { - # remove unneeded copies of GPL - rm Copying.txt docs/en/gpl.html docs/ru/gpl.html - for i in de es ja nl ro ; do - rm -rf docs/$i - done - - # remove windows-only files - rm "${S}"/*.bat - - emake DESTDIR="${D}" install || die "emake install failed" - prepalldocs -} diff --git a/media-video/smplayer/smplayer-0.6.7_p2872-r1.ebuild b/media-video/smplayer/smplayer-0.6.7_p2872-r1.ebuild deleted file mode 100644 index d382038064ed..000000000000 --- a/media-video/smplayer/smplayer-0.6.7_p2872-r1.ebuild +++ /dev/null @@ -1,91 +0,0 @@ -# Copyright 1999-2009 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/media-video/smplayer/smplayer-0.6.7_p2872-r1.ebuild,v 1.1 2009/03/14 10:27:55 yngwin Exp $ - -EAPI=2 -inherit eutils qt4 - -MY_P=${PN}-r${PV##*p} - -DESCRIPTION="Great Qt4 GUI front-end for mplayer" -HOMEPAGE="http://smplayer.sourceforge.net" -SRC_URI="mirror://gentoo/${MY_P}.tar.bz2" - -LICENSE="GPL-2" -SLOT="0" -KEYWORDS="~alpha ~amd64 ~hppa ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd" -IUSE="debug" - -DEPEND="x11-libs/qt-gui:4" -RDEPEND="${DEPEND} - media-video/mplayer[ass,png]" - -LANGS="bg ca cs de en_US es eu fi fr gl hu it ja ka ko ku mk nl pl pt_BR pt_PT sk sr sv tr zh_CN zh_TW" -NOLONGLANGS="ar_SY el_GR ro_RO ru_RU sl_SI uk_UA" -for X in ${LANGS}; do - IUSE="${IUSE} linguas_${X}" -done -for X in ${NOLONGLANGS}; do - IUSE="${IUSE} linguas_${X%_*}" -done - -S="${WORKDIR}/${MY_P}" - -src_prepare() { - # Fix paths in Makefile - sed -i -e "/^PREFIX=/s:/usr/local:/usr:" \ - -e "/^CONF_PREFIX=/s:\$(PREFIX)::" \ - -e "/^DOC_PATH=/s:packages/smplayer:${PF}:" \ - "${S}"/Makefile || die "sed failed" - - # Turn debug message flooding off - if ! use debug ; then - sed -i "s:#DEFINES += NO_DEBUG_ON_CONSOLE:DEFINES += NO_DEBUG_ON_CONSOLE:" \ - "${S}"/src/smplayer.pro || die "sed failed" - fi -} - -src_configure() { - eqmake4 src/${PN}.pro -o src/Makefile -} - -src_compile() { - emake || die "emake failed" - - # Generate translations - cd "${S}"/src/translations - local LANG= - for LANG in ${LINGUAS}; do - if has ${LANG} ${LANGS}; then - einfo "Generating ${LANG} translation ..." - lrelease ${PN}_${LANG}.ts || die "Failed to generate ${LANG} translation!" - continue - elif [[ " ${NOLONGLANGS} " == *" ${LANG}_"* ]]; then - local X= - for X in ${NOLONGLANGS}; do - if [[ "${LANG}" == "${X%_*}" ]]; then - einfo "Generating ${X} translation ..." - lrelease ${PN}_${X}.ts || die "Failed to generate ${X} translation!" - continue 2 - fi - done - fi - ewarn "Sorry, but ${PN} does not support the ${LANG} LINGUA." - done - # install fails when no translation is present (bug 244370) - [[ -f *.qm ]] || lrelease ${PN}_en_US.ts -} - -src_install() { - # remove unneeded copies of GPL - rm Copying.txt docs/cs/gpl.html docs/en/gpl.html docs/ru/gpl.html - for i in de es ja nl ro ; do - rm -rf docs/$i - done - - # remove windows-only files - rm "${S}"/*.bat - - emake DESTDIR="${D}" install || die "emake install failed" - prepalldocs -} diff --git a/media-video/smplayer/smplayer-0.6.8.ebuild b/media-video/smplayer/smplayer-0.6.8.ebuild new file mode 100644 index 000000000000..c2255a4e5f19 --- /dev/null +++ b/media-video/smplayer/smplayer-0.6.8.ebuild @@ -0,0 +1,104 @@ +# Copyright 1999-2009 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/media-video/smplayer/smplayer-0.6.8.ebuild,v 1.1 2009/07/26 13:14:37 yngwin Exp $ + +EAPI=2 +inherit eutils qt4 + +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.sourceforge.net" +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~hppa ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd" +IUSE="debug" + +DEPEND="x11-libs/qt-gui:4" +RDEPEND="${DEPEND} + media-video/mplayer[ass,png]" + +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_PT sk sr sv tr zh_CN zh_TW" +# langs with long notation in pkg, but no long notation in portage: +NOLONGLANGS="ar_SY el_GR ro_RO ru_RU sl_SI uk_UA vi_VN" +for X in ${LANGS}; do + IUSE="${IUSE} linguas_${X}" +done +for X in ${NOLONGLANGS}; do + IUSE="${IUSE} linguas_${X%_*}" +done + +src_prepare() { + # 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 "emake failed" + + # 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 [[ " ${NOLONGLANGS} " == *" ${lang}_"* ]]; then + for x in ${NOLONGLANGS}; 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 "emake install failed" + prepalldocs +} |