summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLouis Sautier <sbraz@gentoo.org>2022-11-26 18:27:43 +0100
committerLouis Sautier <sbraz@gentoo.org>2022-11-26 18:32:49 +0100
commit4338694a9420cb9bd1d05a160127ab90b579f589 (patch)
tree3819b01b065da36ff2cfa839be7b7037ac92690a
parentx11-misc/grub2-theme-preview: 2.7.0 (diff)
downloadgentoo-4338694a9420cb9bd1d05a160127ab90b579f589.tar.gz
gentoo-4338694a9420cb9bd1d05a160127ab90b579f589.tar.bz2
gentoo-4338694a9420cb9bd1d05a160127ab90b579f589.zip
dev-python/python-ctags: support Py3.11, use PEP517
Signed-off-by: Louis Sautier <sbraz@gentoo.org>
-rw-r--r--dev-python/python-ctags/Manifest1
-rw-r--r--dev-python/python-ctags/python-ctags-1.5.0-r1.ebuild40
2 files changed, 41 insertions, 0 deletions
diff --git a/dev-python/python-ctags/Manifest b/dev-python/python-ctags/Manifest
index 3d50d1c72c4b..6b470afec3f7 100644
--- a/dev-python/python-ctags/Manifest
+++ b/dev-python/python-ctags/Manifest
@@ -1 +1,2 @@
+DIST python-ctags-1.5.0.gh.tar.gz 63921 BLAKE2B 1d25e7bafbdf157f1051321058b39fc9347bc479a61fae637bd11ef8540a3c67e2abd101493668977f05e464a8203b8c518fd1f4433defe5cec9939a200438b2 SHA512 414774c865af51e54c53f66dc7b3cfb5a03b64ea4eb94325658c158542615dfffdd1a5933d9ae03cedf1dbac30e1810d5914fbc3d6ab41e5f708c5d3000d161e
DIST python-ctags3-1.5.0.tar.gz 59091 BLAKE2B 303b061e7e660c1ed08c52fa76e4a96e288c6359167006a112de2262eff8c6bb564cb5c5ed310e091a3e88c5d5494e883020e7aa3ed900dc9a316cc8a9f597e8 SHA512 a5f1e2ff49abf9cf471a0139c1d2e1c4f836557386f394a96e67692d6153c60717df16fc7dbf832f69182270842fdc550f77194855111534c3b71b81ac94e483
diff --git a/dev-python/python-ctags/python-ctags-1.5.0-r1.ebuild b/dev-python/python-ctags/python-ctags-1.5.0-r1.ebuild
new file mode 100644
index 000000000000..12154624c3b7
--- /dev/null
+++ b/dev-python/python-ctags/python-ctags-1.5.0-r1.ebuild
@@ -0,0 +1,40 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DISTUTILS_USE_PEP517=setuptools
+PYTHON_COMPAT=( pypy3 python3_{9..11} )
+
+inherit distutils-r1
+
+MY_PN="${PN}3"
+DESCRIPTION="Exuberant Ctags indexing python bindings"
+HOMEPAGE="https://github.com/universal-ctags/python-ctags3"
+# PyPI tarballs don't contain pyx files
+SRC_URI="https://github.com/universal-ctags/python-ctags3/archive/${PV}.tar.gz -> ${P}.gh.tar.gz"
+S="${WORKDIR}/${MY_PN}-${PV}"
+
+LICENSE="LGPL-3"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+
+RDEPEND="dev-util/ctags:="
+BDEPEND="dev-python/cython[${PYTHON_USEDEP}]"
+
+distutils_enable_tests pytest
+
+python_prepare_all() {
+ # We currently need to let Cython regenerate this file to make Python 3.11
+ # support work
+ rm src/_readtags.c || die
+ cython -3 src/_readtags.pyx || die
+ distutils-r1_python_prepare_all
+}
+
+python_test() {
+ # To prevent pytest from importing it and failing with:
+ # ModuleNotFoundError: No module named 'ctags._readtags'
+ rm -rf src/ctags || die
+ epytest
+}