/[gentoo-x86]/dev-python/astng/astng-0.23.1-r1.ebuild
Gentoo

Contents of /dev-python/astng/astng-0.23.1-r1.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.3 - (show annotations) (download)
Mon Aug 26 11:36:28 2013 UTC (7 years ago) by djc
Branch: MAIN
CVS Tags: HEAD
Changes since 1.2: +1 -1 lines
FILE REMOVED
Remove old versions.

(Portage version: 2.2.1/cvs/Linux x86_64, signed Manifest commit with key 6B065BFB)

1 # Copyright 1999-2012 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/dev-python/astng/astng-0.23.1-r1.ebuild,v 1.2 2012/08/27 15:20:01 floppym Exp $
4
5 EAPI="4"
6 SUPPORT_PYTHON_ABIS="1"
7 PYTHON_TESTS_RESTRICTED_ABIS="3.* *-jython *-pypy-*"
8
9 inherit distutils eutils
10
11 DESCRIPTION="Abstract Syntax Tree New Generation for logilab packages"
12 HOMEPAGE="http://www.logilab.org/project/logilab-astng http://pypi.python.org/pypi/logilab-astng"
13 SRC_URI="ftp://ftp.logilab.org/pub/astng/logilab-${P}.tar.gz mirror://pypi/l/logilab-astng/logilab-${P}.tar.gz"
14
15 LICENSE="LGPL-2.1"
16 SLOT="0"
17 KEYWORDS="~amd64 ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x64-macos ~x86-macos"
18 IUSE="test"
19
20 # Version specified in __pkginfo__.py.
21 RDEPEND=">=dev-python/logilab-common-0.53.0"
22 DEPEND="${RDEPEND}
23 dev-python/setuptools
24 test? ( >=dev-python/egenix-mx-base-3.0.0 )"
25
26 S="${WORKDIR}/logilab-${P}"
27 PYTHON_MODNAME="logilab/astng"
28 DISTUTILS_USE_SEPARATE_SOURCE_DIRECTORIES="1"
29
30 src_prepare() {
31 epatch "${FILESDIR}/${P}-file-open.patch"
32 distutils_src_prepare
33 }
34
35 src_test() {
36 testing() {
37 local tpath="${T}/test-${PYTHON_ABI}"
38 local spath="${tpath}$(python_get_sitedir)"
39
40 mkdir -p "${spath}/logilab" || return 1
41 cp -r "$(python_get_sitedir)/logilab/common" "${spath}/logilab" || return 1
42
43 "$(PYTHON)" setup.py build -b build install --root="${tpath}" ||
44 die "Installation for tests failed with $(python_get_implementation_and_version)"
45
46 # pytest uses tests placed relatively to the current directory.
47 pushd "${spath}/logilab/astng" > /dev/null || return 1
48 PYTHONPATH="${spath}" pytest -v || return 1
49 popd > /dev/null || return 1
50 }
51 python_execute_function -s testing
52 }
53
54 src_install() {
55 distutils_src_install
56
57 deletion_of_unneeded_files() {
58 # Avoid collision with dev-python/logilab-common.
59 rm -f "${ED}$(python_get_sitedir)/logilab/__init__.py" || return 1
60
61 # Don't install tests.
62 rm -fr "${ED}$(python_get_sitedir)/logilab/astng/test" || return 1
63 }
64 python_execute_function -q deletion_of_unneeded_files
65 }

  ViewVC Help
Powered by ViewVC 1.1.20