blob: cc9efbdf81d55a707a04f034c4b425922480c44e (
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
|
# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/media-sound/beets/beets-1.0_beta14-r1.ebuild,v 1.4 2012/05/30 16:48:29 xarthisius Exp $
EAPI="4"
PYTHON_DEPEND="2:2.6"
PYTHON_USE_WITH="sqlite"
SUPPORT_PYTHON_ABIS="1"
#There a few test failures with 2.6, worth investigating
RESTRICT_PYTHON_ABIS="2.5 3.* 2.7-pypy-*"
inherit distutils
MY_PV=${PV/_beta/b}
MY_P=${PN}-${MY_PV}
DESCRIPTION="A media library management system for obsessive-compulsive music geeks"
SRC_URI="http://beets.googlecode.com/files/${MY_P}.tar.gz"
HOMEPAGE="http://beets.radbox.org/"
KEYWORDS="~amd64 ~x86"
SLOT="0"
LICENSE="MIT"
IUSE="chroma doc lastgenre bpd replaygain web"
RDEPEND="
dev-python/munkres
dev-python/python-musicbrainz-ngs
dev-python/unidecode
media-libs/mutagen
chroma? ( dev-python/pyacoustid )
lastgenre? ( dev-python/pylast )
bpd? ( dev-python/bluelet )
replaygain? ( media-sound/rgain )
web? ( dev-python/flask )
doc? ( dev-python/sphinx )"
DEPEND="${RDEPEND}
dev-python/setuptools"
S=${WORKDIR}/${MY_P}
src_prepare() {
distutils_src_prepare
# remove plugins that do not have appropriate dependencies installed
for flag in lastgenre bpd web chroma replaygain;do
if ! use $flag ; then
rm -r beetsplug/$flag* || \
die "Unable to remove $flag plugin"
fi
done
for flag in lastgenre bpd web;do
if ! use $flag ; then
sed -i "s:'beetsplug.$flag',::" setup.py || \
die "Unable to disable $flag plugin "
fi
done
use bpd || rm -f test/test_player.py
}
src_compile() {
distutils_src_compile
use doc && emake -C docs html
}
src_test() {
cd test
testing() {
PYTHONPATH="../build-${PYTHON_ABI}/lib" "$(PYTHON)" testall.py
}
python_execute_function testing
}
src_install() {
distutils_src_install
doman man/beet.1 man/beetsconfig.5
use doc && dohtml -r docs/_build/html/
}
|