mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-08-31 09:08:08 -07:00
dev-python/setproctitle: Port to pypy3
Signed-off-by: Michał Górny <mgorny@gentoo.org>
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=7
|
||||
PYTHON_COMPAT=( python3_{6..9} )
|
||||
PYTHON_COMPAT=( python3_{6..9} pypy3 )
|
||||
|
||||
inherit distutils-r1 toolchain-funcs
|
||||
|
||||
@@ -13,21 +13,22 @@ SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
|
||||
LICENSE="BSD"
|
||||
SLOT="0"
|
||||
KEYWORDS="~alpha amd64 arm arm64 ~ia64 ppc ppc64 sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
|
||||
IUSE="test"
|
||||
RESTRICT="!test? ( test )"
|
||||
|
||||
RDEPEND=""
|
||||
DEPEND="dev-python/setuptools[${PYTHON_USEDEP}]
|
||||
test? ( dev-python/nose[${PYTHON_USEDEP}] )"
|
||||
|
||||
# Required for re-write of test suite
|
||||
DISTUTILS_IN_SOURCE_BUILD=1
|
||||
python_configure_all() {
|
||||
2to3 -w --no-diffs tests || die
|
||||
}
|
||||
|
||||
python_test() {
|
||||
# prepare embedded executable
|
||||
emake \
|
||||
CC="$(tc-getCC)" \
|
||||
PYINC="$(python_get_CFLAGS)" \
|
||||
PYLIB="$(python_get_LIBS)" \
|
||||
check
|
||||
if [[ ${EPYTHON} != pypy* ]]; then
|
||||
# prepare executable for embedded interpreter test
|
||||
# (skipped with pypy)
|
||||
rm -f tests/pyrun3 || die
|
||||
emake \
|
||||
CC="$(tc-getCC)" \
|
||||
PYINC="$(python_get_CFLAGS)" \
|
||||
PYLIB="$(python_get_LIBS)" \
|
||||
tests/pyrun3
|
||||
fi
|
||||
|
||||
"${EPYTHON}" tests/setproctitle_test.py -v || die "Tests failed with ${EPYTHON}"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user