]>
Commit | Line | Data |
---|---|---|
1 | Summary: A minimalistic C client library for Redis | |
2 | Name: hiredis | |
3 | Version: 0.10.0 | |
4 | Release: 1 | |
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 | |
10 | Patch0: link.patch | |
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}-*/* . | |
28 | %patch0 -p1 | |
29 | ||
30 | %build | |
31 | %{__make} \ | |
32 | CC="%{__cc}" \ | |
33 | DEBUG="" \ | |
34 | LDFLAGS="-L. %{rpmldflags}" \ | |
35 | OPTIMIZATION="%{rpmcflags}" | |
36 | ||
37 | %install | |
38 | rm -rf $RPM_BUILD_ROOT | |
39 | %{__make} install \ | |
40 | INSTALL="cp -a" \ | |
41 | PREFIX=$RPM_BUILD_ROOT%{_prefix} \ | |
42 | INSTALL_LIBRARY_PATH=$RPM_BUILD_ROOT%{_libdir} | |
43 | ||
44 | install -d $RPM_BUILD_ROOT%{_bindir} | |
45 | install -p hiredis-example hiredis-test $RPM_BUILD_ROOT%{_bindir} | |
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 | |
60 | %attr(755,root,root) %{_libdir}/libhiredis.so.*.*.* | |
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 |