From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 59A7A1382C5 for ; Sat, 6 Jun 2020 17:40:36 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id A7B49E0AAD; Sat, 6 Jun 2020 17:40:35 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 918A1E0AAD for ; Sat, 6 Jun 2020 17:40:35 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 94A7234F14B for ; Sat, 6 Jun 2020 17:40:34 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 165B931 for ; Sat, 6 Jun 2020 17:40:33 +0000 (UTC) From: "Pacho Ramos" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Pacho Ramos" Message-ID: <1591465228.c9ef6b5d055e9451dc20ea4094d7ba9dc6551b4f.pacho@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/cairocffi/ X-VCS-Repository: repo/gentoo X-VCS-Files: dev-python/cairocffi/cairocffi-0.9.0-r1.ebuild X-VCS-Directories: dev-python/cairocffi/ X-VCS-Committer: pacho X-VCS-Committer-Name: Pacho Ramos X-VCS-Revision: c9ef6b5d055e9451dc20ea4094d7ba9dc6551b4f X-VCS-Branch: master Date: Sat, 6 Jun 2020 17:40:33 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 7d3e6a8e-c4a0-408a-a7d1-92e73c827f09 X-Archives-Hash: 993f4f8ee56d3df9c46344c0ad888765 commit: c9ef6b5d055e9451dc20ea4094d7ba9dc6551b4f Author: Pacho Ramos gentoo org> AuthorDate: Sat Jun 6 17:40:03 2020 +0000 Commit: Pacho Ramos gentoo org> CommitDate: Sat Jun 6 17:40:28 2020 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c9ef6b5d dev-python/cairocffi: Support newer python This allows consumers needing python2 support to coexist with packages needed newer python. By the way, also apply the patch that is used in 0.8 and 1.1 versions to workaround broken tests. Package-Manager: Portage-2.3.100, Repoman-2.3.22 Signed-off-by: Pacho Ramos gentoo.org> dev-python/cairocffi/cairocffi-0.9.0-r1.ebuild | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/dev-python/cairocffi/cairocffi-0.9.0-r1.ebuild b/dev-python/cairocffi/cairocffi-0.9.0-r1.ebuild index 45e349b5808..6793e7f9b0e 100644 --- a/dev-python/cairocffi/cairocffi-0.9.0-r1.ebuild +++ b/dev-python/cairocffi/cairocffi-0.9.0-r1.ebuild @@ -3,7 +3,7 @@ EAPI="7" -PYTHON_COMPAT=( python2_7 python3_{6,7} ) +PYTHON_COMPAT=( python2_7 python3_{6..9} ) inherit distutils-r1 virtualx @@ -17,9 +17,11 @@ SRC_URI="mirror://pypi/${MY_P:0:1}/${MY_PN}/${MY_P}.tar.gz" LICENSE="BSD" SLOT="0" KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86" -IUSE="doc test" +IUSE="test" RESTRICT="!test? ( test )" +distutils_enable_sphinx docs + RDEPEND=" $(python_gen_cond_dep '>=dev-python/cffi-1.1.0:=[${PYTHON_USEDEP}]' 'python*') >=dev-python/xcffib-0.3.2[${PYTHON_USEDEP}] @@ -28,7 +30,6 @@ RDEPEND=" DEPEND=" dev-python/setuptools[${PYTHON_USEDEP}] - doc? ( dev-python/sphinx[${PYTHON_USEDEP}] ) test? ( ${RDEPEND} dev-python/pytest[${PYTHON_USEDEP}] @@ -36,15 +37,15 @@ DEPEND=" S="${WORKDIR}/${MY_P}" -python_compile_all() { - use doc && esetup.py build_sphinx +PATCHES=( "${FILESDIR}"/${PN}-0.8.0-tests.patch ) + +python_prepare() { + if python_is_python3; then + # Remove deprecated statements for python3 + sed -i -e 's/tostring/tobytes/g' cairocffi/test_cairo.py || die + fi } python_test() { virtx py.test -v --pyargs cairocffi -o addopts= } - -python_install_all() { - use doc && HTML_DOCS=( docs/_build/html/. ) - distutils-r1_python_install_all -}