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