diff options
| author | Liguros - Gitlab CI/CD [develop] <gitlab@liguros.net> | 2022-12-29 00:54:43 +0000 |
|---|---|---|
| committer | Liguros - Gitlab CI/CD [develop] <gitlab@liguros.net> | 2022-12-29 00:54:43 +0000 |
| commit | 849b2a23e34c3bcce31eed8b4aaedeb63f6c4cd6 (patch) | |
| tree | 24140ea7f18d61c1ef5b548410f683996ea1f237 /dev-python | |
| parent | 89bdf0bea50f19711633d2a295a6f30029102e63 (diff) | |
| download | baldeagleos-repo-849b2a23e34c3bcce31eed8b4aaedeb63f6c4cd6.tar.gz baldeagleos-repo-849b2a23e34c3bcce31eed8b4aaedeb63f6c4cd6.tar.xz baldeagleos-repo-849b2a23e34c3bcce31eed8b4aaedeb63f6c4cd6.zip | |
Adding metadata
Diffstat (limited to 'dev-python')
25 files changed, 810 insertions, 5 deletions
diff --git a/dev-python/blosc/blosc-1.10.6.ebuild b/dev-python/blosc/blosc-1.10.6.ebuild index a9fe7da0b551..3b7d731deedd 100644 --- a/dev-python/blosc/blosc-1.10.6.ebuild +++ b/dev-python/blosc/blosc-1.10.6.ebuild @@ -22,7 +22,7 @@ SRC_URI=" S=${WORKDIR}/${MY_P} SLOT="0" -LICENSE="MIT" +LICENSE="BSD" KEYWORDS="amd64 arm arm64 ~hppa ~ia64 ppc ppc64 ~riscv ~s390 ~sparc x86 ~amd64-linux ~x86-linux" IUSE="test" RESTRICT="!test? ( test )" diff --git a/dev-python/blosc/blosc-1.11.0.ebuild b/dev-python/blosc/blosc-1.11.0.ebuild index 6cb23d1ec422..910a0cceb3e0 100644 --- a/dev-python/blosc/blosc-1.11.0.ebuild +++ b/dev-python/blosc/blosc-1.11.0.ebuild @@ -22,7 +22,7 @@ SRC_URI=" S=${WORKDIR}/${MY_P} SLOT="0" -LICENSE="MIT" +LICENSE="BSD" KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux" IUSE="test" RESTRICT="!test? ( test )" diff --git a/dev-python/blosc/blosc-1.11.1.ebuild b/dev-python/blosc/blosc-1.11.1.ebuild index 6cb23d1ec422..910a0cceb3e0 100644 --- a/dev-python/blosc/blosc-1.11.1.ebuild +++ b/dev-python/blosc/blosc-1.11.1.ebuild @@ -22,7 +22,7 @@ SRC_URI=" S=${WORKDIR}/${MY_P} SLOT="0" -LICENSE="MIT" +LICENSE="BSD" KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux" IUSE="test" RESTRICT="!test? ( test )" diff --git a/dev-python/filelock/Manifest b/dev-python/filelock/Manifest index ef74829c91af..89f6d317c77d 100644 --- a/dev-python/filelock/Manifest +++ b/dev-python/filelock/Manifest @@ -1,2 +1,3 @@ DIST py-filelock-3.8.0.gh.tar.gz 204748 BLAKE2B 719f965eddf9a76aaa7d3700ffbd29df3856fdcd76aa184b12a1e3b3341a5d8681f05ebd7239b48a0ffbc942aebc8574ff3878177100ba659347a904945b2234 SHA512 a9b63ab9a6697334eb8c561c422e8ec6febd0b7b203c0ebb4cfd1e4281f16cc0ef5145121c90f3c08bec88f13e219c0655142e3d3f856163702a0d32e14cd5ce DIST py-filelock-3.8.2.gh.tar.gz 204940 BLAKE2B a83fbea21690f82680ab5d024cbca6e52b5f6490854fa1d14a98191a4e56edea41c0a8bda9dd396f8b9c5b83187d9f976011440ca00987fbe4e96cd1e311a244 SHA512 2d5f7f49cf2d112a060156391eeb600040b9ae8619a9795173b9888ee977ec718432beff68bfefca290791b14f8cefca6d2a92defd78132822dc3596493aaa23 +DIST py-filelock-3.9.0.gh.tar.gz 205047 BLAKE2B 3995f7ad27bb09ca75310c4ada7645f2dd16c09ddb39663394f315443851037f2f9cf08eecb507eba521479696ad1004978d3fdd300a7128ac3354fce2e57d5f SHA512 1235ae9ebdb4c84b0c30e68be91e01eb1acbfcd15c85202fa54a3b91e4e507f221926f8886e1ec91acd4f71d2d88c08f536529b4cebfd2de4fb90118f5dc242e diff --git a/dev-python/filelock/filelock-3.9.0.ebuild b/dev-python/filelock/filelock-3.9.0.ebuild new file mode 100644 index 000000000000..df3b1fb81e6d --- /dev/null +++ b/dev-python/filelock/filelock-3.9.0.ebuild @@ -0,0 +1,36 @@ +# Copyright 2018-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=hatchling +PYTHON_COMPAT=( python3_{7,8,9,10,11} pypy3 ) + +inherit distutils-r1 + +MY_P=py-filelock-${PV} +DESCRIPTION="A platform independent file lock for Python" +HOMEPAGE=" + https://github.com/tox-dev/py-filelock/ + https://pypi.org/project/filelock/ +" +SRC_URI=" + https://github.com/tox-dev/py-filelock/archive/${PV}.tar.gz + -> ${MY_P}.gh.tar.gz +" +S="${WORKDIR}/${MY_P}" + +LICENSE="Unlicense" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-macos" + +BDEPEND=" + dev-python/hatch-vcs[${PYTHON_USEDEP}] + test? ( + dev-python/pytest-timeout[${PYTHON_USEDEP}] + ) +" + +distutils_enable_tests pytest + +export SETUPTOOLS_SCM_PRETEND_VERSION=${PV} diff --git a/dev-python/mock/Manifest b/dev-python/mock/Manifest index 6e034d8a6680..ef079b4586e6 100644 --- a/dev-python/mock/Manifest +++ b/dev-python/mock/Manifest @@ -1 +1,2 @@ DIST mock-4.0.3.gh.tar.gz 80318 BLAKE2B bc0dc8b97129eaa2f0f9c89898157ea5de398f59f4e2ebc07318cf745b74d1f1bcc989774600ec88ce1956f9fe16f9464f101ea5df5cd23b3a58b432d19feb8a SHA512 adfdab253eb3bc1b6cb767c58ffa3a8a5c5f88da0f04ea6680e0d87da59177972d2d99bfe0a770ac2ed4f809ca6a090a9d0f789eea8f4365ef2c54f8e8792e89 +DIST mock-5.0.0.gh.tar.gz 83866 BLAKE2B 7c0718f8d43325b293b070f37c39ccf539a80460ac7e7b724674deb02154157a7dd62a81cd439e19589cee66f256f111f0feec9f8790f16c70948fac3745b43b SHA512 acde3099cb8daf49dffc390faffc45f94c9f1dd24f196ef613b0677cd88d1b55b5cbd04604ff540731e919784242c1cc341065fae99c347c6dfbb3d8115fc2fe diff --git a/dev-python/mock/mock-5.0.0.ebuild b/dev-python/mock/mock-5.0.0.ebuild new file mode 100644 index 000000000000..cda37f90a7ef --- /dev/null +++ b/dev-python/mock/mock-5.0.0.ebuild @@ -0,0 +1,35 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=setuptools +PYTHON_COMPAT=( python3_{7,8,9,10,11} pypy3 ) + +inherit distutils-r1 + +DESCRIPTION="Rolling backport of unittest.mock for all Pythons" +HOMEPAGE=" + https://github.com/testing-cabal/mock/ + https://pypi.org/project/mock/ +" +SRC_URI=" + https://github.com/testing-cabal/mock/archive/${PV}.tar.gz + -> ${P}.gh.tar.gz +" + +LICENSE="BSD" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~x64-macos ~x64-solaris" + +RDEPEND=" + >=dev-python/six-1.9[${PYTHON_USEDEP}] +" + +distutils_enable_tests pytest + +python_install_all() { + local DOCS=( CHANGELOG.rst README.rst ) + + distutils-r1_python_install_all +} diff --git a/dev-python/platformdirs/Manifest b/dev-python/platformdirs/Manifest index c4d630365fe9..b2f1ece8b0a8 100644 --- a/dev-python/platformdirs/Manifest +++ b/dev-python/platformdirs/Manifest @@ -1,2 +1,3 @@ DIST platformdirs-2.5.4.gh.tar.gz 20645 BLAKE2B c995b881bf25d215ffbcfa4d9fd6721d763d2c27e306961965cd16da00bffce5a1e8dc3ebb48f0f499dbc0f5a079fcffbe0755913f61bc3e8a7192e951e8f18b SHA512 35e2f4ff4d289d6d83172105c716b3a337dc55b52be6d4ac653460e6e5696cce2256a645b2e91a8bab4a17f8a6c6e49b4a005924ede8da7ef2d03ede35061703 DIST platformdirs-2.6.0.gh.tar.gz 20779 BLAKE2B 5958cff9e3583091c365aea0b3380fc02b273d529868587cda80713db43794c5b69df729390152611d1611aa8a29a5aff84d26a4ccd8777bbd800b3c982bb0fe SHA512 727e057197b1f50cd6e9c0afcba042c9c0f85e061a8667f04548966e6d3d8eb80ce35d07d6578f98fc66273f31caf2a0dc7db9599f2f55fe2e89493803c4db57 +DIST platformdirs-2.6.1.gh.tar.gz 21135 BLAKE2B 65cd34d5fcc3aea46f216780d3a069d39395e0e9af1cff7a7af8511318c165233fff50ad6610ccd48a1e98e1dc4ca68f1cb2d6156a2c4e2a4523f04c09abdd0e SHA512 aff9d091ffad8e110aa2b3d615da65e3618b20f26f007210a9cb75d5e7d72d9ab8309e7e5a139f344f9f6dbedb419ab97848f8301e5104a667a6def58f947a6e diff --git a/dev-python/platformdirs/platformdirs-2.6.1.ebuild b/dev-python/platformdirs/platformdirs-2.6.1.ebuild new file mode 100644 index 000000000000..ec990df90bae --- /dev/null +++ b/dev-python/platformdirs/platformdirs-2.6.1.ebuild @@ -0,0 +1,35 @@ +# Copyright 2021-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=hatchling +PYTHON_COMPAT=( python3_{7,8,9,10,11} pypy3 ) + +inherit distutils-r1 + +DESCRIPTION="A small Python module for determining appropriate platform-specific dirs" +HOMEPAGE=" + https://pypi.org/project/platformdirs/ + https://github.com/platformdirs/platformdirs/ +" +SRC_URI=" + https://github.com/platformdirs/platformdirs/archive/${PV}.tar.gz + -> ${P}.gh.tar.gz +" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86" + +BDEPEND=" + >=dev-python/hatch-vcs-0.3[${PYTHON_USEDEP}] + test? ( + dev-python/appdirs[${PYTHON_USEDEP}] + dev-python/pytest-mock[${PYTHON_USEDEP}] + ) +" + +distutils_enable_tests pytest + +export SETUPTOOLS_SCM_PRETEND_VERSION=${PV} diff --git a/dev-python/pyquery/Manifest b/dev-python/pyquery/Manifest index 0eef5930be6d..2c9de0a63bb8 100644 --- a/dev-python/pyquery/Manifest +++ b/dev-python/pyquery/Manifest @@ -1 +1,2 @@ DIST pyquery-1.4.3.tar.gz 47448 BLAKE2B 32451dfc8f8160207b4be12006ceba3098b8cb344bfa3e80ccf75f8cfca9542614ae78b9bfec773139cbbf12434201f92f8b4738e7d9e6241b3addfeb1bc8dda SHA512 cb61326e38f78763ca15de09e3a56dad776b3d4831b54eabf295db0f9af8bf04599642c73f5db3e3172b86d7b66ba2ef626c8cba2dfb458af6ac432d15ea7cba +DIST pyquery-2.0.0.tar.gz 45210 BLAKE2B 2c1d052d310541b36f526e72906681ea03e0d55be16202c98ab5d5b9f5fc408b7612a353100937381639a03f8871b8bf691c6b0d5ad09dec8cc6f2e2ced7944d SHA512 316a479acd23e371b6e70550681527b15203e7ab62f4722375335180f13d9b48d9170abf308bb26b6180d954de4f8dfea5f90426cb820c5e888cc56f8a99ba33 diff --git a/dev-python/pyquery/pyquery-2.0.0.ebuild b/dev-python/pyquery/pyquery-2.0.0.ebuild new file mode 100644 index 000000000000..204d5a375b5e --- /dev/null +++ b/dev-python/pyquery/pyquery-2.0.0.ebuild @@ -0,0 +1,45 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=setuptools +PYTHON_COMPAT=( python3_{7,8,9,10,11} pypy3 ) + +inherit distutils-r1 optfeature + +DESCRIPTION="A jQuery-like library for python" +HOMEPAGE=" + https://github.com/gawel/pyquery/ + https://pypi.org/project/pyquery/ +" +SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz" + +LICENSE="BSD" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-macos" + +RDEPEND=" + >=dev-python/lxml-2.1[${PYTHON_USEDEP}] + >=dev-python/cssselect-1.2.0[${PYTHON_USEDEP}] + >=dev-python/webob-1.1.9[${PYTHON_USEDEP}] +" +DEPEND=" + test? ( + dev-python/beautifulsoup4[${PYTHON_USEDEP}] + dev-python/requests[${PYTHON_USEDEP}] + dev-python/webtest[${PYTHON_USEDEP}] + dev-python/webob[${PYTHON_USEDEP}] + ) +" + +distutils_enable_tests pytest + +EPYTEST_DESELECT=( + # needs network + tests/test_pyquery.py::TestWebScrappingEncoding::test_get +) + +pkg_postinst() { + optfeature "Support for BeautifulSoup3 as a parser backend" dev-python/beautifulsoup4 +} diff --git a/dev-python/pytables/Manifest b/dev-python/pytables/Manifest index c456f554b2d0..ea9d491502ea 100644 --- a/dev-python/pytables/Manifest +++ b/dev-python/pytables/Manifest @@ -1 +1,2 @@ DIST tables-3.7.0.tar.gz 8227955 BLAKE2B 0d5b7b765375c4787f1210138e5fd02e3c0ce429ef209a3a8d4fd3bc094f68486ab6f4d0a960ce86efea6991ed691ef2a3e9e8f37a49fe91cb8d6372cadea80e SHA512 eaa368d063b5fad87e6d0f9ab6f02da0b2a3542740a52fe8c2bb58e41121495d07b6d2710ad402a28891294aa61a11238c6a7e2cf2933a1bb11391b79cf4fd13 +DIST tables-3.8.0.tar.gz 8014052 BLAKE2B 28d120ad609ebc9ae8cd97286bb3fb9c484bd8a179edcf0de1b96e4400b7a21b4db835d94fae3aaee84924bd46b84b84da12c538b39517362d805651e7aa3aef SHA512 1616c00787a2e88ff3dc2aebe3a1b2ad428b5a8ea48fc94058b49c509f1c040b540b3f62551b16b3246d2fed58e0b33443cbdaaf1dfcba5a6eead5f3e8028029 diff --git a/dev-python/pytables/files/pytables-3.8.0-blosc2.patch b/dev-python/pytables/files/pytables-3.8.0-blosc2.patch new file mode 100644 index 000000000000..59403cdec12d --- /dev/null +++ b/dev-python/pytables/files/pytables-3.8.0-blosc2.patch @@ -0,0 +1,30 @@ +From 99a7f336635aaeb666ea8dc791743177a030dc18 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= <mgorny@gentoo.org> +Date: Wed, 28 Dec 2022 15:53:08 +0100 +Subject: [PATCH] Workaround blosc2 detection via blosc2 package + +--- + setup.py | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/setup.py b/setup.py +index 966be028..2708deb9 100755 +--- a/setup.py ++++ b/setup.py +@@ -262,11 +262,11 @@ if __name__ == "__main__": + + debug = "--debug" in sys.argv + +- blosc2_inc, blosc2_lib = get_blosc2_directories() ++ blosc2_inc, blosc2_lib = "", "" + + # Global variables + lib_dirs = [blosc2_lib] +- inc_dirs = [Path("hdf5-blosc/src"), Path("hdf5-blosc2/src"), blosc2_inc] ++ inc_dirs = [Path("hdf5-blosc/src"), Path("hdf5-blosc2/src")] + optional_libs = [] + copy_libs = [] + +-- +2.39.0 + diff --git a/dev-python/pytables/pytables-3.8.0.ebuild b/dev-python/pytables/pytables-3.8.0.ebuild new file mode 100644 index 000000000000..74ebdc456571 --- /dev/null +++ b/dev-python/pytables/pytables-3.8.0.ebuild @@ -0,0 +1,83 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{7,8,9,10,11} ) +PYTHON_REQ_USE="threads(+)" + +inherit distutils-r1 + +MY_PN=tables +MY_P=${MY_PN}-${PV} + +DESCRIPTION="Hierarchical datasets for Python" +HOMEPAGE=" + https://www.pytables.org/ + https://github.com/PyTables/PyTables/ + https://pypi.org/project/tables/ +" +SRC_URI="mirror://pypi/${MY_PN:0:1}/${MY_PN}/${MY_P}.tar.gz" +S=${WORKDIR}/${MY_P} + +LICENSE="BSD" +SLOT="0" +KEYWORDS="~amd64" +IUSE="examples test" +RESTRICT="!test? ( test )" + +DEPEND=" + app-arch/bzip2:0= + app-arch/lz4:0= + >=app-arch/zstd-1.0.0:= + >=dev-libs/c-blosc-1.11.1:0= + dev-libs/c-blosc2:= + dev-libs/lzo:2= + >=dev-python/numpy-1.19[${PYTHON_USEDEP}] + >=sci-libs/hdf5-1.8.4:= +" +RDEPEND=" + ${DEPEND} + >=dev-python/numexpr-2.6.2[${PYTHON_USEDEP}] + dev-python/packaging[${PYTHON_USEDEP}] + dev-python/py-cpuinfo[${PYTHON_USEDEP}] +" +BDEPEND=" + >=dev-python/cython-0.21[${PYTHON_USEDEP}] + dev-python/py-cpuinfo[${PYTHON_USEDEP}] + virtual/pkgconfig + test? ( + ${RDEPEND} + ) +" + +python_prepare_all() { + local PATCHES=( + "${FILESDIR}"/${P}-blosc2.patch + ) + + export PYTABLES_NO_EMBEDDED_LIBS=1 + export USE_PKGCONFIG=TRUE + + rm -r c-blosc/{blosc,internal-complibs} || die + rm tables/libblosc2.so || die + distutils-r1_python_prepare_all +} + +python_compile() { + distutils-r1_python_compile -j1 +} + +python_test() { + cd "${BUILD_DIR}"/lib* || die + "${EPYTHON}" tables/tests/test_all.py -v || die +} + +python_install_all() { + distutils-r1_python_install_all + + if use examples; then + dodoc -r contrib examples + docompress -x /usr/share/doc/${PF}/{contrib,examples} + fi +} diff --git a/dev-python/stapler/files/stapler-1.0.0_p20220330-fix-tests-for-PyPDF2-2.x.patch b/dev-python/stapler/files/stapler-1.0.0_p20220330-fix-tests-for-PyPDF2-2.x.patch new file mode 100644 index 000000000000..125b06a7735a --- /dev/null +++ b/dev-python/stapler/files/stapler-1.0.0_p20220330-fix-tests-for-PyPDF2-2.x.patch @@ -0,0 +1,13 @@ +diff --git a/staplelib/tests.py b/staplelib/tests.py +index 4d59153..447d48a 100755 +--- a/staplelib/tests.py ++++ b/staplelib/tests.py +@@ -5,7 +5,7 @@ import shutil + import tempfile + import unittest + +-from PyPDF2.pdf import PdfFileReader ++from PyPDF2 import PdfFileReader + + from staplelib import main, CommandError + diff --git a/dev-python/stapler/files/stapler-1.0.0_p20220330-port-to-PyPDF2-3.0.0.patch b/dev-python/stapler/files/stapler-1.0.0_p20220330-port-to-PyPDF2-3.0.0.patch new file mode 100644 index 000000000000..91eea95ae217 --- /dev/null +++ b/dev-python/stapler/files/stapler-1.0.0_p20220330-port-to-PyPDF2-3.0.0.patch @@ -0,0 +1,302 @@ +From 48d6ab21369f1e71dc57890f9bf78fff66c00a90 Mon Sep 17 00:00:00 2001 +From: Ben Kohler <bkohler@gentoo.org> +Date: Wed, 28 Dec 2022 10:08:30 -0600 +Subject: [PATCH 2/2] Port to PyPDF2-3.0.0 + +Lots of functions got renamed in the recent PyPDF2-3.0.0 release + +Signed-off-by: Ben Kohler <bkohler@gentoo.org> +--- + staplelib/commands.py | 46 +++++++++++++++++++++---------------------- + staplelib/iohelper.py | 12 +++++------ + staplelib/tests.py | 34 ++++++++++++++++---------------- + 3 files changed, 46 insertions(+), 46 deletions(-) + +diff --git a/staplelib/commands.py b/staplelib/commands.py +index d37bfa7..caf75f9 100644 +--- a/staplelib/commands.py ++++ b/staplelib/commands.py +@@ -4,9 +4,9 @@ import math + import os + + try: +- from PyPDF2 import PdfFileWriter, PdfFileReader ++ from PyPDF2 import PdfWriter, PdfReader + except: +- from pyPdf import PdfFileWriter, PdfFileReader ++ from pyPdf import PdfWriter, PdfReader + + from . import CommandError, iohelper + import staplelib +@@ -33,7 +33,7 @@ def select(args, inverse=False): + if not filesandranges or not outputfilename: + raise CommandError("Both input and output filenames are required.") + +- output = PdfFileWriter() ++ output = PdfWriter() + try: + for input in filesandranges: + pdf = input['pdf'] +@@ -44,21 +44,21 @@ def select(args, inverse=False): + if not inverse: + pagerange = input['pages'] or [ + (p, iohelper.ROTATION_NONE) for p in +- range(1, pdf.getNumPages() + 1)] ++ range(1, len(pdf.pages) + 1)] + else: + excluded = [p for p, r in input['pages']] + pagerange = [(p, iohelper.ROTATION_NONE) for p in +- range(1, pdf.getNumPages() + 1) if ++ range(1, len(pdf.pages) + 1) if + p not in excluded] + + for pageno, rotate in pagerange: +- if 1 <= pageno <= pdf.getNumPages(): ++ if 1 <= pageno <= len(pdf.pages): + if verbose: + print("Using page: {} (rotation: {} deg.)".format( + pageno, rotate)) + +- output.addPage(pdf.getPage(pageno-1) +- .rotateClockwise(rotate)) ++ output.add_page(pdf.pages[pageno-1] ++ .rotate(rotate)) + else: + raise CommandError("Page {} not found in {}.".format( + pageno, input['name'])) +@@ -98,14 +98,14 @@ def split(args): + base, + '_', + '%0', +- str(math.ceil(math.log10(input.getNumPages()))), ++ str(math.ceil(math.log10(len(input.pages)))), + 'd', + ext + ]) + +- for pageno in range(input.getNumPages()): +- output = PdfFileWriter() +- output.addPage(input.getPage(pageno)) ++ for pageno in range(len(input.pages)): ++ output = PdfWriter() ++ output.add_page(input.pages[pageno]) + + outputname = output_template % (pageno + 1) + if verbose: +@@ -150,17 +150,17 @@ def zip_pdf_pages(filesandranges, verbose): + # empty range means "include all pages" + pagerange = input['pages'] or [ + (p, iohelper.ROTATION_NONE) for p in +- range(1, pdf.getNumPages() + 1)] ++ range(1, len(pdf.pages) + 1)] + + pagestozip = [] + for pageno, rotate in pagerange: +- if 1 <= pageno <= pdf.getNumPages(): ++ if 1 <= pageno <= len(pdf.pages): + if verbose: + print("Using page: {} (rotation: {} deg.)".format( + pageno, rotate)) + +- pagestozip.append(pdf.getPage(pageno-1) +- .rotateClockwise(rotate)) ++ pagestozip.append(pdf.pages[pageno-1] ++ .rotate(rotate)) + else: + raise CommandError("Page {} not found in {}.".format( + pageno, input['name'])) +@@ -181,7 +181,7 @@ def background(args): + try: + filestozip = zip_pdf_pages(filesandranges, verbose) + +- output = PdfFileWriter() ++ output = PdfWriter() + for pageno in range(max(map(len, filestozip))): + page = None + for listno in range(len(filestozip)): +@@ -190,8 +190,8 @@ def background(args): + if not page: + page = p + else: +- page.mergePage(p) +- output.addPage(page) ++ page.merge_page(p) ++ output.add_page(page) + + except Exception as e: + import sys +@@ -213,11 +213,11 @@ def zip(args): + filestozip = zip_pdf_pages(filesandranges, verbose) + + # Interweave pages. +- output = PdfFileWriter() ++ output = PdfWriter() + for pageno in range(max(map(len, filestozip))): + for listno in range(len(filestozip)): + if pageno < len(filestozip[listno]): +- output.addPage(filestozip[listno][pageno]) ++ output.add_page(filestozip[listno][pageno]) + + _write_output(output, outputfilename) + +@@ -266,7 +266,7 @@ def pdf_page_enumeration(pdf): + pagelabels = pdf.trailer["/Root"]["/PageLabels"] + except: + # ("No /Root/PageLabels object"), so infer the list. +- return range(1, pdf.getNumPages() + 1) ++ return range(1, len(pdf.pages) + 1) + + # """Select the item that is most likely to contain the information you desire; e.g. + # {'/Nums': [0, IndirectObject(42, 0)]} +@@ -292,7 +292,7 @@ def pdf_page_enumeration(pdf): + style = '/D' + prefix = '' + next_pageno = 1 +- for i in range(0, pdf.getNumPages()): ++ for i in range(0, len(pdf.pages)): + if len(pagelabels_nums_list) > 0 and i >= pagelabels_nums_list[0]: + pagelabels_nums_list.pop(0) # discard index + pnle = pagelabels_nums_list.pop(0) +diff --git a/staplelib/iohelper.py b/staplelib/iohelper.py +index 959e900..8df365c 100644 +--- a/staplelib/iohelper.py ++++ b/staplelib/iohelper.py +@@ -7,9 +7,9 @@ import re + import sys + + try: +- from PyPDF2 import PdfFileWriter, PdfFileReader ++ from PyPDF2 import PdfWriter, PdfReader + except ImportError: +- from pyPdf import PdfFileWriter, PdfFileReader ++ from pyPdf import PdfWriter, PdfReader + + + from . import CommandError +@@ -31,8 +31,8 @@ def read_pdf(filename): + """Open a PDF file with PyPDF2.""" + if not os.path.exists(filename): + raise CommandError("{} does not exist".format(filename)) +- pdf = PdfFileReader(open(filename, "rb")) +- if pdf.isEncrypted: ++ pdf = PdfReader(open(filename, "rb")) ++ if pdf.is_encrypted: + while True: + pw = prompt_for_pw(filename) + matched = pdf.decrypt(pw) +@@ -46,7 +46,7 @@ def read_pdf(filename): + def write_pdf(pdf, filename): + force = staplelib.OPTIONS.force + +- """Write the content of a PdfFileWriter object to a file.""" ++ """Write the content of a PdfWriter object to a file.""" + if os.path.exists(filename) and not force: + raise CommandError("File already exists: {}".format(filename)) + +@@ -123,7 +123,7 @@ def parse_ranges(handles_files_and_ranges): + "page range '{}'".format(handle_key, inputname)) + + current = operations[-1] +- max_page = current['pdf'].getNumPages() ++ max_page = len(current['pdf'].pages) + # allow "end" as alias for the last page + replace_end = lambda page: ( + max_page if page.lower() == 'end' else int(page)) +diff --git a/staplelib/tests.py b/staplelib/tests.py +index 4d59153..3350dfc 100755 +--- a/staplelib/tests.py ++++ b/staplelib/tests.py +@@ -5,7 +5,7 @@ import shutil + import tempfile + import unittest + +-from PyPDF2 import PdfFileReader ++from PyPDF2 import PdfReader + + from staplelib import main, CommandError + +@@ -38,40 +38,40 @@ class TestStapler(unittest.TestCase): + self.outputfile]) + self.assertTrue(os.path.isfile(self.outputfile)) + with open(self.outputfile, 'rb') as outputfile: +- pdf = PdfFileReader(outputfile) +- self.assertEqual(pdf.getNumPages(), 6) ++ pdf = PdfReader(outputfile) ++ self.assertEqual(len(pdf.pages), 6) + + def test_sel_one_page(self): + """Test select of a one page from a PDF file.""" + run_stapler(['sel', 'A=' + FIVEPAGE_PDF, 'A2', self.outputfile]) + self.assertTrue(os.path.isfile(self.outputfile)) + with open(self.outputfile, 'rb') as outputfile: +- pdf = PdfFileReader(outputfile) +- self.assertEqual(pdf.getNumPages(), 1) ++ pdf = PdfReader(outputfile) ++ self.assertEqual(len(pdf.pages), 1) + + def test_sel_range(self): + """Test select of more pages from a PDF file.""" + run_stapler(['cat', 'A=' + FIVEPAGE_PDF, 'A2-4', self.outputfile]) + self.assertTrue(os.path.isfile(self.outputfile)) + with open(self.outputfile, 'rb') as outputfile: +- pdf = PdfFileReader(outputfile) +- self.assertEqual(pdf.getNumPages(), 3) ++ pdf = PdfReader(outputfile) ++ self.assertEqual(len(pdf.pages), 3) + + def test_del_one_page(self): + """Test del command for inverse select of one page.""" + run_stapler(['del', 'A=' + FIVEPAGE_PDF, 'A1', self.outputfile]) + self.assertTrue(os.path.isfile(self.outputfile)) + with open(self.outputfile, 'rb') as outputfile: +- pdf = PdfFileReader(outputfile) +- self.assertEqual(pdf.getNumPages(), 4) ++ pdf = PdfReader(outputfile) ++ self.assertEqual(len(pdf.pages), 4) + + def test_del_range(self): + """Test del command for inverse select multiple pages.""" + run_stapler(['del', 'A=' + FIVEPAGE_PDF, 'A2-4', self.outputfile]) + self.assertTrue(os.path.isfile(self.outputfile)) + with open(self.outputfile, 'rb') as outputfile: +- pdf = PdfFileReader(outputfile) +- self.assertEqual(pdf.getNumPages(), 2) ++ pdf = PdfReader(outputfile) ++ self.assertEqual(len(pdf.pages), 2) + + def test_split(self): + """Make sure a file is properly split into pages.""" +@@ -81,24 +81,24 @@ class TestStapler(unittest.TestCase): + self.assertEqual(len(filelist), 5) + for f in os.listdir(self.tmpdir): + with open(os.path.join(self.tmpdir, f), 'rb') as pdf_file: +- pdf = PdfFileReader(pdf_file) +- self.assertEqual(pdf.getNumPages(), 1) ++ pdf = PdfReader(pdf_file) ++ self.assertEqual(len(pdf.pages), 1) + + def test_background(self): + """Test background.""" + run_stapler(['background', ONEPAGE_PDF, FIVEPAGE_PDF, self.outputfile]) + self.assertTrue(os.path.isfile(self.outputfile)) + with open(self.outputfile, 'rb') as outputfile: +- pdf = PdfFileReader(outputfile) +- self.assertEqual(pdf.getNumPages(), 5) ++ pdf = PdfReader(outputfile) ++ self.assertEqual(len(pdf.pages), 5) + + def test_zip(self): + """Test zip.""" + run_stapler(['zip', ONEPAGE_PDF, FIVEPAGE_PDF, self.outputfile]) + self.assertTrue(os.path.isfile(self.outputfile)) + with open(self.outputfile, 'rb') as outputfile: +- pdf = PdfFileReader(outputfile) +- self.assertEqual(pdf.getNumPages(), 6) ++ pdf = PdfReader(outputfile) ++ self.assertEqual(len(pdf.pages), 6) + + def test_output_file_already_exists(self): + """Test zip.""" +-- +2.39.0 + diff --git a/dev-python/stapler/files/stapler-1.0.0_p20220330-use-poetry-core-backend-for-PEP517.patch b/dev-python/stapler/files/stapler-1.0.0_p20220330-use-poetry-core-backend-for-PEP517.patch new file mode 100644 index 000000000000..276df746791f --- /dev/null +++ b/dev-python/stapler/files/stapler-1.0.0_p20220330-use-poetry-core-backend-for-PEP517.patch @@ -0,0 +1,32 @@ +From 3907d86f515ff0e9f042df7111515205e9abaa11 Mon Sep 17 00:00:00 2001 +From: Ben Kohler <bkohler@gentoo.org> +Date: Thu, 26 May 2022 13:33:38 -0500 +Subject: [PATCH 1/2] pyproject.toml: use poetry-core backend for PEP517 + +Per poetry upstream, "If your pyproject.toml file still references +poetry directly as a build backend, you should update it to reference +poetry-core instead." + +https://python-poetry.org/docs/pyproject/#poetry-and-pep-517 +https://projects.gentoo.org/python/guide/distutils.html#deprecated-pep-517-backends + +Signed-off-by: Ben Kohler <bkohler@gentoo.org> +--- + pyproject.toml | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/pyproject.toml b/pyproject.toml +index efa98ea..d34823e 100644 +--- a/pyproject.toml ++++ b/pyproject.toml +@@ -28,5 +28,5 @@ pdf-stapler = 'staplelib:main' + + # this section is for PEP517 compliance. It is technically unnecessary if using Poetry + [build-system] +-requires = ["poetry>=1.0"] +-build-backend = "poetry.masonry.api" ++requires = ["poetry-core>=1.0.0"] ++build-backend = "poetry.core.masonry.api" +-- +2.39.0 + diff --git a/dev-python/stapler/stapler-1.0.0_p20220330.ebuild b/dev-python/stapler/stapler-1.0.0_p20220330-r1.ebuild index 2c44cfed2ff0..5d8a216715c6 100644 --- a/dev-python/stapler/stapler-1.0.0_p20220330.ebuild +++ b/dev-python/stapler/stapler-1.0.0_p20220330-r1.ebuild @@ -19,8 +19,8 @@ LICENSE="BSD" SLOT="0" KEYWORDS="~amd64 ~x86" -DEPEND="test? ( dev-python/PyPDF2[${PYTHON_USEDEP}] )" -RDEPEND="dev-python/PyPDF2[${PYTHON_USEDEP}]" +DEPEND="test? ( <dev-python/PyPDF2-3[${PYTHON_USEDEP}] )" +RDEPEND="<dev-python/PyPDF2-3[${PYTHON_USEDEP}]" distutils_enable_tests unittest diff --git a/dev-python/stapler/stapler-1.0.0_p20220330-r2.ebuild b/dev-python/stapler/stapler-1.0.0_p20220330-r2.ebuild new file mode 100644 index 000000000000..128ed8aaebc6 --- /dev/null +++ b/dev-python/stapler/stapler-1.0.0_p20220330-r2.ebuild @@ -0,0 +1,29 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{7,8,9,10,11} ) +DISTUTILS_USE_PEP517=poetry + +inherit distutils-r1 + +COMMIT="382f1edc62296e071093a5419811a2fca9d78d93" + +DESCRIPTION="Suite of tools for PDF files manipulation written in Python" +HOMEPAGE="https://github.com/hellerbarde/stapler" +SRC_URI="https://github.com/hellerbarde/${PN}/archive/${COMMIT}.tar.gz -> ${P}.tar.gz" +S="${WORKDIR}/${PN}-${COMMIT}" + +LICENSE="BSD" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +DEPEND="test? ( >=dev-python/PyPDF2-3.0.0[${PYTHON_USEDEP}] )" +RDEPEND=">=dev-python/PyPDF2-3.0.0[${PYTHON_USEDEP}]" + +distutils_enable_tests unittest + +PATCHES=( "${FILESDIR}"/${P}-fix-tests-for-PyPDF2-2.x.patch + "${FILESDIR}"/${P}-port-to-PyPDF2-3.0.0.patch + "${FILESDIR}"/${P}-use-poetry-core-backend-for-PEP517.patch ) diff --git a/dev-python/tox/Manifest b/dev-python/tox/Manifest index a86b2bc96599..ee227995b6d7 100644 --- a/dev-python/tox/Manifest +++ b/dev-python/tox/Manifest @@ -3,3 +3,4 @@ DIST tox-3.28.0.gh.tar.gz 309472 BLAKE2B 9896411426f6aebb3efa468c01696ecc5f17ec3 DIST tox-4.0.16.gh.tar.gz 283676 BLAKE2B b9b8149dcfa141518cb18a0ac3263c65f4928fc068357d7a513971d7037cc60cb4b3627d61d3e3479622b9fcbdc235356ca97cde993ab47db7abf4755854b17d SHA512 db4428b576dd3b669969b2390203ba6a0efa85f60073374b32c7ff1273745dde59ef0ffd404a7db98ca9056c5d5b5bd1811b51af7b475c116816c150c4d88c4c DIST tox-4.0.17.gh.tar.gz 284062 BLAKE2B 65055fd793fa5d4006d0082a89d7f42452cc5b3d1507a87875175db334bf177efeefa8b3e671d9042b795d8f21898ea1b1650cb1337bb9581a3b83ce8b42fec7 SHA512 065f4b91c32902fc8a65b5529e615af428a5ee8f8ad5cebee6c4ba14ceea315844cda8c6d2a882ba34baf7369d5676f210752d89d1cb3f9e2c7d7af790481193 DIST tox-4.0.18.gh.tar.gz 284137 BLAKE2B b507b0a15664656f381bc06356adb04c5fdfbe52deeef673e4ccc3d7a45d8cec10de80f6fe141a35bf529b020d5d8579c4dd6e4e3aa323bad320c7fcc6c34d18 SHA512 cd10cd4194002644d57fc63295099fccf6ffdaa2eeaf7bfe2f47c85d76dc115f9faa78ce0cfc43603b11ec04abaf4d41fe653fa48bff71e71ab7d102356ec5b8 +DIST tox-4.0.19.gh.tar.gz 284319 BLAKE2B f0ed3d300e0fadfaa5725589cea91511ed0c37937dc3761b203cfd1f0a5cf4033b6006e693521c932d3af64feb150951c046f5853a8b9bb9e37dcf3c5db4de95 SHA512 27d01b96acf4f7650b5a4a3ad80293ea884ee6791ff2e734cb64c94551943af1fb91804944f7ae82937fe4172522c0d5e4f24e84d35012d11657adc49702fc88 diff --git a/dev-python/tox/tox-4.0.19.ebuild b/dev-python/tox/tox-4.0.19.ebuild new file mode 100644 index 000000000000..ecac4627b405 --- /dev/null +++ b/dev-python/tox/tox-4.0.19.ebuild @@ -0,0 +1,91 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=hatchling +PYTHON_COMPAT=( python3_{7,8,9,10,11} pypy3 ) + +inherit distutils-r1 + +MY_P=${P/_} +DESCRIPTION="virtualenv-based automation of test activities" +HOMEPAGE=" + https://tox.readthedocs.io/ + https://github.com/tox-dev/tox/ + https://pypi.org/project/tox/ +" +SRC_URI=" + https://github.com/tox-dev/tox/archive/${PV/_}.tar.gz + -> ${MY_P}.gh.tar.gz +" +S=${WORKDIR}/${MY_P} + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~amd64 ~ppc" + +RDEPEND=" + >=dev-python/cachetools-5.2[${PYTHON_USEDEP}] + >=dev-python/chardet-5.1[${PYTHON_USEDEP}] + >=dev-python/colorama-0.4.6[${PYTHON_USEDEP}] + >=dev-python/filelock-3.8.2[${PYTHON_USEDEP}] + >=dev-python/packaging-21.3[${PYTHON_USEDEP}] + >=dev-python/platformdirs-2.6[${PYTHON_USEDEP}] + >=dev-python/pluggy-1[${PYTHON_USEDEP}] + >=dev-python/pyproject-api-1.2.1[${PYTHON_USEDEP}] + $(python_gen_cond_dep ' + >=dev-python/tomli-2.0.1[${PYTHON_USEDEP}] + ' 3.8 3.9 3.10) + >=dev-python/virtualenv-20.17.1[${PYTHON_USEDEP}] +" +BDEPEND=" + >=dev-python/hatch-vcs-0.3[${PYTHON_USEDEP}] + test? ( + dev-python/build[${PYTHON_USEDEP}] + >=dev-python/distlib-0.3.6[${PYTHON_USEDEP}] + >=dev-python/flaky-3.7[${PYTHON_USEDEP}] + >=dev-python/psutil-5.9.4[${PYTHON_USEDEP}] + dev-python/pytest-mock[${PYTHON_USEDEP}] + >=dev-python/pytest-xdist-3.1[${PYTHON_USEDEP}] + >=dev-python/re-assert-1.1[${PYTHON_USEDEP}] + $(python_gen_cond_dep ' + >=dev-python/time-machine-2.8.2[${PYTHON_USEDEP}] + ' 'python*') + ) +" + +distutils_enable_tests pytest + +export SETUPTOOLS_SCM_PRETEND_VERSION=${PV} + +src_prepare() { + # the minimal bounds in tox are entirely meaningless and new packaging + # breaks setuptools + sed -i -e '/packaging/s:>=22::' pyproject.toml || die + distutils-r1_src_prepare +} + +python_test() { + # devpi_process is not packaged, and has lots of dependencies + cat > "${T}"/devpi_process.py <<-EOF || die + def IndexServer(*args, **kwargs): raise NotImplementedError() + EOF + + local -x PYTHONPATH=${T}:${PYTHONPATH} + local EPYTEST_DESELECT=( + # Internet + tests/tox_env/python/virtual_env/package/test_package_cmd_builder.py::test_build_wheel_external + ) + local EPYTEST_IGNORE=( + # requires devpi* + tests/test_provision.py + ) + if ! has_version "dev-python/time_machine[${PYTHON_USEDEP}]"; then + EPYTEST_IGNORE+=( + tests/util/test_spinner.py + ) + fi + + epytest +} diff --git a/dev-python/xlsxwriter/Manifest b/dev-python/xlsxwriter/Manifest index 57ed2a081a4c..1f8917edde83 100644 --- a/dev-python/xlsxwriter/Manifest +++ b/dev-python/xlsxwriter/Manifest @@ -1 +1,2 @@ DIST XlsxWriter-RELEASE_3.0.3.tar.gz 35519702 BLAKE2B f4dfa6b286dda94a1a44d8168b8e17f7a37f2f59a23aa3a5ed0efa46b5d8bdcdb831e99a61924e22755c6a921c23f5c540c048152cd07363841ff09a49549c79 SHA512 92a53226aa9ee9f8493fe7171ce752f3a13ef8f3107aecbef896f17022e93bd7dbccb5e619fcbbb3598102030b190d75508d4dacce20b9643eead59a4441f6aa +DIST XlsxWriter-RELEASE_3.0.4.gh.tar.gz 35033608 BLAKE2B 49a54380f1753077f0d9e56024a09ffd9d26540daeb03c270e892ae986c8e36fb0ce74ab96e62b1cb15adebbb51ba2093b6b1e356077433537af62ededd79d5c SHA512 e10bbbcc975ee3c2395c642c7a04e53d792b8c739c9f5acbb3858b47963a0f9b68ac565d96d4a9f9c87b104fc02b8930b0629e753d53735892e10bd17e5c1fcc diff --git a/dev-python/xlsxwriter/xlsxwriter-3.0.4.ebuild b/dev-python/xlsxwriter/xlsxwriter-3.0.4.ebuild new file mode 100644 index 000000000000..2a188961ee16 --- /dev/null +++ b/dev-python/xlsxwriter/xlsxwriter-3.0.4.ebuild @@ -0,0 +1,28 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=setuptools +PYTHON_COMPAT=( python3_{7,8,9,10,11} pypy3 ) + +inherit distutils-r1 + +TAG=RELEASE_${PV} +MY_P=XlsxWriter-${TAG} +DESCRIPTION="Python module for creating Excel XLSX files" +HOMEPAGE=" + https://github.com/jmcnamara/XlsxWriter/ + https://pypi.org/project/XlsxWriter/ +" +SRC_URI=" + https://github.com/jmcnamara/XlsxWriter/archive/${TAG}.tar.gz + -> ${MY_P}.gh.tar.gz +" +S=${WORKDIR}/${MY_P} + +SLOT="0" +LICENSE="BSD" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux" + +distutils_enable_tests pytest diff --git a/dev-python/xxhash/Manifest b/dev-python/xxhash/Manifest index f35f9c821333..eb61887a7efd 100644 --- a/dev-python/xxhash/Manifest +++ b/dev-python/xxhash/Manifest @@ -1 +1,2 @@ DIST xxhash-3.1.0.tar.gz 74389 BLAKE2B c2c7467aca51a397366c9de47104831f2d3d732b6b287e3fce4a0481d21bf059330dd63e1372b8da3aa9354efbc3de6ba106501d86c907b5783f7192e5e7c9a1 SHA512 a1d78dbbcc8fc8e41b6bc1d9e571df6951d4545fe61b198427db6f8c99058a095cf20e09951acc7bf9b432963f8b234741ae1f15ebb19972e69be0c59c9eb165 +DIST xxhash-3.2.0.tar.gz 74561 BLAKE2B d2c32b9a556eaaa67d961e130b017ff82944fbec983f24e0356436a7a23927faaba118328eff508e288e0757a1379b5ff88a48c2130eb9b3cf347e178cfc810d SHA512 bbe903b95de3e91177064986adc5c945a9b7058650ea2b5cc10ee162a15a42909dc69f95b86081b8d276960f309b4bacf895ad263a9d9188fa66bb216d76dcd5 diff --git a/dev-python/xxhash/xxhash-3.2.0.ebuild b/dev-python/xxhash/xxhash-3.2.0.ebuild new file mode 100644 index 000000000000..d222c0ee2dbc --- /dev/null +++ b/dev-python/xxhash/xxhash-3.2.0.ebuild @@ -0,0 +1,38 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=setuptools +PYTHON_COMPAT=( python3_{7,8,9,10,11} ) + +inherit distutils-r1 + +DESCRIPTION="Python binding for the xxHash library" +HOMEPAGE=" + https://github.com/ifduyue/python-xxhash/ + https://pypi.org/project/xxhash/ +" +SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~amd64 ~arm64 ~x86" + +DEPEND=" + >=dev-libs/xxhash-0.8.0 +" +RDEPEND=" + ${DEPEND} +" + +distutils_enable_tests unittest + +python_configure_all() { + export XXHASH_LINK_SO=1 +} + +python_test() { + cd tests || die + eunittest +} |
