summaryrefslogtreecommitdiff
blob: 97ae289062c63accb1be3854377d33198b7cb9bb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
# Copyright 1999-2006 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/net-p2p/transmission/transmission-0.6.1.ebuild,v 1.2 2006/08/15 23:58:18 squinky86 Exp $

inherit eutils

MY_PN="${PN/t/T}"
MY_P=${MY_PN}-${PV}

DESCRIPTION="a lightweight BitTorrent client"
HOMEPAGE="http://transmission.m0k.org/"
SRC_URI="http://download.m0k.org/transmission/files/${MY_P}.tar.gz"

LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="gtk ssl"

DEPEND="sys-devel/gettext
	gtk? ( >=x11-libs/gtk+-2.6 )
	ssl? ( dev-libs/openssl )"

S="${WORKDIR}/${MY_P}"

src_unpack() {
	unpack ${A}
	cd ${S}
	epatch ${FILESDIR}/${PV}-configure.patch
}

src_compile() {
	econf $(use_enable ssl openssl) \
		$(use_enable gtk) || die "configure failed"
	emake || die "make failed"
}

src_install() {
	dobin cli/transmissioncli

	if use gtk ; then
		dobin gtk/transmission-gtk

		doicon "${FILESDIR}/transmission.png"
		make_desktop_entry "transmission-gtk" "${MY_PN}" "${PN}.png" \
			"Network;Internet;GNOME;GTK;X-Red-Hat-Base"
	fi
	dodoc AUTHORS NEWS README
}