]>
Commit | Line | Data |
---|---|---|
0aa38b05 ER |
1 | Summary: A minimalistic C client library for Redis |
2 | Name: hiredis | |
3 | Version: 0.10.0 | |
e0ef7478 | 4 | Release: 1 |
0aa38b05 ER |
5 | License: BSD |
6 | Group: Libraries | |
7 | URL: https://github.com/antirez/hiredis | |
8 | Source0: https://github.com/antirez/hiredis/tarball/v%{version}/%{name}-%{version}.tgz | |
9 | # Source0-md5: 66edb31cdc39c94978ddf98538259d72 | |
e0ef7478 | 10 | Patch0: link.patch |
0aa38b05 ER |
11 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
12 | ||
13 | %description | |
14 | Hiredis is a minimalistic C client library for the Redis database. | |
15 | ||
16 | %package devel | |
17 | Summary: Header files and libraries for hiredis C development | |
18 | Group: Development/Libraries | |
19 | Requires: %{name} = %{version}-%{release} | |
20 | ||
21 | %description devel | |
22 | The %{name}-devel package contains the header files and libraries to | |
23 | develop applications using a Redis database. | |
24 | ||
25 | %prep | |
26 | %setup -qc | |
27 | mv *-%{name}-*/* . | |
e0ef7478 | 28 | %patch0 -p1 |
0aa38b05 ER |
29 | |
30 | %build | |
31 | %{__make} \ | |
e0ef7478 ER |
32 | CC="%{__cc}" \ |
33 | DEBUG="" \ | |
34 | LDFLAGS="-L. %{rpmldflags}" \ | |
35 | OPTIMIZATION="%{rpmcflags}" | |
0aa38b05 ER |
36 | |
37 | %install | |
38 | rm -rf $RPM_BUILD_ROOT | |
39 | %{__make} install \ | |
e0ef7478 | 40 | INSTALL="cp -a" \ |
0aa38b05 ER |
41 | PREFIX=$RPM_BUILD_ROOT%{_prefix} \ |
42 | INSTALL_LIBRARY_PATH=$RPM_BUILD_ROOT%{_libdir} | |
43 | ||
44 | install -d $RPM_BUILD_ROOT%{_bindir} | |
e0ef7478 | 45 | install -p hiredis-example hiredis-test $RPM_BUILD_ROOT%{_bindir} |
0aa38b05 ER |
46 | |
47 | find $RPM_BUILD_ROOT -name *.a | xargs rm -v | |
48 | ||
49 | %clean | |
50 | rm -rf $RPM_BUILD_ROOT | |
51 | ||
52 | %post -p /sbin/ldconfig | |
53 | %postun -p /sbin/ldconfig | |
54 | ||
55 | %files | |
56 | %defattr(644,root,root,755) | |
57 | %doc COPYING TODO | |
58 | %attr(755,root,root) %{_bindir}/hiredis-example | |
59 | %attr(755,root,root) %{_bindir}/hiredis-test | |
e0ef7478 | 60 | %attr(755,root,root) %{_libdir}/libhiredis.so.*.*.* |
0aa38b05 ER |
61 | %ghost %{_libdir}/libhiredis.so.0 |
62 | ||
63 | %files devel | |
64 | %defattr(644,root,root,755) | |
65 | %doc README.md | |
66 | %{_includedir}/%{name} | |
67 | %{_libdir}/libhiredis.so |