]> Pileus Git - ~andy/sunrise/blob - media-video/qnapi/qnapi-0.1.6_rc2.ebuild
media-video/qnapi: Properly fix qt deps
[~andy/sunrise] / media-video / qnapi / qnapi-0.1.6_rc2.ebuild
1 # Copyright 1999-2012 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: $
4
5 EAPI="4"
6 KDE_REQUIRED="optional"
7 CMAKE_REQUIRED="false"
8
9 inherit eutils gnome2-utils kde4-base qt4-r2
10
11 MY_P=${P/_rc/-rc}
12
13 DESCRIPTION="Automatic subtitle downloader using Napiprojekt database"
14 HOMEPAGE="http://krzemin.iglu.cz/software/qnapi"
15 SRC_URI="mirror://sourceforge/${PN}/${MY_P}.tar.gz"
16
17 LICENSE="GPL-2"
18 SLOT="0"
19 KEYWORDS="~amd64 ~x86"
20 IUSE="gnome"
21
22 S=${WORKDIR}/${MY_P}
23
24 DEPEND="dev-qt/qtcore:4
25         dev-qt/qtgui:4
26         gnome? ( gnome-base/gconf )"
27 RDEPEND="${DEPEND}
28         app-arch/p7zip"
29
30 # fix install paths, remove unneeded files, general cleanup
31 PATCHES=( "${FILESDIR}/${P}-gentoo.diff" )
32
33 pkg_setup() {
34         use kde && kde4-base_pkg_setup # get KDEDIR for KDE4
35 }
36
37 src_configure() {
38         local integr
39
40         use gnome && integr="gnome_integration"
41         use kde && integr="${integr} kde4_integration"
42         KDE4DIR="${KDEDIR}" INTEGRATION_TARGETS="${integr}" eqmake4
43 }
44
45 pkg_preinst() {
46         use gnome && gnome2_gconf_savelist
47 }
48
49 pkg_postinst() {
50         use gnome && gnome2_gconf_install
51         use kde && kde4-base_pkg_postinst
52 }
53
54 pkg_postrm() {
55         use kde && kde4-base_pkg_postrm
56 }