Merge from trunk.
[m6w6/libmemcached] / support / libmemcached.spec.in
1 Name: libmemcached
2 Summary: memcached C library and command line tools
3 Version: @VERSION@
4 Release: 1
5 License: BSD
6 Group: System Environment/Libraries
7 URL: http://tangent.org/552/libmemcached.html
8 Source0: http://download.tangent.org/libmemcached-%{version}.tar.gz
9
10 # For test suite
11 BuildRequires: memcached
12
13 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
14
15
16 %description
17 libmemcached is a C client library to the memcached server
18 (http://danga.com/memcached). It has been designed to be light on memory
19 usage, and provide full access to server side methods.
20
21 It also implements several command line tools:
22
23 memcat - Copy the value of a key to standard output.
24 memflush - Flush the contents of your servers.
25 memrm - Remove a key(s) from the serrver.
26 memstat - Dump the stats of your servers to standard output.
27 memslap - Generate testing loads on a memcached cluster.
28 memcp - Copy files to memcached servers.
29 memerror - Creates human readable messages from libmemecached error codes.
30
31
32 %package devel
33 Summary: Header files and development libraries for %{name}
34 Group: Development/Libraries
35 Requires: %{name} = %{version}-%{release}
36
37 %description devel
38 This package contains the header files and development libraries
39 for %{name}. If you like to develop programs using %{name},
40 you will need to install %{name}-devel.
41
42
43 %prep
44 %setup -q
45
46 %{__mkdir} examples
47 %{__cp} tests/*.{c,cpp,h} examples/
48
49
50 %build
51 %configure
52 %{__make} %{_smp_mflags}
53
54
55 %install
56 %{__rm} -rf %{buildroot}
57 %{__make} install DESTDIR="%{buildroot}" AM_INSTALL_PROGRAM_FLAGS=""
58
59
60 %check
61 # test suite cannot run in mock (same port use for memcache server on all arch)
62 # 1 test seems to fail..
63 #%{__make} test
64
65
66 %clean
67 %{__rm} -rf %{buildroot}
68
69
70 %post -p /sbin/ldconfig
71
72
73 %postun -p /sbin/ldconfig
74
75
76 %files
77 %defattr (-,root,root,-)
78 %doc AUTHORS COPYING NEWS README THANKS TODO
79 %{_bindir}/mem*
80 %exclude %{_libdir}/libmemcached.a
81 %exclude %{_libdir}/libmemcached.la
82 %exclude %{_libdir}/libmemcachedutil.a
83 %exclude %{_libdir}/libmemcachedprotocol.a
84 %exclude %{_libdir}/libmemcachedutil.la
85 %exclude %{_libdir}/libmemcachedprotocol.la
86 %{_libdir}/libmemcached.so.*
87 %{_libdir}/libmemcachedutil.so.*
88 %{_libdir}/libmemcachedprotocol.so.*
89 %{_mandir}/man1/mem*
90
91
92 %files devel
93 %defattr (-,root,root,-)
94 %doc examples
95 %{_includedir}/libmemcached
96 %{_libdir}/libmemcached.so
97 %{_libdir}/libmemcachedutil.so
98 %{_libdir}/libmemcachedprotocol.so
99 %{_libdir}/pkgconfig/libmemcached.pc
100 %{_mandir}/man3/libmemcached*.3.gz
101 %{_mandir}/man3/memcached_*.3.gz
102
103
104 %changelog
105 * Sat Apr 25 2009 Remi Collet <rpms@famillecollet.com> - 0.28-1
106 - Initial RPM from Brian Aker spec
107 - create -devel subpackage
108 - add %%post %%postun %%check section
109