/[gentoo-x86]/media-sound/qmpdclient/qmpdclient-1.1.2.ebuild
Gentoo

Contents of /media-sound/qmpdclient/qmpdclient-1.1.2.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.6 - (show annotations) (download)
Wed Feb 2 09:42:02 2011 UTC (9 years, 10 months ago) by hwoarang
Branch: MAIN
CVS Tags: HEAD
Changes since 1.5: +1 -1 lines
FILE REMOVED
remove old ebuild

(Portage version: 2.2.0_alpha19/cvs/Linux x86_64)

1 # Copyright 1999-2010 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/media-sound/qmpdclient/qmpdclient-1.1.2.ebuild,v 1.5 2010/01/14 12:33:46 fauli Exp $
4
5 EAPI="2"
6
7 inherit qt4
8
9 DESCRIPTION="QMPDClient with NBL additions, such as lyrics' display"
10 HOMEPAGE="http://bitcheese.net/wiki/QMPDClient"
11 SRC_URI="http://dump.bitcheese.net/files/dedycec/${P}.tar.bz2"
12
13 LICENSE="GPL-2"
14 SLOT="0"
15 KEYWORDS="amd64 hppa ppc ~sparc x86"
16 IUSE="debug dbus"
17
18 DEPEND="x11-libs/qt-gui:4[dbus?,debug?]"
19 RDEPEND="${DEPEND}"
20
21 LANGSNOLONG="cs_CZ de_DE fr_FR it_IT nl_NL nn_NO no_NO ru_RU sv_SE tr_TR uk_UA"
22 LANGS="zh_CN zh_TW pt_BR "
23
24 for X in ${LANGSNOLONG}; do
25 IUSE="${IUSE} linguas_${X%_*}"
26 done
27
28 for X in ${LANGS};do
29 IUSE="${IUSE} linguas_${X}"
30 done
31
32 S="${WORKDIR}/${PN}"
33
34 src_prepare() {
35 # Fix the install path
36 sed -i -e "s:PREFIX = /usr/local:PREFIX = /usr:" ${PN}.pro \
37 || die "sed failed (install path)"
38
39 # Fix package version
40 sed -i -e "s:1.1.1:${PV}:" ${PN}.pro || die "failed to fix package version"
41 # nostrip fix
42 sed -i -e "s:CONFIG += :CONFIG += nostrip :" ${PN}.pro \
43 || die "sed failed (nostrip)"
44
45 sed -i -e "s:+= -O2 -g0 -s:+= -O2 -g0:" ${PN}.pro \
46 || die "sed failed (nostrip)"
47
48 # fix installation folder name
49 sed -i "s/share\/QMPDClient/share\/qmpdclient/" ${PN}.pro src/config.cpp \
50 || die "failed to fix installation directory"
51
52 # check dbus
53 if ! use dbus; then
54 sed -i -e "s/message(DBus notifier:\ enabled)/message(DBus notifier:\ disabled)/" \
55 -e "s/CONFIG\ +=\ nostrip\ qdbus//" \
56 -e "s/SOURCES\ +=\ src\/notifications_dbus.cpp/SOURCES\ +=\ src\/notifications_nodbus.cpp/" \
57 ${PN}.pro || die "disabling dbus failed"
58 fi
59 }
60
61 src_configure() {
62 eqmake4 qmpdclient.pro
63 }
64
65 src_compile() {
66 emake || die "emake failed"
67 # generate translations
68 emake translate || die "failed to generate translations"
69 cd "${S}"/lang
70 for X in *.ts;do
71 lrelease "${X}" || die "lrelease failed"
72 done
73 }
74
75 src_install() {
76 emake install INSTALL_ROOT="${D}" || die "emake install failed"
77 dodoc README AUTHORS THANKSTO Changelog || die "Installing docs failed"
78 for res in 16 22 64 ; do
79 insinto /usr/share/icons/hicolor/${res}x${res}/apps/
80 newins icons/qmpdclient${res}.png ${PN}.png || die "Installing icons failed"
81 done
82
83 #install translations
84 insinto /usr/share/${PN}/translations/
85 local LANG=
86 for LANG in ${LINGUAS};do
87 for X in ${LANGSNOLONG};do
88 if [[ ${LANG} == ${X%_*} ]];then
89 doins -r lang/${X}.qm || die "failed to install translations"
90 fi
91 done
92 for X in ${LANGS};do
93 if [[ ${LANG} == ${X} ]]; then
94 doins -r lang/${X}.qm || die "failed to install translations"
95 fi
96 done
97 done
98 }

  ViewVC Help
Powered by ViewVC 1.1.20