/[gentoo-x86]/dev-python/routes/routes-2.0.ebuild
Gentoo

Contents of /dev-python/routes/routes-2.0.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (show annotations) (download)
Wed Dec 25 16:01:31 2013 UTC (9 months ago) by floppym
Branch: MAIN
CVS Tags: HEAD
Changes since 1.1: +5 -2 lines
Fix unicode error in setup.py, bug 495118.

(Portage version: 2.2.7/cvs/Linux x86_64, signed Manifest commit with key 0BBEEA1FEA4843A4)

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/routes/routes-2.0.ebuild,v 1.1 2013/11/21 20:53:58 radhermit Exp $
4
5 EAPI=5
6 PYTHON_COMPAT=( python{2_6,2_7,3_2,3_3} )
7
8 inherit distutils-r1
9
10 MY_PN="Routes"
11 MY_P="${MY_PN}-${PV}"
12
13 DESCRIPTION="A Python re-implementation of the Rails routes system for mapping URL's to Controllers/Actions"
14 HOMEPAGE="http://routes.groovie.org http://pypi.python.org/pypi/Routes"
15 SRC_URI="mirror://pypi/${MY_PN:0:1}/${MY_PN}/${MY_P}.tar.gz"
16
17 LICENSE="BSD"
18 SLOT="0"
19 KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos"
20 IUSE="doc test"
21
22 RDEPEND="dev-python/webob[${PYTHON_USEDEP}]
23 >=dev-python/repoze-lru-0.3[${PYTHON_USEDEP}]"
24 DEPEND="${RDEPEND}
25 dev-python/setuptools[${PYTHON_USEDEP}]
26 doc? ( dev-python/sphinx[${PYTHON_USEDEP}] )
27 test? (
28 dev-python/coverage[${PYTHON_USEDEP}]
29 dev-python/nose[${PYTHON_USEDEP}]
30 dev-python/webtest[${PYTHON_USEDEP}]
31 )"
32
33 S="${WORKDIR}/${MY_P}"
34
35 PATCHES=(
36 "${FILESDIR}"/${PN}-2.0-tests-py3.patch
37 "${FILESDIR}"/${PN}-2.0-setup.py.patch
38 )
39
40 python_prepare_all() {
41 use test && DISTUTILS_IN_SOURCE_BUILD=1
42 distutils-r1_python_prepare_all
43 }
44
45 python_compile_all() {
46 use doc && emake -C docs html
47 }
48
49 python_test() {
50 cp -r tests "${BUILD_DIR}" || die
51 if [[ ${EPYTHON} == python3* ]]; then
52 2to3 -w --no-diffs "${BUILD_DIR}"/tests || die
53 fi
54
55 nosetests -w "${BUILD_DIR}"/tests || die "Tests fail with ${EPYTHON}"
56 }
57
58 python_install_all() {
59 use doc && local HTML_DOCS=( docs/_build/html/. )
60 distutils-r1_python_install_all
61 }

  ViewVC Help
Powered by ViewVC 1.1.20