From: Michał Górny Date: Wed, 18 Mar 2020 06:46:28 +0000 (+0100) Subject: dev-python/pyhamcrest: Switch to distutils_enable_sphinx X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=5ba0e02a8a31b72ac50beab70650d540a99e328a;p=gentoo.git dev-python/pyhamcrest: Switch to distutils_enable_sphinx Signed-off-by: Michał Górny --- diff --git a/dev-python/pyhamcrest/pyhamcrest-1.9.0-r1.ebuild b/dev-python/pyhamcrest/pyhamcrest-1.9.0-r1.ebuild index 9030f0d5741b..3d3ac12ea0fa 100644 --- a/dev-python/pyhamcrest/pyhamcrest-1.9.0-r1.ebuild +++ b/dev-python/pyhamcrest/pyhamcrest-1.9.0-r1.ebuild @@ -12,31 +12,24 @@ MY_PN="PyHamcrest" DESCRIPTION="Hamcrest framework for matcher objects" HOMEPAGE="https://github.com/hamcrest/PyHamcrest" SRC_URI="https://github.com/hamcrest/PyHamcrest/archive/V${PV}.tar.gz -> ${MY_PN}-${PV}.gh.tar.gz" +S="${WORKDIR}/${MY_PN}-${PV}" LICENSE="BSD" SLOT="0" KEYWORDS="~alpha amd64 arm arm64 ~mips ~sh sparc ~amd64-linux ~x86-linux" -IUSE="doc examples test" -REQUIRED_USE="doc? ( || ( $(python_gen_useflags -3) ) )" +IUSE="examples test" RESTRICT="!test? ( test )" RDEPEND=">=dev-python/six-1.4[${PYTHON_USEDEP}]" DEPEND="${RDEPEND} dev-python/setuptools[${PYTHON_USEDEP}] - doc? ( - $(python_gen_cond_dep '>=dev-python/sphinx-2[${PYTHON_USEDEP}]' -3) - $(python_gen_cond_dep 'dev-python/sphinx_rtd_theme[${PYTHON_USEDEP}]' -3) - ) test? ( >=dev-python/pytest-2.6[${PYTHON_USEDEP}] dev-python/mock[${PYTHON_USEDEP}] )" -S="${WORKDIR}/${MY_PN}-${PV}" - -pkg_setup() { - use doc && DISTUTILS_ALL_SUBPHASE_IMPLS=( -3 ) -} +distutils_enable_sphinx doc \ + dev-python/sphinx_rtd_theme python_prepare_all() { # enables coverage testing which we don't want @@ -56,13 +49,6 @@ python_prepare_all() { distutils-r1_python_prepare_all } -python_compile_all() { - if use doc; then - esetup.py build_sphinx - HTML_DOCS=( "${BUILD_DIR}"/sphinx/html/. ) - fi -} - python_test() { py.test -vv || die "Tests failed under ${EPYTHON}" "${EPYTHON}" tests/object_import.py || die "Tests failed under ${EPYTHON}"