Gentoo Archives: gentoo-commits

From: Arthur Zamarin <arthurzam@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/zstandard/
Date: Wed, 19 Jan 2022 07:26:23
Message-Id: 1642576363.005ecf24a13f2fd873fab21a259038791931fa02.arthurzam@gentoo
1 commit: 005ecf24a13f2fd873fab21a259038791931fa02
2 Author: Arthur Zamarin <arthurzam <AT> gentoo <DOT> org>
3 AuthorDate: Wed Jan 19 07:12:43 2022 +0000
4 Commit: Arthur Zamarin <arthurzam <AT> gentoo <DOT> org>
5 CommitDate: Wed Jan 19 07:12:43 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=005ecf24
7
8 dev-python/zstandard: add 0.17.0
9
10 Signed-off-by: Arthur Zamarin <arthurzam <AT> gentoo.org>
11
12 dev-python/zstandard/Manifest | 1 +
13 dev-python/zstandard/zstandard-0.17.0.ebuild | 42 ++++++++++++++++++++++++++++
14 2 files changed, 43 insertions(+)
15
16 diff --git a/dev-python/zstandard/Manifest b/dev-python/zstandard/Manifest
17 index 093e0aae667c..e1832b9534a5 100644
18 --- a/dev-python/zstandard/Manifest
19 +++ b/dev-python/zstandard/Manifest
20 @@ -1 +1,2 @@
21 DIST zstandard-0.16.0.tar.gz 563633 BLAKE2B 8d896dcbd8ef9f9b28825d35792d02c3c447fa82ccef067deb925394c21da8f19a7faa4fbe84700fe5a0871af6d33d218c6134829d08eed93fd5ef43c3d0058c SHA512 f528cace58c1f1ec0fbea96e1646d92b05077ab6f5919eec07dc7b4fcfadf97dc848238928276fdb4333fb2cd035509af472ee352608661c3de681bc8dbed318
22 +DIST zstandard-0.17.0.tar.gz 629456 BLAKE2B 2b19c017b6255eaa22037e633f1f1dea1322c21dda3f1129e9593c5782b6cf3dbba12003711f6192bfa474a918cbf1eae2b5dd21fbf78731b8dfc62e69a27048 SHA512 312aa02c7309fac64cf70ca901942118d4b3f12f27d20cc18dcaba5ce155ad81ea8d7657501a33a5fb6cdc8bcca11f91141ea9d6c3fc09c28a84d698b9050391
23
24 diff --git a/dev-python/zstandard/zstandard-0.17.0.ebuild b/dev-python/zstandard/zstandard-0.17.0.ebuild
25 new file mode 100644
26 index 000000000000..2d942b9c0f95
27 --- /dev/null
28 +++ b/dev-python/zstandard/zstandard-0.17.0.ebuild
29 @@ -0,0 +1,42 @@
30 +# Copyright 1999-2022 Gentoo Authors
31 +# Distributed under the terms of the GNU General Public License v2
32 +
33 +EAPI=8
34 +
35 +PYTHON_COMPAT=( python3_{8..10} pypy3 )
36 +
37 +inherit distutils-r1
38 +
39 +DESCRIPTION="Zstandard Bindings for Python"
40 +HOMEPAGE="https://pypi.org/project/zstandard/ https://github.com/indygreg/python-zstandard"
41 +SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
42 +
43 +SLOT="0"
44 +LICENSE="BSD"
45 +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~riscv ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
46 +
47 +DEPEND="
48 + app-arch/zstd:="
49 +RDEPEND="${DEPEND}
50 + $(python_gen_cond_dep '>=dev-python/cffi-1.14.0-r2:=[${PYTHON_USEDEP}]' 'python*')
51 +"
52 +BDEPEND="
53 + test? ( dev-python/hypothesis[${PYTHON_USEDEP}] )"
54 +
55 +distutils_enable_tests setup.py
56 +
57 +src_prepare() {
58 + # the C backend is repeatedly broken, so force CFFI instead
59 + sed -e '/PYTHON_ZSTANDARD_IMPORT_POLICY/s:default:cffi:' \
60 + -i zstandard/__init__.py || die
61 + # unreliable, fails on x86
62 + sed -e 's:test_estimated_compression_context_size:_&:' \
63 + -i tests/test_data_structures.py || die
64 +
65 + distutils-r1_src_prepare
66 +
67 + DISTUTILS_ARGS=(
68 + --no-c-backend
69 + --system-zstd
70 + )
71 +}