blob: 1699ef11452bc7a0e421dcd490f1acc093058d05 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
|
# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
PYTHON_COMPAT=( python3_{7,8,9} pypy3 )
DISTUTILS_USE_SETUPTOOLS=manual
inherit distutils-r1
DESCRIPTION="Virtual Python Environment builder"
HOMEPAGE="
https://virtualenv.pypa.io/en/stable/
https://pypi.org/project/virtualenv/
https://github.com/pypa/virtualenv/
"
SRC_URI="https://github.com/pypa/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="MIT"
#KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ppc ppc64 ~riscv sparc x86"
SLOT="0"
IUSE="test"
RESTRICT="!test? ( test )"
RDEPEND=">=dev-python/setuptools-19.6.2[${PYTHON_USEDEP}]"
BDEPEND="${RDEPEND}
test? (
>=dev-python/pip-19.3.1-r1[${PYTHON_USEDEP}]
dev-python/mock[${PYTHON_USEDEP}]
dev-python/pypiserver[${PYTHON_USEDEP}]
dev-python/pytest-localserver[${PYTHON_USEDEP}]
dev-python/pytest-timeout[${PYTHON_USEDEP}]
dev-python/pytest[${PYTHON_USEDEP}]
dev-python/six[${PYTHON_USEDEP}]
dev-python/wheel[${PYTHON_USEDEP}]
)"
DOCS=( docs/index.rst docs/changes.rst )
PATCHES=(
"${FILESDIR}/virtualenv-16.7.7-tests.patch"
# disable tests that need internet access
"${FILESDIR}/virtualenv-16.7.7-tests-internet.patch"
# test fixes for pypy
"${FILESDIR}/virtualenv-16.7.8-tests-pypy.patch"
)
distutils_enable_sphinx docs \
dev-python/sphinx_rtd_theme \
dev-python/towncrier
python_test() {
cp "${S}"/LICENSE.txt "${BUILD_DIR}"/lib || \
die "Could not copy LICENSE.txt with ${EPYTHON}"
pytest -vv tests || die "Tests fail with ${EPYTHON}"
}
pkg_postinst() {
elog "Please note that while virtualenv package no longer supports"
elog "Python 2.7, you can still create py2.7 virtualenvs via:"
elog " $ virtualenv -p /usr/bin/python2.7 ..."
}
|