summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarkos Chandras <hwoarang@gentoo.org>2010-05-24 22:24:42 +0000
committerMarkos Chandras <hwoarang@gentoo.org>2010-05-24 22:24:42 +0000
commitcfdec72c7d6857085317a40cc562e17a95cd3b13 (patch)
tree6b6aba697f3b894193636f8def085c961ed8d3ff /media-sound
parentFix build with GCC 4.5 wrt bug #320377 (diff)
downloadgentoo-2-cfdec72c7d6857085317a40cc562e17a95cd3b13.tar.gz
gentoo-2-cfdec72c7d6857085317a40cc562e17a95cd3b13.tar.bz2
gentoo-2-cfdec72c7d6857085317a40cc562e17a95cd3b13.zip
Version bump. Ebuild was almost rewritten. Use debian tarballs+patches.Fixes plugin installation. Fixes bug #321211
(Portage version: 2.2_rc67/cvs/Linux x86_64)
Diffstat (limited to 'media-sound')
-rw-r--r--media-sound/lastfmplayer/ChangeLog12
-rw-r--r--media-sound/lastfmplayer/files/fix_plugin_path.patch13
-rw-r--r--media-sound/lastfmplayer/lastfmplayer-1.5.4.26862.ebuild109
3 files changed, 132 insertions, 2 deletions
diff --git a/media-sound/lastfmplayer/ChangeLog b/media-sound/lastfmplayer/ChangeLog
index 01e8da10f6cf..d27a51c96fad 100644
--- a/media-sound/lastfmplayer/ChangeLog
+++ b/media-sound/lastfmplayer/ChangeLog
@@ -1,6 +1,14 @@
# ChangeLog for media-sound/lastfmplayer
-# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/media-sound/lastfmplayer/ChangeLog,v 1.41 2009/11/02 20:59:37 maekke Exp $
+# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/media-sound/lastfmplayer/ChangeLog,v 1.42 2010/05/24 22:24:42 hwoarang Exp $
+
+*lastfmplayer-1.5.4.26862 (24 May 2010)
+
+ 24 May 2010; Markos Chandras <hwoarang@gentoo.org>
+ +lastfmplayer-1.5.4.26862.ebuild, +files/fix_plugin_path.patch:
+ Version bump. Ebuild almost have been rewritten. Use debian tarball and
+ patches + a custom patch to install plugins into different location and
+ support multilib profiles. Fixes bug #321211 as well.
02 Nov 2009; Markus Meier <maekke@gentoo.org>
lastfmplayer-1.5.1.31879-r3.ebuild:
diff --git a/media-sound/lastfmplayer/files/fix_plugin_path.patch b/media-sound/lastfmplayer/files/fix_plugin_path.patch
new file mode 100644
index 000000000000..c4fd5ae522b4
--- /dev/null
+++ b/media-sound/lastfmplayer/files/fix_plugin_path.patch
@@ -0,0 +1,13 @@
+Index: lastfm-1.5.4.26862+dfsg/src/libMoose/MooseCommon.cpp
+===================================================================
+--- lastfm-1.5.4.26862+dfsg.orig/src/libMoose/MooseCommon.cpp
++++ lastfm-1.5.4.26862+dfsg/src/libMoose/MooseCommon.cpp
+@@ -112,7 +112,7 @@ servicePath( QString name )
+ // Hack to get it working with VS2005
+ dirPath = qApp->applicationDirPath();
+ #else
+- dirPath = qApp->applicationDirPath() + "/services";
++ dirPath = "/usr/lib/services";
+ #endif
+
+ #ifndef QT_NO_DEBUG
diff --git a/media-sound/lastfmplayer/lastfmplayer-1.5.4.26862.ebuild b/media-sound/lastfmplayer/lastfmplayer-1.5.4.26862.ebuild
new file mode 100644
index 000000000000..df19f31efd86
--- /dev/null
+++ b/media-sound/lastfmplayer/lastfmplayer-1.5.4.26862.ebuild
@@ -0,0 +1,109 @@
+# Copyright 1999-2010 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/media-sound/lastfmplayer/lastfmplayer-1.5.4.26862.ebuild,v 1.1 2010/05/24 22:24:42 hwoarang Exp $
+
+EAPI=2
+inherit eutils multilib toolchain-funcs qt4-r2
+
+MY_P="${P/lastfmplayer/lastfm}+dfsg"
+
+DESCRIPTION="A player for last.fm radio streams"
+HOMEPAGE="http://www.last.fm/help/player"
+SRC_URI="mirror://debian/pool/main/l/lastfm/lastfm_${PV}+dfsg.orig.tar.gz
+ mirror://debian/pool/main/l/lastfm/lastfm_${PV}+dfsg-3.debian.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~x86"
+IUSE="ipod"
+RESTRICT="mirror"
+
+RDEPEND="x11-libs/qt-gui:4
+ x11-libs/qt-sql:4
+ media-libs/libsamplerate
+ sci-libs/fftw
+ media-libs/libmad
+ ipod? ( >=media-libs/libgpod-0.5.2 )
+ media-libs/alsa-lib"
+DEPEND="${RDEPEND}
+ app-arch/sharutils"
+
+S=${WORKDIR}/${MY_P}
+
+src_prepare() {
+ qt4-r2_src_prepare
+ epatch "${FILESDIR}"/fix_plugin_path.patch
+ einfo "Applying Debian patchset"
+ ebegin "Disabling tray-icon-size patch"
+ sed -i "/^tray-icon-size.diff/d" "${WORKDIR}"/debian/patches/series
+ eend $?
+ cd "${S}"
+ for i in $( < "${WORKDIR}"/debian/patches/series); do
+ epatch "${WORKDIR}"/debian/patches/$i
+ done
+ if ! use ipod ; then
+ sed -i '/src\/mediadevices\/ipod/d' LastFM.pro || die "sed failed"
+ fi
+ #don't install plugins into generic location
+ sed -i "s:\$\$BIN_DIR/services:\$\$BIN_DIR/lastfm_services:" \
+ "${S}"/definitions.pro.inc
+ #fix plugin search path
+ sed -i "s:/usr/lib/services:/usr/$(get_libdir)/lastfm_services:" \
+ "${S}"/src/libMoose/MooseCommon.cpp
+}
+
+src_compile() {
+ emake CC="$(tc-getCC)" CXX="$(tc-getCXX)" || die "emake failed"
+ cd i18n; lrelease *.ts
+}
+
+src_install() {
+ cd "${WORKDIR}"
+ # Docs
+ dodoc "${S}"/ChangeLog "${S}"/README debian/README.source \
+ || die "dodoc failed"
+ doman debian/lastfm.1 || die "doman failed"
+
+ # Copied from debian/rules
+ insinto /usr/share
+ doins -r debian/package-files/share/icons || die "failed to install icons"
+ insinto /usr/share/lastfm/icons
+ doins "${S}"/bin/data/icons/*.png \
+ || die "failed to install application icons"
+ insinto /usr/share/lastfm
+ doins "${S}"/bin/data/*.png || die "failed to install icons"
+ dodir /usr/$(get_libdir)/lastfm_services/
+ insinto /usr/$(get_libdir)/lastfm_services/
+ insopts -m0755
+ doins -r "${S}"/bin/lastfm_services/*.so || die "failed to install plugins"
+ insinto /usr/$(get_libdir)
+ insopts -m0755
+ doins "${S}"/bin/libLastFmTools.so.1* || die "failed to install library"
+ doins "${S}"/bin/libMoose.so.1* || die "failed to install library"
+ #fix symlinks
+ cd "${D}"/usr/$(get_libdir)/
+ ln -sfn libLastFmTools.so.1.0.0 libLastFmTools.so.1
+ ln -sfn libLastFmTools.so.1.0.0 libLastFmTools.so.1.0
+ ln -sfn libMoose.so.1.0.0 libMoose.so.1
+ ln -sfn libMoose.so.1.0.0 libMoose.so.1.0
+ cd "${WORKDIR}"
+ newbin "${S}"/bin/last.fm lastfm || die "newbin failed"
+ insinto /usr/share/lastfm/i18n
+ doins "${S}"/i18n/*.qm || die "failed to install translations"
+ fperms 755 /usr/bin/lastfm
+ rm -f "${D}"/usr/share/lastfm/icons/{*profile24,systray_mac}.png
+ # create desktop entry
+ doicon "${WORKDIR}"/debian/package-files/share/icons/hicolor/48x48/apps/lastfm.png
+ make_desktop_entry lastfm "Last.fm Player" lastfm
+}
+
+pkg_postinst() {
+ elog "To use the Last.fm player with a mozilla based browser:"
+ elog " 1. Go to about:config in the browser"
+ elog " 2. Right-click on the page"
+ elog " 3. Select New and then String"
+ elog " 4. For the name: network.protocol-handler.app.lastfm"
+ elog " 5. For the value: /usr/bin/lastfm"
+ elog
+ elog "If you experience awkward fonts or widgets, try running qtconfig."
+}