diff options
Diffstat (limited to 'dev-python/cffi')
-rw-r--r-- | dev-python/cffi/Manifest | 2 | ||||
-rw-r--r-- | dev-python/cffi/cffi-1.15.0.ebuild | 54 |
2 files changed, 56 insertions, 0 deletions
diff --git a/dev-python/cffi/Manifest b/dev-python/cffi/Manifest index 5a198f6b89ee..286ac12f5e51 100644 --- a/dev-python/cffi/Manifest +++ b/dev-python/cffi/Manifest @@ -1,4 +1,6 @@ AUX cffi-1.14.0-darwin-no-brew.patch 568 BLAKE2B 43afdb086a0385e913f287bc5c1534df1b881058cf7efdfdecd9df063c27ebd26683edad43e3010e1c01d9d93c5d98785ffbe65a5e3317d96ebb6a3132aecdab SHA512 75335871b8f98223e0247defc3d08f1c10ebed58c79790826c4e39057e6757b8bdc07e2773ad25482ed17c13480b3e72b3667e48697a456ed0cc4a39e7d91b79 DIST cffi-1.14.6.tar.gz 475744 BLAKE2B 46e3f1f61746f659c066d83fdb07b83c289eda68056c6f9e364ea6f30cd56c190e4fdb35586c064b2402483704a7c1e9399d7f30cb49a78eec21797146da36f2 SHA512 30a8b25b74921a90a1fa96d05de1f25437d0fbbf73b7de0bb9ce22dfcaccbd78376b605525fe970212221d3e598357a9b1da420bfbd1a3e513263ed2b789e813 +DIST cffi-1.15.0.tar.gz 484058 BLAKE2B 0d2d470c7eb11b8a9526be816b153c4483a5cfb529d3d220a804842facae1f06e2a822aa2be9abb1b5648cb36a97033bffc1dd235d83bdf8c075d67a907aa7d9 SHA512 ee83efde6f77f4a0c5889088c4c208ed7b9071fe06dfc16a8d2396de07f78fe859e1e39866760198a9d700f3b7359e8715e8a3e4907feb81d3fc4b8dd0dbaca1 EBUILD cffi-1.14.6.ebuild 1461 BLAKE2B a6e6a2e745fd9ac2aa2dcfa2de7566981f972746ea00375c3320f90d9f1d9f9b54319e0144bdc1be2477dde83b985ea410838a64ac3431442d56576504669e4a SHA512 c12149dcbc691a4d9856d2d912689ee4e2524cf67eb6cf271c09c75032c500b3c08f4679986594ef42f5934751ab32f7c584b870f54b28efeddc80740baed5d3 +EBUILD cffi-1.15.0.ebuild 1486 BLAKE2B fb22e897a2e3275e7aa13bedc1eb6a699625719a660530062432ef9d5d6f206423c58cd7ce307bcc1a68dc0d37a3afe2a82565c85e67c075c95672bfe5780c51 SHA512 f2f2e3bef5ac37a416cfdf715153b413422e6466cb322eed91f0842d2844b46af7c995db45175cfdbde37bf0958a6f2a2f8805280eac2e5547a5c9eae9aba298 MISC metadata.xml 318 BLAKE2B f914459fac4ae3d8ac9273fb721c52494513b932676f570f02cc4cfb2283705d8cfc761806ffed23c6f31c95a967398edee01c1536547c1830def5ca4144c003 SHA512 ec451f8c535f0d01dc7bcd248c002745947982cd469a02ac247d0d34f4d7a33374fa10c28d8f074932f0548dc500c3270b499dd08b18acbb9d308777bcc7e4f0 diff --git a/dev-python/cffi/cffi-1.15.0.ebuild b/dev-python/cffi/cffi-1.15.0.ebuild new file mode 100644 index 000000000000..8bf3a0a6b6ee --- /dev/null +++ b/dev-python/cffi/cffi-1.15.0.ebuild @@ -0,0 +1,54 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +# please keep this ebuild at EAPI 7 -- sys-apps/portage dep +EAPI=7 + +# DO NOT ADD pypy to PYTHON_COMPAT +# pypy bundles a modified version of cffi. Use python_gen_cond_dep instead. +PYTHON_COMPAT=( python3_{8..10} ) +inherit distutils-r1 toolchain-funcs + +DESCRIPTION="Foreign Function Interface for Python calling C code" +HOMEPAGE="https://cffi.readthedocs.io/ https://pypi.org/project/cffi/" +SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz" + +LICENSE="MIT" +SLOT="0/${PV}" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" + +DEPEND="dev-libs/libffi:=" +RDEPEND="${DEPEND} + dev-python/pycparser[${PYTHON_USEDEP}]" +BDEPEND="${RDEPEND} + virtual/pkgconfig" + +distutils_enable_sphinx doc/source +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 \ + c/ testing/ +} |