blob: cf2307b3face3b182bfc7b3d609ae7279aa85496 (
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
|
# Copyright 1999-2011 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/sys-fs/pysize/pysize-0.2.ebuild,v 1.3 2011/03/08 23:21:18 hwoarang Exp $
EAPI="3"
PYTHON_DEPEND="2"
SUPPORT_PYTHON_ABIS="1"
RESTRICT_PYTHON_ABIS="3.*"
inherit distutils eutils
DESCRIPTION="A graphical and console tool for exploring the size of directories"
HOMEPAGE="http://guichaz.free.fr/pysize/"
SRC_URI="http://guichaz.free.fr/${PN}/files/${P}.tar.bz2"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="amd64 ~x86 ~amd64-linux ~x86-linux"
IUSE="gtk ncurses psyco"
DEPEND="
gtk? ( dev-python/pygtk:2 )
ncurses? ( sys-libs/ncurses )
psyco? ( dev-python/psyco )"
RDEPEND="${DEPEND}"
src_prepare() {
if ! use gtk; then
sed -e '/^from pysize.ui.gtk/d' \
-e "s~'gtk': ui_gtk.run,~~g" \
-e 's:ui_gtk.run,::g' \
-i pysize/main.py || die "Failed to remove gtk support"
rm -rf pysize/ui/gtk || die "Failed to remove gtk support"
fi
if ! use ncurses; then
sed -e '/^from pysize.ui.curses/d' \
-e "s~'curses': ui_curses.run,~~g" \
-e 's:ui_curses.run,::g' \
-i pysize/main.py || die "Failed to remove ncurses support"
rm -rf pysize/ui/curses || die "Failed to remove ncurses support"
fi
use psyco || epatch "${FILESDIR}/psyco-${PV}"-automagic.patch
epatch "${FILESDIR}"/${PV}-setuptools-automagic.patch
distutils_src_prepare
}
|