/[gentoo-x86]/dev-python/pyzor/pyzor-0.5.0-r2.ebuild
Gentoo

Contents of /dev-python/pyzor/pyzor-0.5.0-r2.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.9 - (show annotations) (download)
Wed Mar 19 13:56:07 2014 UTC (6 years, 4 months ago) by ago
Branch: MAIN
CVS Tags: HEAD
Changes since 1.8: +2 -2 lines
Stable for alpha, wrt bug #498050

(Portage version: 2.2.8-r1/cvs/Linux x86_64, RepoMan options: --include-arches="alpha", signed Manifest commit with key 7194459F)

1 # Copyright 1999-2014 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.5.0-r2.ebuild,v 1.8 2014/01/26 12:23:16 ago Exp $
4
5 EAPI="3"
6 PYTHON_DEPEND="2"
7 PYTHON_USE_WITH="gdbm"
8 PYTHON_USE_WITH_OPT="pyzord"
9 SUPPORT_PYTHON_ABIS="1"
10 RESTRICT_PYTHON_ABIS="3.*"
11
12 inherit distutils eutils
13
14 DESCRIPTION="A distributed, collaborative spam detection and filtering network"
15 HOMEPAGE="http://pyzor.sourceforge.net/"
16 SRC_URI="mirror://sourceforge/${PN}/${P}.tar.bz2"
17
18 LICENSE="GPL-2"
19 SLOT="0"
20 KEYWORDS="alpha amd64 hppa ia64 ppc ppc64 sparc x86"
21 IUSE="pyzord"
22
23 DEPEND=""
24 RDEPEND=""
25
26 DOCS="THANKS UPGRADING"
27
28 src_prepare() {
29 epatch "${FILESDIR}/pyzord_getopt.patch"
30 epatch "${FILESDIR}/${P}-python26_warnings.patch"
31
32 # rfc822BodyCleanerTest doesn't work fine.
33 # Remove it until it's fixed.
34 sed -i \
35 -e '/rfc822BodyCleanerTest/,/self\.assertEqual/d' \
36 unittests.py || die "sed in unittest.py failed"
37 }
38
39 src_test() {
40 testing() {
41 PYTHONPATH="build-${PYTHON_ABI}/lib" "$(PYTHON)" unittests.py
42 }
43 python_execute_function testing
44 }
45
46 src_install () {
47 distutils_src_install
48
49 dohtml docs/usage.html
50 rm -rf "${ED}usr/share/doc/pyzor"
51
52 if use pyzord; then
53 dodir /usr/sbin
54 mv "${ED}"usr/bin/pyzord* "${ED}usr/sbin"
55 else
56 rm "${ED}"usr/bin/pyzord*
57 fi
58 }
59
60 pkg_postinst() {
61 distutils_pkg_postinst
62
63 if use pyzord; then
64 ewarn "/usr/bin/pyzord has been moved to /usr/sbin"
65 fi
66 }

  ViewVC Help
Powered by ViewVC 1.1.20