1 %global alphatag @alphatag@
2 %global numcomm @numcomm@
6 # Invoke "rpmbuild --without <feature>" or "rpmbuild --with <feature>"
7 # to disable or enable specific features
10 %bcond_with monitoring
18 Summary: The Corosync Cluster Engine and Application Programming Interfaces
20 Release: 1%{?numcomm:.%{numcomm}}%{?alphatag:.%{alphatag}}%{?dirty:.%{dirty}}%{?dist}
22 Group: System Environment
/Base
23 URL: http
://ftp.corosync.org
24 Source0: ftp
://ftp
:user@ftp.corosync.org
/downloads
/%{name}-%{version}/%{name}-%{version}%{?numcomm:.%{numcomm}}%{?alphatag:-%{alphatag}}%{?dirty:-%{dirty}}.tar.gz
27 Requires: corosynclib
= %{version}-%{release}
28 Requires(pre
): /usr
/sbin
/useradd
29 Requires(post
): /sbin
/chkconfig
30 Requires(preun
): /sbin
/chkconfig
31 Conflicts: openais
<= 0.89, openais
-devel
<= 0.89
36 %{?_with_buildtrunk: %define buildtrunk 1}
38 BuildRequires
: libqb
-devel
40 BuildRequires
: autoconf automake
43 BuildRequires
: nss
-devel
46 BuildRequires
: libibverbs
-devel librdmacm
-devel
49 BuildRequires
: net
-snmp
-devel
52 BuildRequires
: dbus
-devel
55 BuildRequires
: systemd
-units
61 BuildRoot: %
(mktemp
-ud
%{_tmppath}/%{name}-%{version}-%{release}-XXXXXX
)
64 %setup -q
-n
%{name}-%{version}%{?numcomm:.%{numcomm}}%{?alphatag:-%{alphatag}}%{?dirty:-%{dirty}}
72 export ibverbs_CFLAGS
=-I
/usr
/include
/infiniband \
73 export ibverbs_LIBS
=-libverbs \
74 export rdmacm_CFLAGS
=-I
/usr
/include
/rdma \
75 export rdmacm_LIBS
=-lrdmacm \
83 %if %{with testagents}
89 %if %{with monitoring}
104 --with
-initddir
=%{_initrddir}
111 make install DESTDIR
=%{buildroot}
114 mkdir -p
-m
0700 %{buildroot}/%{_sysconfdir}/dbus
-1/system.d
115 install -m
644 %{_builddir}/%{name}-%{version}/conf/corosync-signals.conf %{buildroot}/%{_sysconfdir}/dbus
-1/system.d
/corosync
-signals.conf
120 rm -f
%{buildroot}%{_libdir}/*.a
121 # drop docs and html docs for now
122 rm -rf
%{buildroot}%{_docdir}/*
128 This package contains the Corosync Cluster Engine Executive
, several default
129 APIs and libraries
, default configuration files
, and an init script.
132 if [ $
1 -eq
1 ]; then
133 /sbin
/chkconfig
--add corosync ||
:
137 if [ $
1 -eq
0 ]; then
138 /sbin
/service corosync stop
&>/dev
/null ||
:
139 /sbin
/chkconfig
--del corosync ||
:
143 %defattr(-,root
,root
,-)
144 %doc LICENSE SECURITY
146 %{_sbindir}/corosync
-keygen
147 %{_sbindir}/corosync
-cmapctl
148 %{_sbindir}/corosync
-cfgtool
149 %{_sbindir}/corosync
-fplay
150 %{_sbindir}/corosync
-pload
151 %{_sbindir}/corosync
-cpgtool
152 %{_sbindir}/corosync
-quorumtool
153 %{_sbindir}/corosync
-notifyd
154 %{_bindir}/corosync
-blackbox
156 %{_bindir}/corosync
-xmlproc
158 %dir %{_sysconfdir}/corosync
159 %dir %{_sysconfdir}/corosync
/uidgid.d
160 %config(noreplace
) %{_sysconfdir}/corosync
/corosync.conf.example
161 %config(noreplace
) %{_sysconfdir}/corosync
/corosync.conf.example.udpu
163 %{_sysconfdir}/dbus
-1/system.d
/corosync
-signals.conf
166 %{_datadir}/snmp
/mibs
/COROSYNC
-MIB.txt
169 %{_unitdir}/corosync.service
170 %{_unitdir}/corosync
-notifyd.service
172 %{_initrddir}/corosync
173 %{_initrddir}/corosync
-notifyd
175 %dir %{_localstatedir}/lib
/corosync
176 %dir %{_localstatedir}/log
/cluster
177 %{_mandir}/man8
/corosync_overview
.8*
178 %{_mandir}/man8
/corosync
.8*
179 %{_mandir}/man8
/corosync
-blackbox
.8*
180 %{_mandir}/man8
/corosync
-cmapctl
.8*
181 %{_mandir}/man8
/corosync
-keygen
.8*
182 %{_mandir}/man8
/corosync
-cfgtool
.8*
183 %{_mandir}/man8
/corosync
-cpgtool
.8*
184 %{_mandir}/man8
/corosync
-fplay
.8*
185 %{_mandir}/man8
/corosync
-pload
.8*
186 %{_mandir}/man8
/corosync
-notifyd
.8*
187 %{_mandir}/man8
/corosync
-quorumtool
.8*
188 %{_mandir}/man5
/corosync.conf
.5*
191 # optional testagent rpm
193 %if %{with testagents}
195 %package -n corosync
-testagents
196 Summary: The Corosync Cluster Engine Test Agents
197 Group: Development
/Libraries
198 Requires: %{name} = %{version}-%{release}
200 %description -n corosync
-testagents
201 This package contains corosync
test agents.
203 %files -n corosync
-testagents
204 %defattr(755,root
,root
,-)
205 %{_datadir}/corosync
/tests
/mem_leak_test.sh
206 %{_datadir}/corosync
/tests
/net_breaker.sh
207 %{_datadir}/corosync
/tests
/cmap
-dispatch
-deadlock.sh
208 %{_datadir}/corosync
/tests
/shm_leak_audit.sh
209 %{_bindir}/cpg_test_agent
210 %{_bindir}/sam_test_agent
211 %{_bindir}/votequorum_test_agent
217 %package -n corosynclib
218 Summary: The Corosync Cluster Engine Libraries
219 Group: System Environment
/Libraries
220 Requires: %{name} = %{version}-%{release}
222 %description -n corosynclib
223 This package contains corosync libraries.
225 %files -n corosynclib
226 %defattr(-,root
,root
,-)
228 %{_libdir}/libcfg.so.
*
229 %{_libdir}/libcpg.so.
*
230 %{_libdir}/libcmap.so.
*
231 %{_libdir}/libevs.so.
*
232 %{_libdir}/libtotem_pg.so.
*
233 %{_libdir}/libquorum.so.
*
234 %{_libdir}/libvotequorum.so.
*
235 %{_libdir}/libpload.so.
*
236 %{_libdir}/libsam.so.
*
238 %post -n corosynclib
-p
/sbin
/ldconfig
240 %postun -n corosynclib
-p
/sbin
/ldconfig
242 %package -n corosynclib
-devel
243 Summary: The Corosync Cluster Engine Development Kit
244 Group: Development
/Libraries
245 Requires: corosynclib
= %{version}-%{release}
247 Provides: corosync
-devel
= %{version}
248 Obsoletes
: corosync
-devel
< 0.92-7
250 %description -n corosynclib
-devel
251 This package contains include files and man pages used to develop using
252 The Corosync Cluster Engine APIs.
254 %files -n corosynclib
-devel
255 %defattr(-,root
,root
,-)
257 %dir %{_includedir}/corosync
/
258 %{_includedir}/corosync
/cs_config.h
259 %{_includedir}/corosync
/corodefs.h
260 %{_includedir}/corosync
/cfg.h
261 %{_includedir}/corosync
/cmap.h
262 %{_includedir}/corosync
/corotypes.h
263 %{_includedir}/corosync
/cpg.h
264 %{_includedir}/corosync
/evs.h
265 %{_includedir}/corosync
/hdb.h
266 %{_includedir}/corosync
/list.h
267 %{_includedir}/corosync
/mar_gen.h
268 %{_includedir}/corosync
/sam.h
269 %{_includedir}/corosync
/swab.h
270 %{_includedir}/corosync
/quorum.h
271 %{_includedir}/corosync
/votequorum.h
272 %dir %{_includedir}/corosync
/totem
/
273 %{_includedir}/corosync
/totem
/totem.h
274 %{_includedir}/corosync
/totem
/totemip.h
275 %{_includedir}/corosync
/totem
/totempg.h
276 %dir %{_includedir}/corosync
/engine
277 %{_includedir}/corosync
/engine
/quorum.h
280 %{_libdir}/libcmap.so
282 %{_libdir}/libtotem_pg.so
283 %{_libdir}/libquorum.so
284 %{_libdir}/libvotequorum.so
285 %{_libdir}/libpload.so
287 %{_libdir}/pkgconfig
/*.pc
288 %{_mandir}/man3
/cpg_
*3*
289 %{_mandir}/man3
/evs_
*3*
290 %{_mandir}/man3
/quorum_
*3*
291 %{_mandir}/man3
/votequorum_
*3*
292 %{_mandir}/man3
/sam_
*3*
293 %{_mandir}/man8
/cpg_overview
.8*
294 %{_mandir}/man8
/evs_overview
.8*
295 %{_mandir}/man8
/votequorum_overview
.8*
296 %{_mandir}/man8
/sam_overview
.8*
299 * @date@ Autotools generated version
<nobody@nowhere.org
> - @version@
-1-@numcomm@.@alphatag@.@dirty@
300 - Autotools generated version