summaryrefslogtreecommitdiff
path: root/dev-python
diff options
context:
space:
mode:
authorMichał Górny <mgorny@gentoo.org>2025-07-29 04:05:50 +0200
committerMichał Górny <mgorny@gentoo.org>2025-07-29 04:13:52 +0200
commitd1512d55b4b0a454045c6af4bb5df6bb72e0fb1c (patch)
tree303c138a31c3ae34cc8c00c68a5229879ad8b231 /dev-python
parent5d0efa589a84cc792f28aa61fbdfeaa04d365c28 (diff)
downloadgentoo-d1512d55b4b0a454045c6af4bb5df6bb72e0fb1c.tar.gz
gentoo-d1512d55b4b0a454045c6af4bb5df6bb72e0fb1c.tar.bz2
gentoo-d1512d55b4b0a454045c6af4bb5df6bb72e0fb1c.zip
dev-python/cffi: Bump to 2.0.0_beta1
Signed-off-by: Michał Górny <mgorny@gentoo.org>
Diffstat (limited to 'dev-python')
-rw-r--r--dev-python/cffi/Manifest1
-rw-r--r--dev-python/cffi/cffi-2.0.0_beta1.ebuild70
2 files changed, 71 insertions, 0 deletions
diff --git a/dev-python/cffi/Manifest b/dev-python/cffi/Manifest
index 39184736f5e0..39fa548c09d0 100644
--- a/dev-python/cffi/Manifest
+++ b/dev-python/cffi/Manifest
@@ -1 +1,2 @@
DIST cffi-1.17.1.tar.gz 516621 BLAKE2B 902844a14c0765ada6adf5054a9462a195b49b2ea4d7441deeff97dd6d9209accd29257697002ee1bad7e143ebf983a2d98077b17e08b060dd1ee75dc682e3d8 SHA512 907129891d56351ca5cb885aae62334ad432321826d6eddfaa32195b4c7b7689a80333e6d14d0aab479a646aba148b9852c0815b80344dfffa4f183a5e74372c
+DIST cffi-2.0.0b1.tar.gz 521625 BLAKE2B a62b15652e02ed62ce33cc92f6bfd4454a81a6a7c3fb84cc048fbf8cc39325af09c19f5c2a2f1e6c80063e9fc8ae6537d1b917a01f15e8e56c2bb847bd79bfac SHA512 974f724a4c819f0a32da38a7209c6f54e63810817794bab286e8721bab6c59ce50c2c0992c828af54088ff8f1dec40480ffe37155d979cadc26c79cdc6b78f54
diff --git a/dev-python/cffi/cffi-2.0.0_beta1.ebuild b/dev-python/cffi/cffi-2.0.0_beta1.ebuild
new file mode 100644
index 000000000000..1f850d13ea69
--- /dev/null
+++ b/dev-python/cffi/cffi-2.0.0_beta1.ebuild
@@ -0,0 +1,70 @@
+# Copyright 1999-2025 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+# please keep this ebuild at EAPI 8 -- sys-apps/portage dep
+EAPI=8
+
+DISTUTILS_EXT=1
+DISTUTILS_USE_PEP517=setuptools
+# DO NOT ADD pypy to PYTHON_COMPAT
+# pypy bundles a modified version of cffi. Use python_gen_cond_dep instead.
+PYTHON_COMPAT=( python3_{11..14} python3_14t )
+
+inherit distutils-r1 toolchain-funcs pypi
+
+DESCRIPTION="Foreign Function Interface for Python calling C code"
+HOMEPAGE="
+ https://cffi.readthedocs.io/
+ https://pypi.org/project/cffi/
+"
+
+LICENSE="MIT"
+SLOT="0/${PV}"
+
+# Needs recent libffi for HPPA fixes
+DEPEND="
+ >=dev-libs/libffi-3.4.4-r1:=
+"
+# setuptools as a modern distutils provider
+RDEPEND="
+ ${DEPEND}
+ dev-python/pycparser[${PYTHON_USEDEP}]
+ dev-python/setuptools[${PYTHON_USEDEP}]
+"
+BDEPEND="
+ ${RDEPEND}
+ virtual/pkgconfig
+ test? (
+ dev-python/py[${PYTHON_USEDEP}]
+ )
+"
+
+distutils_enable_sphinx doc/source
+EPYTEST_PLUGINS=()
+distutils_enable_tests pytest
+
+PATCHES=(
+ "${FILESDIR}"/cffi-1.14.0-darwin-no-brew.patch
+)
+
+src_prepare() {
+ if [[ ${CHOST} == *darwin* ]] ; then
+ # Don't obsessively try to find libffi
+ sed -i -e "s/.*\-iwithsysroot\/usr\/include\/ffi.*/\tpass/" setup.py || die
+ fi
+ distutils-r1_src_prepare
+}
+
+src_configure() {
+ tc-export PKG_CONFIG
+}
+
+python_test() {
+ local EPYTEST_IGNORE=(
+ # these tests call pip
+ testing/cffi0/test_zintegration.py
+ )
+
+ "${EPYTHON}" -c "import _cffi_backend as backend" || die
+ epytest src/c testing
+}