| 1 |
# Copyright 1999-2012 Gentoo Foundation
|
| 2 |
# Distributed under the terms of the GNU General Public License v2
|
| 3 |
# $Header: /var/cvsroot/gentoo-x86/net-p2p/tribler/tribler-5.9.17.ebuild,v 1.1 2012/06/28 11:21:44 blueness Exp $
|
| 4 |
|
| 5 |
EAPI="4"
|
| 6 |
PYTHON_DEPEND="2"
|
| 7 |
PYTHON_USE_WITH="sqlite"
|
| 8 |
|
| 9 |
inherit eutils python
|
| 10 |
|
| 11 |
MY_PV="${PN}_${PV}-1ubuntu1_all"
|
| 12 |
|
| 13 |
DESCRIPTION="Bittorrent client that does not require a website to discover content"
|
| 14 |
HOMEPAGE="http://www.tribler.org/"
|
| 15 |
SRC_URI="http://dl.tribler.org/${MY_PV}.deb"
|
| 16 |
|
| 17 |
LICENSE="LGPL-2.1"
|
| 18 |
SLOT="0"
|
| 19 |
KEYWORDS="~amd64 ~x86"
|
| 20 |
IUSE="vlc"
|
| 21 |
|
| 22 |
RDEPEND="
|
| 23 |
>=dev-python/apsw-3.6
|
| 24 |
>=dev-python/m2crypto-0.16
|
| 25 |
dev-python/netifaces
|
| 26 |
>=dev-libs/openssl-0.9.8
|
| 27 |
>=dev-python/wxpython-2.8
|
| 28 |
vlc? ( >=media-video/vlc-1.1.0 )"
|
| 29 |
|
| 30 |
# Skipping for now:
|
| 31 |
# xulrunner-sdk >= 1.9.1.5 < 1.9.2 (optional, to run SwarmTransport)
|
| 32 |
# 7-Zip >= 4.6.5 (optional, to build SwarmTransport)
|
| 33 |
|
| 34 |
DEPEND="${RDEPEND}
|
| 35 |
app-arch/unzip"
|
| 36 |
|
| 37 |
S=${WORKDIR}
|
| 38 |
|
| 39 |
pkg_setup() {
|
| 40 |
python_set_active_version 2
|
| 41 |
python_pkg_setup
|
| 42 |
}
|
| 43 |
|
| 44 |
src_unpack() {
|
| 45 |
unpack ${A}
|
| 46 |
unpack ./data.tar.gz
|
| 47 |
}
|
| 48 |
|
| 49 |
src_prepare() {
|
| 50 |
epatch "${FILESDIR}/${PN}-5.9.12-fix-global-declarations.patch"
|
| 51 |
epatch "${FILESDIR}/${PN}-log2homedir.patch"
|
| 52 |
|
| 53 |
python_convert_shebangs -r 2 .
|
| 54 |
}
|
| 55 |
|
| 56 |
src_compile() { :; }
|
| 57 |
|
| 58 |
src_install() {
|
| 59 |
#Rename the doc dir properly
|
| 60 |
mv usr/share/doc/${PN} usr/share/doc/${P}
|
| 61 |
|
| 62 |
#Move the readme to the doc dir
|
| 63 |
mv usr/share/${PN}/Tribler/readme.txt usr/share/doc/${P}
|
| 64 |
|
| 65 |
#Remove the licenses scattered throughout
|
| 66 |
rm usr/share/doc/${P}/copyright
|
| 67 |
rm usr/share/${PN}/Tribler/*.txt
|
| 68 |
rm usr/share/${PN}/Tribler/Core/DecentralizedTracking/pymdht/{LGPL-2.1.txt,LICENSE.txt}
|
| 69 |
|
| 70 |
#Copy the rest over
|
| 71 |
cp -pPR usr/ "${ED}"/
|
| 72 |
}
|
| 73 |
|
| 74 |
pkg_postinst() {
|
| 75 |
python_mod_optimize "${ROOT}"usr/share/${PN}
|
| 76 |
}
|
| 77 |
|
| 78 |
pkg_postrm() {
|
| 79 |
python_mod_cleanup "${ROOT}"usr/share/${PN}
|
| 80 |
}
|