1 |
commit: 35a31490e10134dfacead33b97686749e61c6652 |
2 |
Author: Tomas Mozes <hydrapolic <AT> gmail <DOT> com> |
3 |
AuthorDate: Thu Oct 25 07:16:54 2018 +0000 |
4 |
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri Oct 26 09:50:00 2018 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=35a31490 |
7 |
|
8 |
dev-libs/hiredis: bump to 0.14.0 |
9 |
|
10 |
Bug: https://bugs.gentoo.org/669484 |
11 |
Closes: https://bugs.gentoo.org/669554 |
12 |
Signed-off-by: Tomáš Mózes <hydrapolic <AT> gmail.com> |
13 |
Package-Manager: Portage-2.3.51, Repoman-2.3.11 |
14 |
Closes: https://github.com/gentoo/gentoo/pull/10223 |
15 |
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org> |
16 |
|
17 |
dev-libs/hiredis/Manifest | 1 + |
18 |
dev-libs/hiredis/hiredis-0.14.0.ebuild | 78 ++++++++++++++++++++++++++++++++++ |
19 |
2 files changed, 79 insertions(+) |
20 |
|
21 |
diff --git a/dev-libs/hiredis/Manifest b/dev-libs/hiredis/Manifest |
22 |
index a97852fe607..f34a3040d70 100644 |
23 |
--- a/dev-libs/hiredis/Manifest |
24 |
+++ b/dev-libs/hiredis/Manifest |
25 |
@@ -1 +1,2 @@ |
26 |
DIST hiredis-0.13.3.tar.gz 58291 BLAKE2B 2af5853475a48b1f05c17100197633af61663a23a1259c702545938367b6a5b9fc09b886e12f57d27f23db3f5c636bb42d7e58887cc1481b7016cea405345ddb SHA512 0d8b71d5ee4105e8aaeeee308795afc2c1f60a04b0bfe8ae873d800a0c157882ec307efa04a8d0e63b538fd3fc3f88eedf4d46cb87c8937e2403927aeb7e434c |
27 |
+DIST hiredis-0.14.0.tar.gz 63061 BLAKE2B 1923a63317f5f4a5bcbc9f8fd35e11fda15c30bb766d377f3be1eaf961cf34339e16b9b7c468b5bf07e513db4913c564e49eb29a2684b945db6c914b07d01905 SHA512 57a81a35b4750f0ca9dba830789483667f8ca1559f13b0ebdc3fab3e34ad16b2809f9734cf88157041263784e11447556b7a748bfb7ef318a60bb5dda3e358a0 |
28 |
|
29 |
diff --git a/dev-libs/hiredis/hiredis-0.14.0.ebuild b/dev-libs/hiredis/hiredis-0.14.0.ebuild |
30 |
new file mode 100644 |
31 |
index 00000000000..ab120cee20d |
32 |
--- /dev/null |
33 |
+++ b/dev-libs/hiredis/hiredis-0.14.0.ebuild |
34 |
@@ -0,0 +1,78 @@ |
35 |
+# Copyright 1999-2018 Gentoo Authors |
36 |
+# Distributed under the terms of the GNU General Public License v2 |
37 |
+ |
38 |
+EAPI="7" |
39 |
+ |
40 |
+inherit toolchain-funcs |
41 |
+ |
42 |
+DESCRIPTION="Minimalistic C client library for the Redis database" |
43 |
+HOMEPAGE="https://github.com/redis/hiredis" |
44 |
+SRC_URI="https://github.com/redis/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" |
45 |
+ |
46 |
+LICENSE="BSD" |
47 |
+SLOT="0/0.14" |
48 |
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sparc ~x86 ~x86-fbsd ~x64-solaris" |
49 |
+IUSE="examples static-libs test" |
50 |
+ |
51 |
+DEPEND="test? ( dev-db/redis )" |
52 |
+ |
53 |
+src_prepare() { |
54 |
+ local PATCHES=( "${FILESDIR}/${PN}-0.13.3-disable-network-tests.patch" ) |
55 |
+ default |
56 |
+ |
57 |
+ # use GNU ld syntax on Solaris |
58 |
+ sed -i -e '/DYLIB_MAKE_CMD=.* -G/d' Makefile || die |
59 |
+} |
60 |
+ |
61 |
+_build() { |
62 |
+ emake \ |
63 |
+ AR="$(tc-getAR)" \ |
64 |
+ CC="$(tc-getCC)" \ |
65 |
+ PREFIX="${EPREFIX%/}/usr" \ |
66 |
+ LIBRARY_PATH="$(get_libdir)" \ |
67 |
+ ARCH= \ |
68 |
+ DEBUG= \ |
69 |
+ OPTIMIZATION="${CPPFLAGS}" \ |
70 |
+ "$@" |
71 |
+} |
72 |
+ |
73 |
+src_compile() { |
74 |
+ # The static lib re-uses the same objects as the shared lib, so |
75 |
+ # overhead is low w/creating it all the time. It's also needed |
76 |
+ # by the tests. |
77 |
+ _build dynamic static hiredis.pc |
78 |
+} |
79 |
+ |
80 |
+src_test() { |
81 |
+ local REDIS_PID="${T}"/hiredis.pid |
82 |
+ local REDIS_SOCK="${T}"/hiredis.sock |
83 |
+ local REDIS_PORT=56379 |
84 |
+ local REDIS_TEST_CONFIG="daemonize yes |
85 |
+ pidfile ${REDIS_PID} |
86 |
+ port ${REDIS_PORT} |
87 |
+ bind 127.0.0.1 |
88 |
+ unixsocket //${REDIS_SOCK}" |
89 |
+ |
90 |
+ _build hiredis-test |
91 |
+ |
92 |
+ /usr/sbin/redis-server - <<< "${REDIS_TEST_CONFIG}" || die |
93 |
+ ./hiredis-test -h 127.0.0.1 -p ${REDIS_PID} -s ${REDIS_SOCK} |
94 |
+ local ret=$? |
95 |
+ |
96 |
+ kill "$(<"${REDIS_PID}")" || die |
97 |
+ [ ${ret} != "0" ] && die "tests failed" |
98 |
+} |
99 |
+ |
100 |
+src_install() { |
101 |
+ _build PREFIX="${ED%/}/usr" install |
102 |
+ if ! use static-libs; then |
103 |
+ rm "${ED%/}/usr/$(get_libdir)/libhiredis.a" || die |
104 |
+ fi |
105 |
+ |
106 |
+ insinto /usr/$(get_libdir)/pkgconfig |
107 |
+ doins ${PN}.pc |
108 |
+ |
109 |
+ local DOCS=( CHANGELOG.md README.md ) |
110 |
+ use examples && DOCS+=( examples ) |
111 |
+ einstalldocs |
112 |
+} |