1 |
commit: bfa0b339d6094863dd89316d742775398880d483 |
2 |
Author: Sven Wegener <swegener <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sat Jun 26 21:41:08 2021 +0000 |
4 |
Commit: Sven Wegener <swegener <AT> gentoo <DOT> org> |
5 |
CommitDate: Sat Jun 26 21:41:51 2021 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=bfa0b339 |
7 |
|
8 |
dev-python/hiredis: Version bump to 2.0.0 |
9 |
|
10 |
Package-Manager: Portage-3.0.20, Repoman-3.0.2 |
11 |
Signed-off-by: Sven Wegener <swegener <AT> gentoo.org> |
12 |
|
13 |
dev-python/hiredis/Manifest | 1 + |
14 |
.../hiredis/files/hiredis-2.0.0-system-libs.patch | 14 ++++++++++ |
15 |
dev-python/hiredis/hiredis-2.0.0.ebuild | 31 ++++++++++++++++++++++ |
16 |
3 files changed, 46 insertions(+) |
17 |
|
18 |
diff --git a/dev-python/hiredis/Manifest b/dev-python/hiredis/Manifest |
19 |
index 3504fdc829a..5f1ab167b26 100644 |
20 |
--- a/dev-python/hiredis/Manifest |
21 |
+++ b/dev-python/hiredis/Manifest |
22 |
@@ -1 +1,2 @@ |
23 |
DIST hiredis-1.1.0.tar.gz 54620 BLAKE2B 9991745d277e87efe836c1c8eabb2016ce401e2be52c7e1b3a154350776fae6fd3c49e3096da57231e42c57bf36ba692ce26bc993d0923b5246376d8694ad058 SHA512 ad37868376de91303c15ffe6109dc7fadb4f458efdd44b7ddc0a410937a389b8e062ab7d36b1aec3fe324ecafe6b1e5e6b92f547cbf619251dad22a28e02ee9c |
24 |
+DIST hiredis-2.0.0.tar.gz 75807 BLAKE2B dc7535f117c8ecfb2c924fe44a1cba2f02271c544588249de6794ce3aec27f66038ecb9f6364ca87b71f66ba13870a3be192eb79c1f360d2eb6dcb6dcae41caa SHA512 b9a313acdd00676dc046713a81bbf4336959f49f09bd2828997c23ca41259935047c657a4b6f81913715141a75fb6bbe7fc4429c7a5b0f4bc3d5de66b9cfa909 |
25 |
|
26 |
diff --git a/dev-python/hiredis/files/hiredis-2.0.0-system-libs.patch b/dev-python/hiredis/files/hiredis-2.0.0-system-libs.patch |
27 |
new file mode 100644 |
28 |
index 00000000000..74f14cdc00b |
29 |
--- /dev/null |
30 |
+++ b/dev-python/hiredis/files/hiredis-2.0.0-system-libs.patch |
31 |
@@ -0,0 +1,14 @@ |
32 |
+--- hiredis-2.0.0/setup.py |
33 |
++++ hiredis-2.0.0/setup.py |
34 |
+@@ -11,9 +11,8 @@ |
35 |
+ return module.__version__ |
36 |
+ |
37 |
+ ext = Extension("hiredis.hiredis", |
38 |
+- sources=sorted(glob.glob("src/*.c") + |
39 |
+- ["vendor/hiredis/%s.c" % src for src in ("alloc", "read", "sds")]), |
40 |
+- include_dirs=["vendor"]) |
41 |
++ sources=sorted(glob.glob("src/*.c")), |
42 |
++ libraries=["hiredis"]) |
43 |
+ |
44 |
+ setup( |
45 |
+ name="hiredis", |
46 |
|
47 |
diff --git a/dev-python/hiredis/hiredis-2.0.0.ebuild b/dev-python/hiredis/hiredis-2.0.0.ebuild |
48 |
new file mode 100644 |
49 |
index 00000000000..c2881e5aae3 |
50 |
--- /dev/null |
51 |
+++ b/dev-python/hiredis/hiredis-2.0.0.ebuild |
52 |
@@ -0,0 +1,31 @@ |
53 |
+# Copyright 1999-2021 Gentoo Authors |
54 |
+# Distributed under the terms of the GNU General Public License v2 |
55 |
+ |
56 |
+EAPI=7 |
57 |
+PYTHON_COMPAT=( python3_{8..10} ) |
58 |
+ |
59 |
+inherit distutils-r1 |
60 |
+ |
61 |
+DESCRIPTION="Python extension that wraps hiredis" |
62 |
+HOMEPAGE="https://github.com/redis/hiredis-py/" |
63 |
+SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz" |
64 |
+ |
65 |
+LICENSE="BSD" |
66 |
+SLOT="0" |
67 |
+KEYWORDS="~amd64 ~arm ~x86" |
68 |
+IUSE="system-libs" |
69 |
+ |
70 |
+DEPEND="system-libs? ( dev-libs/hiredis:0/1.0.0 )" |
71 |
+RDEPEND="${DEPEND}" |
72 |
+ |
73 |
+src_prepare() { |
74 |
+ use system-libs && PATCHES+=( |
75 |
+ "${FILESDIR}"/${P}-system-libs.patch |
76 |
+ ) |
77 |
+ default |
78 |
+} |
79 |
+ |
80 |
+python_test() { |
81 |
+ cd test || die |
82 |
+ "${EPYTHON}" -m unittest reader.ReaderTest || die "tests failed" |
83 |
+} |