]> git.pld-linux.org Git - packages/corosync.git/blob - corosync.spec
0940660e8198e90c87a316b4e61af6fa1f896a57
[packages/corosync.git] / corosync.spec
1 #
2 # Conditional build:
3 %bcond_with     apidocs         # build apidocs (man3 pages are provided anyway)
4 %bcond_without  dbus            # DBus events
5 %bcond_without  rdma            # RDMA support
6 %bcond_without  snmp            # SNMP protocol support
7 #
8 Summary:        Corosync - OSI Certified implementation of a complete cluster engine
9 Summary(pl.UTF-8):      Corosync - implementacja silnika klastrowego certyfikowana przez OSI
10 Name:           corosync
11 Version:        1.4.3
12 Release:        2.1
13 License:        BSD
14 Group:          Base
15 Source0:        ftp://ftp:downloads@corosync.org/downloads/%{name}-%{version}/%{name}-%{version}.tar.gz
16 # Source0-md5:  9e9943a7d9eb90fabd52d12b215c699c
17 Source1:        %{name}.init
18 Source2:        %{name}-notifyd.init
19 Source3:        %{name}-notifyd.sysconfig
20 Patch0:         %{name}-makefile.patch
21 URL:            http://www.corosync.org/
22 BuildRequires:  autoconf >= 2.61
23 BuildRequires:  automake
24 %{?with_dbus:BuildRequires:     dbus-devel}
25 %{?with_apidocs:BuildRequires:  doxygen}
26 %if %{with rdma}
27 BuildRequires:  libibverbs-devel
28 BuildRequires:  librdmacm-devel
29 %endif
30 %{?with_snmp:BuildRequires:     net-snmp-devel}
31 BuildRequires:  nss-devel
32 BuildRequires:  pkgconfig
33 Requires:       %{name}-libs = %{version}-%{release}
34 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
35
36 # short_service_name_get() is defined in executable
37 %define         skip_post_check_so      libcoroipcs\.so.*
38
39 %description
40 The Corosync Cluster Engine is an OSI Certified implementation of a
41 complete cluster engine.
42
43 %description -l pl.UTF-8
44 Corosync Cluster Engine to implementacja pełnego silnika klastrowego
45 certyfikowana przez OSI.
46
47 %package libs
48 Summary:        Corosync Cluster Engine libraries
49 Summary(pl.UTF-8):      Biblioteki silnika klastrowego Corosync
50 Group:          Libraries
51
52 %description libs
53 This package contains the libraries of Corosync Cluster Engine, an OSI
54 Certified implementation of a complete cluster engine.
55
56 %description libs -l pl.UTF-8
57 Ten pakiet zawiera biblioteki Corosync Cluster Engine - pełnego
58 silnika klastrowego certyfikowanego przez OSI.
59
60 %package devel
61 Summary:        Header files for Corosync libraries
62 Summary(pl.UTF-8):      Pliki nagłówkowe bibliotek Corosync
63 Group:          Development/Libraries
64 Requires:       %{name}-libs = %{version}-%{release}
65 Conflicts:      openais-devel < 1.0
66
67 %description devel
68 This package contains the include files used to develop using Corosync
69 APIs.
70
71 %description devel -l pl.UTF-8
72 Ten pakiet zawiera pliki nagłówkowe potrzebne do tworzenia programów z
73 użyciem API Corosync.
74
75 %package static
76 Summary:        Corosync static libraries
77 Summary(pl.UTF-8):      Statyczne biblioteki Corosync
78 Group:          Development/Libraries
79 Requires:       %{name}-devel = %{version}-%{release}
80
81 %description static
82 This package contains the Corosync static libraries.
83
84 %description static -l pl.UTF-8
85 Ten pakiet zawiera statyczne biblioteki Corosync.
86
87 %package -n mibs-corosync
88 Summary:        Corosync SNMP MIB data
89 Summary(pl.UTF-8):      Dane SNMP MIB dla Corosync
90 Group:          Applications/System
91 Requires:       mibs-dirs
92
93 %description -n mibs-corosync
94 Corosync SNMP MIB data.
95
96 %description -n mibs-corosync -l pl.UTF-8
97 Dane SNMP MIB dla Corosync.
98
99 %prep
100 %setup -q
101 %patch0 -p1
102
103 %build
104 %{__aclocal}
105 %{__autoconf}
106 %{__autoheader}
107 %{__automake}
108 # options not yet supported: monitoring, watchdog, augeas
109 %configure \
110         %{?with_dbus:--enable-dbus} \
111         --enable-nss \
112         %{?with_rdma:--enable-rdma} \
113         %{?with_snmp:--enable-snmp} \
114         --with-initddir=/etc/rc.d/init.d \
115         --with-lcrso-dir=%{_libdir}/lcrso
116
117 %{__make}
118
119 %{?with_apidocs:%{__make} doxygen}
120
121 %install
122 rm -rf $RPM_BUILD_ROOT
123 install -d $RPM_BUILD_ROOT{/etc/rc.d/init.d,/etc/sysconfig}
124
125 %{__make} install \
126         DESTDIR=$RPM_BUILD_ROOT
127
128 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/corosync
129
130 sed -e 's/^/#/' $RPM_BUILD_ROOT%{_sysconfdir}/corosync/corosync.conf.example \
131         >$RPM_BUILD_ROOT%{_sysconfdir}/corosync/corosync.conf
132 %{__rm} $RPM_BUILD_ROOT%{_sysconfdir}/corosync/corosync.conf.example*
133
134 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}
135 install %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}-notifyd
136 install %{SOURCE3} $RPM_BUILD_ROOT/etc/sysconfig/%{name}-notifyd
137
138 %{?with_apidocs:install doc/api/man/man3/* $RPM_BUILD_ROOT%{_mandir}/man3}
139
140 %clean
141 rm -rf $RPM_BUILD_ROOT
142
143 %post
144 /sbin/chkconfig --add %{name}
145 /sbin/chkconfig --add %{name}-notifyd
146 %service %{name} restart
147 %service %{name}-notifyd restart
148 %systemd_post %{name}.service
149 %systemd_post %{name}-notifyd.service
150
151 %preun
152 if [ "$1" = "0" ]; then
153         %service -q %{name} stop
154         /sbin/chkconfig --del %{name}
155         %service -q %{name}-notifyd stop
156         /sbin/chkconfig --del %{name}-notifyd
157 fi
158 %systemd_preun %{name}.service
159 %systemd_preun %{name}-notifyd.service
160
161 %postun
162 %systemd_reload
163
164 %post   libs -p /sbin/ldconfig
165 %postun libs -p /sbin/ldconfig
166
167 %files
168 %defattr(644,root,root,755)
169 %doc AUTHORS ChangeLog LICENSE README.devmap README.recovery SECURITY TODO conf/corosync.conf.example*
170 %attr(754,root,root) /etc/rc.d/init.d/corosync
171 %attr(754,root,root) /etc/rc.d/init.d/corosync-notifyd
172 %verify(not md5 mtime size) %config(noreplace) /etc/sysconfig/%{name}-notifyd
173 %dir %{_sysconfdir}/corosync
174 %verify(not md5 mtime size) %config(noreplace) %{_sysconfdir}/corosync/corosync.conf
175 %attr(755,root,root) %{_bindir}/corosync-blackbox
176 %attr(755,root,root) %{_sbindir}/corosync
177 %attr(755,root,root) %{_sbindir}/corosync-cfgtool
178 %attr(755,root,root) %{_sbindir}/corosync-cpgtool
179 %attr(755,root,root) %{_sbindir}/corosync-fplay
180 %attr(755,root,root) %{_sbindir}/corosync-keygen
181 %attr(755,root,root) %{_sbindir}/corosync-notifyd
182 %attr(755,root,root) %{_sbindir}/corosync-objctl
183 %attr(755,root,root) %{_sbindir}/corosync-pload
184 %attr(755,root,root) %{_sbindir}/corosync-quorumtool
185 %attr(755,root,root) %{_libdir}/lcrso/*.lcrso
186 %{_mandir}/man5/corosync.conf.5*
187 %{_mandir}/man8/corosync.8*
188 %{_mandir}/man8/corosync-blackbox.8*
189 %{_mandir}/man8/corosync-cfgtool.8*
190 %{_mandir}/man8/corosync-cpgtool.8*
191 %{_mandir}/man8/corosync-fplay.8*
192 %{_mandir}/man8/corosync-keygen.8*
193 %{_mandir}/man8/corosync-notifyd.8*
194 %{_mandir}/man8/corosync-objctl.8*
195 %{_mandir}/man8/corosync-pload.8*
196 %{_mandir}/man8/corosync-quorumtool.8*
197 %dir %attr(700,root,root) /var/lib/corosync
198
199 %files libs
200 %defattr(644,root,root,755)
201 %attr(755,root,root) %{_libdir}/libcfg.so.4.*.*
202 %attr(755,root,root) %ghost %{_libdir}/libcfg.so.4
203 %attr(755,root,root) %{_libdir}/libconfdb.so.4.*.*
204 %attr(755,root,root) %ghost %{_libdir}/libconfdb.so.4
205 %attr(755,root,root) %{_libdir}/libcoroipcc.so.4.*.*
206 %attr(755,root,root) %ghost %{_libdir}/libcoroipcc.so.4
207 %attr(755,root,root) %{_libdir}/libcoroipcs.so.4.*.*
208 %attr(755,root,root) %ghost %{_libdir}/libcoroipcs.so.4
209 %attr(755,root,root) %{_libdir}/libcpg.so.4.*.*
210 %attr(755,root,root) %ghost %{_libdir}/libcpg.so.4
211 %attr(755,root,root) %{_libdir}/libevs.so.4.*.*
212 %attr(755,root,root) %ghost %{_libdir}/libevs.so.4
213 %attr(755,root,root) %{_libdir}/liblogsys.so.4.*.*
214 %attr(755,root,root) %ghost %{_libdir}/liblogsys.so.4
215 %attr(755,root,root) %{_libdir}/libpload.so.4.*.*
216 %attr(755,root,root) %ghost %{_libdir}/libpload.so.4
217 %attr(755,root,root) %{_libdir}/libsam.so.4.*.*
218 %attr(755,root,root) %ghost %{_libdir}/libsam.so.4
219 %attr(755,root,root) %{_libdir}/libquorum.so.4.*.*
220 %attr(755,root,root) %ghost %{_libdir}/libquorum.so.4
221 %attr(755,root,root) %{_libdir}/libtotem_pg.so.4.*.*
222 %attr(755,root,root) %ghost %{_libdir}/libtotem_pg.so.4
223 %attr(755,root,root) %{_libdir}/libvotequorum.so.4.*.*
224 %attr(755,root,root) %ghost %{_libdir}/libvotequorum.so.4
225 %dir %{_libdir}/lcrso
226
227 %files devel
228 %defattr(644,root,root,755)
229 %attr(755,root,root) %{_libdir}/libcfg.so
230 %attr(755,root,root) %{_libdir}/libconfdb.so
231 %attr(755,root,root) %{_libdir}/libcoroipcc.so
232 %attr(755,root,root) %{_libdir}/libcoroipcs.so
233 %attr(755,root,root) %{_libdir}/libcpg.so
234 %attr(755,root,root) %{_libdir}/libevs.so
235 %attr(755,root,root) %{_libdir}/liblogsys.so
236 %attr(755,root,root) %{_libdir}/libpload.so
237 %attr(755,root,root) %{_libdir}/libsam.so
238 %attr(755,root,root) %{_libdir}/libquorum.so
239 %attr(755,root,root) %{_libdir}/libtotem_pg.so
240 %attr(755,root,root) %{_libdir}/libvotequorum.so
241 %{_includedir}/corosync
242 %{_pkgconfigdir}/corosync.pc
243 %{_pkgconfigdir}/libcfg.pc
244 %{_pkgconfigdir}/libconfdb.pc
245 %{_pkgconfigdir}/libcoroipcc.pc
246 %{_pkgconfigdir}/libcoroipcs.pc
247 %{_pkgconfigdir}/libcpg.pc
248 %{_pkgconfigdir}/libevs.pc
249 %{_pkgconfigdir}/liblogsys.pc
250 %{_pkgconfigdir}/libpload.pc
251 %{_pkgconfigdir}/libquorum.pc
252 %{_pkgconfigdir}/libsam.pc
253 %{_pkgconfigdir}/libtotem_pg.pc
254 %{_pkgconfigdir}/libvotequorum.pc
255 %{_mandir}/man3/confdb_*.3*
256 %{_mandir}/man3/cpg_*.3*
257 %{_mandir}/man3/evs_*.3*
258 %{_mandir}/man3/sam_*.3*
259 %{_mandir}/man3/votequorum_*.3*
260 # should be man7...
261 %{_mandir}/man8/confdb_overview.8*
262 %{_mandir}/man8/coroipc_overview.8*
263 %{_mandir}/man8/corosync_overview.8*
264 %{_mandir}/man8/cpg_overview.8*
265 %{_mandir}/man8/evs_overview.8*
266 %{_mandir}/man8/logsys_overview.8*
267 %{_mandir}/man8/sam_overview.8*
268 %{_mandir}/man8/votequorum_overview.8*
269
270 %files static
271 %defattr(644,root,root,755)
272 %{_libdir}/libcfg.a
273 %{_libdir}/libconfdb.a
274 %{_libdir}/libcoroipcc.a
275 %{_libdir}/libcoroipcs.a
276 %{_libdir}/libcpg.a
277 %{_libdir}/libevs.a
278 %{_libdir}/liblcr.a
279 %{_libdir}/liblogsys.a
280 %{_libdir}/libpload.a
281 %{_libdir}/libsam.a
282 %{_libdir}/libquorum.a
283 %{_libdir}/libtotem_pg.a
284 %{_libdir}/libvotequorum.a
285
286 %if %{with snmp}
287 %files -n mibs-corosync
288 %defattr(644,root,root,755)
289 %{_datadir}/snmp/mibs/COROSYNC-MIB.txt
290 %endif
This page took 0.071048 seconds and 2 git commands to generate.