/[gentoo-x86]/dev-python/testtools/testtools-0.9.24.ebuild
Gentoo

Contents of /dev-python/testtools/testtools-0.9.24.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (show annotations) (download)
Sun Jan 13 12:47:55 2013 UTC (17 months, 4 weeks ago) by fauli
Branch: MAIN
version bump

(Portage version: 2.1.11.31/cvs/Linux i686, signed Manifest commit with key 2B859DE3)

1 # Copyright 1999-2013 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/dev-python/testtools/testtools-0.9.16.ebuild,v 1.2 2012/10/12 00:50:23 floppym Exp $
4
5 EAPI="4"
6 PYTHON_DEPEND="*:2.6"
7 RESTRICT_PYTHON_ABIS="2.5"
8 SUPPORT_PYTHON_ABIS="1"
9 DISTUTILS_SRC_TEST="setup.py"
10 inherit distutils versionator
11
12 SERIES="$(get_version_component_range 1-2)"
13
14 DESCRIPTION="Extensions to the Python unittest library"
15 HOMEPAGE="https://launchpad.net/testtools http://pypi.python.org/pypi/testtools"
16 SRC_URI="http://launchpad.net/${PN}/${SERIES}/${PV}/+download/${P}.tar.gz"
17
18 LICENSE="MIT"
19 SLOT="0"
20 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd"
21 IUSE=""
22
23 DEPEND=""
24 RDEPEND=""
25
26 src_compile() {
27 distutils_src_compile
28
29 if [[ ! -e testtools/_compat2x.py ]]; then
30 die "_compat2x.py removed upstream; fix src_compile"
31 fi
32
33 fix_compat() {
34 # _compat2x.py is expected to have syntax incompatible with python 3.
35 # This breaks compileall. Replace with "raise SyntaxError".
36 if [[ $(python_get_version -l --major) == 3 ]]; then
37 echo "raise SyntaxError" > build-${PYTHON_ABI}/lib/testtools/_compat2x.py
38 fi
39 }
40 python_execute_function -q fix_compat
41 }
42
43 # dev-python/subunit imports some objects from testtools.tests.helpers, so
44 # tests need to be installed.

  ViewVC Help
Powered by ViewVC 1.1.20