mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-02-25 18:57:28 -08:00
The result was achieved via the following pipeline:
pkgcheck scan -c RestrictTestCheck -R FormatReporter \
--format '{category}/{package}/{package}-{version}.ebuild' |
xargs -n32 grep -L RESTRICT |
xargs -n32 sed -i -e '/^IUSE=.*test/aRESTRICT="!test? ( test )"'
The resulting metadata was compared before and after the change.
Few Go ebuilds had to be fixed manually due to implicit RESTRICT=strip
added by the eclass. Two ebuilds have to be fixed because of multiline
IUSE.
Suggested-by: Robin H. Johnson <robbat2@gentoo.org>
Closes: https://github.com/gentoo/gentoo/pull/13942
Signed-off-by: Michał Górny <mgorny@gentoo.org>
44 lines
973 B
Bash
44 lines
973 B
Bash
# Copyright 1999-2019 Gentoo Authors
|
|
# Distributed under the terms of the GNU General Public License v2
|
|
|
|
EAPI=5
|
|
|
|
PYTHON_COMPAT=( python{2_7,3_5,3_6,3_7} )
|
|
|
|
inherit distutils-r1 eutils
|
|
|
|
DESCRIPTION="Python library for arbitrary-precision floating-point arithmetic"
|
|
HOMEPAGE="http://mpmath.org/"
|
|
SRC_URI="http://mpmath.org/files/${P}.tar.gz"
|
|
|
|
LICENSE="BSD"
|
|
SLOT="0"
|
|
KEYWORDS="amd64 ~arm ~ppc64 x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos"
|
|
|
|
IUSE="gmp matplotlib test"
|
|
RESTRICT="!test? ( test )"
|
|
|
|
RDEPEND="
|
|
gmp? ( dev-python/gmpy )
|
|
matplotlib? ( dev-python/matplotlib[${PYTHON_USEDEP}] )"
|
|
DEPEND="${RDEPEND}
|
|
test? ( dev-python/pytest[${PYTHON_USEDEP}] )"
|
|
|
|
python_prepare_all() {
|
|
local PATCHES=(
|
|
"${FILESDIR}/${P}.patch"
|
|
)
|
|
|
|
# this fails with the current version of dev-python/py
|
|
rm ${PN}/conftest.py || die
|
|
|
|
# this test requires X
|
|
rm ${PN}/tests/test_visualization.py || die
|
|
|
|
distutils-r1_python_prepare_all
|
|
}
|
|
|
|
python_test() {
|
|
py.test -v || die
|
|
}
|