From d0de811019ebd54526311a9910fbe042570aa224 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Micha=C5=82=20G=C3=B3rny?= Date: Mon, 1 Jul 2019 08:54:11 +0200 Subject: [PATCH] dev-python/cython: Bump to 0.29.11 MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Michał Górny --- dev-python/cython/Manifest | 1 + dev-python/cython/cython-0.29.11.ebuild | 86 +++++++++++++++++++++++++ 2 files changed, 87 insertions(+) create mode 100644 dev-python/cython/cython-0.29.11.ebuild diff --git a/dev-python/cython/Manifest b/dev-python/cython/Manifest index 1e8a78f603a8..8b5355265601 100644 --- a/dev-python/cython/Manifest +++ b/dev-python/cython/Manifest @@ -2,4 +2,5 @@ DIST Cython-0.25.2.tar.gz 1703315 BLAKE2B e458604d0843afa128c6019244220bd6b3dd66 DIST Cython-0.26.1.tar.gz 1725133 BLAKE2B b2c0433e8154ad76d921677608cae42a793326015ff320d8cd61818e5eb5fb4daf73ad4e72760d84f4cdaa2386b87d719cf9cd41584b781d4e2021e377a58422 SHA512 cdf31afaba78209c37a224345471c5c822b78c6d26c51583c46669b6b2b57b4952b33a839a51d06c3330fdff889345ac611fbaa2b2f17498cb02f3b5675f7948 DIST Cython-0.28.4.tar.gz 1880943 BLAKE2B a97314147294c95fa0bd6d3fa1a1315d81f8abb46a1f2196009c1ef6f0dd7f47f81a7b31ab81d1fd00e8de37878a18a22d225055181ee74ffe4cc8105d84cd75 SHA512 67d2da2d776fc02193cfe98c8942e93905ec5e30bf4e0f9d5c965d930a034936d4c29c8248fccefff5db6d4dee054ec854994bea63fa3f64ff65df7550997c29 DIST Cython-0.29.10.tar.gz 2049468 BLAKE2B 1cfae1c5e2d7277d3ac25ab0ff5a7b4346242e6c01d0b7945491f4fb64e0c9b98c593efa41b790aa0437ae72275a0ba3b6fe8614c7efaadc6139823f0e453d71 SHA512 df8430bb89816df84abfc6d59bee8e50f4117e8e82b9c82a889afca390a42a1569a9b5dcde76f40e7c29d728489af34c6fe0cf359912f7b74ac0d014af2171c3 +DIST Cython-0.29.11.tar.gz 2050170 BLAKE2B 47ce8b73371b8f4537e4ad7645dfaccdca207573eba68fa7e5da079db5b739b8cede57a55a19b2bfb28aaf30f8d5b5c9eb8492fdfcc07f533f4e9af036a315ad SHA512 d683cd006afb9778c9c2d755646623977d29d05675be8bc85f711d4a0cadcd5bd7ed623a2a2bc2067898b0d5b99819f2047b91345ecd5e4f0828eea6f62ec83c DIST Cython-0.29.4.tar.gz 2044382 BLAKE2B b36d27706a3270805f66190a4cf2735eaf20b1b932365b324a433c0e58e63e860ce1500333233c3539ae697886ac0adc361a2c158d5d064a3ea05843debc3f26 SHA512 8f115e36975aaf64eda4df8b0a85378d0c80b3292dbd162be826b939def03bdc9f3eb937676e2367003c2944b570d97f50d7880becfdb2fdc5144077b4a722dc diff --git a/dev-python/cython/cython-0.29.11.ebuild b/dev-python/cython/cython-0.29.11.ebuild new file mode 100644 index 000000000000..3bd1896df64d --- /dev/null +++ b/dev-python/cython/cython-0.29.11.ebuild @@ -0,0 +1,86 @@ +# Copyright 1999-2019 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +PYTHON_COMPAT=( python2_7 python3_{5,6,7} ) +PYTHON_REQ_USE="threads(+)" + +inherit distutils-r1 toolchain-funcs elisp-common + +MY_PN="Cython" +MY_P="${MY_PN}-${PV/_/}" + +DESCRIPTION="A Python to C compiler" +HOMEPAGE="https://cython.org https://pypi.org/project/Cython/" +SRC_URI="mirror://pypi/${MY_PN:0:1}/${MY_PN}/${MY_P}.tar.gz" + +LICENSE="Apache-2.0" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~riscv ~s390 ~sh ~sparc ~x86 ~x64-cygwin ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~x64-solaris ~x86-solaris" +IUSE="doc emacs test" +RESTRICT="!test? ( test )" + +RDEPEND=" + emacs? ( virtual/emacs ) +" +DEPEND="${RDEPEND} + dev-python/setuptools[${PYTHON_USEDEP}] + doc? ( dev-python/sphinx[${PYTHON_USEDEP}] ) + test? ( dev-python/numpy[${PYTHON_USEDEP}] )" + +SITEFILE=50cython-gentoo.el +S="${WORKDIR}/${MY_PN}-${PV%_*}" + +python_prepare_all() { + # tests behavior that is illegal in Python 3.7+ + # https://github.com/cython/cython/issues/2454 + sed -i -e '/with_outer_raising/,/return/d' tests/run/generators_py.py || die + + distutils-r1_python_prepare_all +} + +python_compile() { + if ! python_is_python3; then + local CFLAGS="${CFLAGS} -fno-strict-aliasing" + local CXXFLAGS="${CXXFLAGS} -fno-strict-aliasing" + fi + + # Python gets confused when it is in sys.path before build. + local -x PYTHONPATH= + + distutils-r1_python_compile +} + +python_compile_all() { + use emacs && elisp-compile Tools/cython-mode.el + + use doc && emake -C docs html +} + +python_test() { + tc-export CC + # https://github.com/cython/cython/issues/1911 + local -x CFLAGS="${CFLAGS} -fno-strict-overflow" + "${PYTHON}" runtests.py -vv --work-dir "${BUILD_DIR}"/tests \ + || die "Tests fail with ${EPYTHON}" +} + +python_install_all() { + local DOCS=( CHANGES.rst README.rst ToDo.txt USAGE.txt ) + use doc && local HTML_DOCS=( docs/build/html/. ) + distutils-r1_python_install_all + + if use emacs; then + elisp-install ${PN} Tools/cython-mode.* + elisp-site-file-install "${FILESDIR}/${SITEFILE}" + fi +} + +pkg_postinst() { + use emacs && elisp-site-regen +} + +pkg_postrm() { + use emacs && elisp-site-regen +} -- 2.26.2