]>
Commit | Line | Data |
---|---|---|
56126164 | 1 | Summary: A high-performance, distributed memory object caching system |
ee5b4f18 | 2 | Summary(pl.UTF-8): Rozproszony, wysokiej wydajności system cache'owania obiektów |
56126164 | 3 | Name: memcached |
54c3d350 | 4 | Version: 1.4.3 |
245e901a | 5 | Release: 1 |
ba4bd57b | 6 | License: BSD |
56126164 | 7 | Group: Networking/Daemons |
ae4347a2 | 8 | Source0: http://memcached.googlecode.com/files/%{name}-%{version}.tar.gz |
54c3d350 | 9 | # Source0-md5: 83c6cc6bad9612536b5acbbbddab3eb3 |
3a964b8a AM |
10 | Source1: %{name}.init |
11 | Source2: %{name}.sysconfig | |
56126164 | 12 | URL: http://www.danga.com/memcached/ |
aebd8fee | 13 | BuildRequires: autoconf |
56126164 | 14 | BuildRequires: automake |
e4a0c888 | 15 | BuildRequires: libevent-devel >= 1.1 |
3a5da022 ER |
16 | BuildRequires: rpmbuild(macros) >= 1.268 |
17 | Requires(post,preun): /sbin/chkconfig | |
371f8914 ER |
18 | Requires(postun): /usr/sbin/groupdel |
19 | Requires(postun): /usr/sbin/userdel | |
20 | Requires(pre): /bin/id | |
21 | Requires(pre): /usr/bin/getgid | |
22 | Requires(pre): /usr/sbin/groupadd | |
23 | Requires(pre): /usr/sbin/useradd | |
ab340080 | 24 | Requires: rc-scripts >= 0.4.1.23 |
371f8914 ER |
25 | Provides: group(memcached) |
26 | Provides: user(memcached) | |
56126164 MM |
27 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
28 | ||
29 | %description | |
30 | A high-performance, distributed memory object caching system. | |
31 | ||
1e501250 JR |
32 | %description -l pl.UTF-8 |
33 | Rozproszony, wysokiej wydajności system cache'owania obiektów. | |
56126164 MM |
34 | |
35 | %prep | |
36 | %setup -q | |
37 | ||
38 | %build | |
39 | %{__aclocal} | |
40 | %{__autoconf} | |
41 | %{__autoheader} | |
42 | %{__automake} | |
1856e00f ER |
43 | %configure \ |
44 | --disable-coverage | |
56126164 MM |
45 | %{__make} |
46 | ||
47 | %install | |
48 | rm -rf $RPM_BUILD_ROOT | |
371f8914 | 49 | install -d $RPM_BUILD_ROOT{/etc/{rc.d/init.d,sysconfig},/var/run/memcached} |
3f79a4b3 | 50 | install -d $RPM_BUILD_ROOT{%{_sbindir},%{_mandir}/man1} |
3a964b8a | 51 | |
3f79a4b3 | 52 | install memcached $RPM_BUILD_ROOT%{_sbindir} |
56126164 MM |
53 | install doc/memcached.1 $RPM_BUILD_ROOT%{_mandir}/man1 |
54 | ||
3a964b8a AM |
55 | install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name} |
56 | install %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/%{name} | |
57 | ||
371f8914 ER |
58 | %pre |
59 | %groupadd -g 209 %{name} | |
60 | %useradd -u 209 -d /usr/share/empty -g %{name} -c "Memcached User" %{name} | |
61 | ||
3a964b8a AM |
62 | %post |
63 | /sbin/chkconfig --add %{name} | |
64 | %service %{name} restart | |
65 | ||
66 | %preun | |
67 | if [ "$1" = "0" ]; then | |
68 | %service -q %{name} stop | |
69 | /sbin/chkconfig --del %{name} | |
70 | fi | |
71 | ||
371f8914 ER |
72 | %postun |
73 | if [ "$1" = "0" ]; then | |
74 | %userremove %{name} | |
75 | %groupremove %{name} | |
76 | fi | |
77 | ||
56126164 MM |
78 | %clean |
79 | rm -rf $RPM_BUILD_ROOT | |
80 | ||
81 | %files | |
82 | %defattr(644,root,root,755) | |
d8d64c97 | 83 | %doc AUTHORS README doc/*.txt |
3a964b8a | 84 | %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/%{name} |
371f8914 ER |
85 | %attr(754,root,root) /etc/rc.d/init.d/%{name} |
86 | %attr(755,root,root) %{_sbindir}/%{name} | |
87 | %{_mandir}/man1/memcached.1* | |
88 | %dir %attr(770,root,memcached) /var/run/memcached |