/[gentoo-x86]/dev-python/pyzor/pyzor-0.4.0-r3.ebuild
Gentoo

Contents of /dev-python/pyzor/pyzor-0.4.0-r3.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.13 - (show annotations) (download)
Fri Sep 4 17:52:44 2009 UTC (10 years, 11 months ago) by patrick
Branch: MAIN
CVS Tags: HEAD
Changes since 1.12: +1 -1 lines
FILE REMOVED
Remove old
(Portage version: 2.2_rc40/cvs/Linux x86_64)

1 # Copyright 1999-2007 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/dev-python/pyzor/pyzor-0.4.0-r3.ebuild,v 1.12 2007/07/06 16:17:15 corsair Exp $
4
5 inherit distutils eutils
6
7 DESCRIPTION="A distributed, collaborative spam detection and filtering network"
8 HOMEPAGE="http://pyzor.sourceforge.net/"
9 SRC_URI="mirror://sourceforge/${PN}/${P}.tar.bz2"
10
11 LICENSE="GPL-2"
12 SLOT="0"
13 KEYWORDS="alpha amd64 hppa ia64 ppc ppc64 sparc x86"
14 IUSE="pyzord"
15
16 DEPEND="dev-lang/python"
17
18 pkg_setup() {
19 if use pyzord ; then
20 if ! built_with_use 'dev-lang/python' gdbm ; then
21 die "you need to rebuild python with gdbm support"
22 fi
23 fi
24 }
25
26 src_unpack() {
27 unpack ${A}
28 cd "${S}"
29
30 epatch "${FILESDIR}/debian_mbox.patch"
31 epatch "${FILESDIR}/handle_unknown_encodings.patch"
32 epatch "${FILESDIR}/pyzord_getopt.patch"
33 epatch "${FILESDIR}/unknown_type.patch"
34
35 # rfc822BodyCleanerTest doesn't work fine
36 # remove it until it's fixed
37 sed -i \
38 -e '/rfc822BodyCleanerTest/,/self\.assertEqual/d' \
39 unittests.py || die "sed in unittest.py failed"
40 }
41
42 src_install () {
43 DOCS="INSTALL THANKS UPGRADING"
44 distutils_src_install
45 dohtml docs/usage.html
46 rm -rf "${D}/usr/share/doc/pyzor"
47
48 if use pyzord ; then
49 dodir /usr/sbin
50 mv "${D}/usr/bin/pyzord" "${D}/usr/sbin/"
51 fi
52 }
53
54 pkg_postinst() {
55 if use pyzord ; then
56 ewarn "/usr/bin/pyzord has been moved to /usr/sbin"
57 fi
58 }
59
60 src_test() {
61 PYTHONPATH=build/lib/ "${python}" unittests.py || die "tests failed"
62 }

  ViewVC Help
Powered by ViewVC 1.1.20