/[gentoo-x86]/media-video/minitube/minitube-2.4.ebuild
Gentoo

Contents of /media-video/minitube/minitube-2.4.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.4 - (show annotations) (download)
Sun May 10 13:05:17 2015 UTC (3 years, 2 months ago) by pesa
Branch: MAIN
CVS Tags: HEAD
Changes since 1.3: +2 -2 lines
Add missing usedep for qtsingleapplication.

(Portage version: 2.2.18/cvs/Linux x86_64, signed Manifest commit with key 0xDADED6B2671CB57D!)

1 # Copyright 1999-2015 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/media-video/minitube/minitube-2.4.ebuild,v 1.3 2015/04/26 10:22:07 hwoarang Exp $
4
5 EAPI=5
6 PLOCALES="ar ca ca_ES da de_DE el en es es_AR es_ES fi fi_FI fr he_IL hr hu
7 ia it jv nl pl pl_PL pt_BR ro ru sk sl tr zh_CN"
8 PLOCALE_BACKUP="en"
9
10 inherit l10n qt4-r2
11
12 DESCRIPTION="Qt4 YouTube Client"
13 HOMEPAGE="http://flavio.tordini.org/minitube"
14 SRC_URI="https://github.com/flaviotordini/${PN}/archive/${PV}.tar.gz ->
15 ${P}.tar.gz"
16
17 LICENSE="GPL-3"
18 SLOT="0"
19 KEYWORDS="~amd64 ~x86"
20 IUSE="debug download gstreamer kde"
21
22 DEPEND=">=dev-qt/qtgui-4.8:4[accessibility]
23 >=dev-qt/qtdbus-4.8:4
24 >=dev-qt/qtsql-4.8:4
25 dev-qt/qtsingleapplication[qt4(+),X]
26 kde? ( || ( media-libs/phonon[gstreamer?,qt4] >=dev-qt/qtphonon-4.8:4 ) )
27 !kde? ( || ( >=dev-qt/qtphonon-4.8:4 media-libs/phonon[gstreamer?,qt4] ) )
28 gstreamer? (
29 media-plugins/gst-plugins-soup:0.10
30 media-plugins/gst-plugins-ffmpeg:0.10
31 media-plugins/gst-plugins-faac:0.10
32 media-plugins/gst-plugins-faad:0.10
33 media-plugins/gst-plugins-theora
34 )
35 "
36 RDEPEND="${DEPEND}"
37
38 DOCS="AUTHORS CHANGES TODO"
39
40 #455976
41 PATCHES=( "${FILESDIR}"/${P}-disable-updates.patch )
42
43 pkg_pretend() {
44 if [[ -z ${MINITUBE_GOOGLE_API_KEY} ]]; then
45 eerror ""
46 eerror "Since version 2.4, you need to generate a Google API Key to use"
47 eerror "with this application. Please head over to"
48 eerror "https://console.developers.google.com/ and"
49 eerror "https://github.com/flaviotordini/minitube/blob/master/README.md"
50 eerror "for more information. Once you have generated your key,"
51 eerror "please export it to your environment ie :"
52 eerror "'export MINITUBE_GOOGLE_API_KEY=\"YourAPIKeyHere\""
53 eerror "and then try to merge this package again"
54 eerror ""
55 die "MINITUBE_GOOGLE_API_KEY env variable not defined!"
56 fi
57 }
58
59 src_prepare() {
60 qt4-r2_src_prepare
61
62 # Remove unneeded translations
63 local trans=
64 for x in $(l10n_get_locales); do
65 trans+="${x}.ts "
66 done
67 if [[ -n ${trans} ]]; then
68 sed -i -e "/^TRANSLATIONS/s/+=.*/+=${trans}/" locale/locale.pri || die
69 fi
70 sed -i \
71 's|include(src/qtsingleapplication/qtsingleapplication.pri)|CONFIG += qtsingleapplication|g' \
72 ${PN}.pro || die "Failed to unbundle qtsingleapplication"
73 # Enable video downloads. Bug #491344
74 use download && { echo "DEFINES += APP_DOWNLOADS" >> ${PN}.pro; }
75 echo "DEFINES += APP_GOOGLE_API_KEY=${MINITUBE_GOOGLE_API_KEY}" >> ${PN}.pro
76 }
77
78 src_install() {
79 qt4-r2_src_install
80 newicon images/app.png minitube.png
81 }
82
83 pkg_postinst() {
84 if use download; then
85 elog "You activated the 'download' USE flag. This allows you to"
86 elog "download videos from youtube, which might violate the youtube"
87 elog "terms-of-service (TOS) in some legislations. If downloading"
88 elog "youtube-videos is not allowed in your legislation, please"
89 elog "disable the 'download' use flag. For details on the youtube TOS,"
90 elog "see http://www.youtube.com/t/terms"
91 fi
92 }

  ViewVC Help
Powered by ViewVC 1.1.20