]> git.pld-linux.org Git - packages/libprelude.git/blame - libprelude.spec
- release 10 (by relup.sh)
[packages/libprelude.git] / libprelude.spec
CommitLineData
26c3f184 1#
2# Conditional build:
38968c27
JB
3%bcond_without lua # Lua (5.1) bindings
4%bcond_without perl # Perl bindings
5%bcond_without python # Python bindings (required by prewikka)
9bae6390 6%bcond_without ruby # Ruby bindings
26c3f184 7#
f1347e6d 8%include /usr/lib/rpm/macros.perl
6c16cb84 9Summary: The Prelude library
6a1accbc 10Summary(pl.UTF-8): Biblioteka Prelude
f1347e6d 11Name: libprelude
4ddd3a0d 12Version: 1.0.1
4ebfd4d5 13Release: 10
d0949742 14License: GPL v2 or commercial
f1347e6d 15Group: Libraries
4ddd3a0d
MK
16# https://www.prelude-ids.org/projects/prelude/files
17Source0: https://www.prelude-ids.org/attachments/download/241/%{name}-%{version}.tar.gz
18# Source0-md5: dce1ea9f82cf436830567894e7ee622f
30591219 19Patch0: %{name}-libtool.patch
38968c27 20Patch1: %{name}-ruby.patch
4ddd3a0d
MK
21Patch2: %{name}-gnutls.patch
22Patch3: %{name}-gets.patch
23Patch4: %{name}-python.patch
7df98bd9 24Patch5: format-security.patch
24d829c8 25URL: http://www.prelude-ids.com/
d0949742
JB
26BuildRequires: autoconf >= 2.59
27BuildRequires: automake
f1347e6d
AM
28BuildRequires: bison
29BuildRequires: flex
9320b06b 30BuildRequires: gnutls-devel >= 1.0.17
d0949742
JB
31BuildRequires: gtk-doc >= 1.0
32BuildRequires: libgcrypt-devel >= 1.1.94
38968c27 33BuildRequires: libltdl-devel >= 2:2.0
eb068d3a 34BuildRequires: libstdc++-devel
38968c27
JB
35BuildRequires: libtool >= 2:2.0
36%{?with_lua:BuildRequires: lua51-devel >= 5.1}
9320b06b 37%{?with_perl:BuildRequires: perl-devel}
d0949742 38%{?with_python:BuildRequires: python-devel >= 1:2.5}
f1347e6d 39BuildRequires: rpm-perlprov
d0949742
JB
40BuildRequires: rpm-pythonprov
41BuildRequires: rpmbuild(macros) >= 1.219
9bae6390 42%{?with_ruby:BuildRequires: ruby-devel >= 1.9}
38968c27 43BuildRequires: sed >= 4.0
30591219 44%{?with_perl:BuildRequires: swig-perl}
38968c27
JB
45%{?with_python:BuildRequires: swig-python}
46%{?with_ruby:BuildRequires: swig-ruby}
d0949742 47Requires: %{name}-libs = %{version}-%{release}
f1347e6d
AM
48BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
49
50%description
6c16cb84 51The Prelude library is a collection of generic functions providing
f1347e6d
AM
52communication between the Prelude Hybrid IDS suite components. It
53provides a convenient interface for sending alerts to Prelude Manager
54with transparent SSL, failover and replication support, asynchronous
55events and timer interfaces, an abstracted configuration API (hooking
56at the commandline, the configuration line, or wide configuration,
57available from the Manager), and a generic plugin API. It allows you
58to easily turn your favorite security program into a Prelude sensor.
59
5db7d1dc
JR
60%description -l pl.UTF-8
61Biblioteka Prelude to zbiór ogólnych funkcji zapewniających
62komunikację pomiędzy komponentami zestawu Prelude Hybrid IDS.
63Dostarcza wygodny interfejs do wysyłania alarmów do zarządcy Prelude z
64przezroczystą obsługę SSL, failover i replikacji, interfejsy do
65zdarzeń asynchronicznych i zegarów, abstrakcyjne API konfiguracyjne
81042991 66(obsługujące linię poleceń, linię konfiguracji i konfigurację dostępną
67z zarządcy) oraz ogólne API wtyczek. Pozwala łatwo zamienić ulubiony
68program związany z bezpieczeństwem na czujnik Prelude.
7758741a 69
f1347e6d 70%package libs
6c16cb84 71Summary: The Prelude library
6a1accbc 72Summary(pl.UTF-8): Biblioteka Prelude
7758741a 73Group: Libraries
d0949742
JB
74Requires: gnutls >= 1.0.17
75Requires: libgcrypt >= 1.1.94
f1347e6d
AM
76
77%description libs
6c16cb84 78The Prelude library.
f1347e6d 79
5db7d1dc 80%description libs -l pl.UTF-8
7758741a
JB
81Biblioteka Prelude.
82
f1347e6d 83%package devel
7758741a 84Summary: Header files and development documentation for libprelude
6a1accbc 85Summary(pl.UTF-8): Pliki nagłówkowe i dokumentacja programistyczna dla libprelude
f1347e6d 86Group: Development/Libraries
7758741a 87Requires: %{name}-libs = %{version}-%{release}
d0949742
JB
88Requires: gnutls-devel >= 1.0.17
89Requires: libgcrypt-devel >= 1.1.94
90Requires: libltdl-devel
f1347e6d
AM
91
92%description devel
7758741a
JB
93Header files and development documentation for libprelude.
94
5db7d1dc
JR
95%description devel -l pl.UTF-8
96Pliki nagłówkowe i dokumentacja programistyczna dla libprelude.
f1347e6d
AM
97
98%package static
99Summary: Static libprelude library
6a1accbc 100Summary(pl.UTF-8): Statyczna biblioteka libprelude
f1347e6d 101Group: Development/Libraries
7758741a 102Requires: %{name}-devel = %{version}-%{release}
f1347e6d
AM
103
104%description static
105Static libprelude library.
106
5db7d1dc 107%description static -l pl.UTF-8
7758741a
JB
108Statyczna biblioteka libprelude.
109
eb068d3a
JB
110%package c++
111Summary: libpreludecpp - C++ binding for libprelude
112Summary(pl.UTF-8): libpreludecpp - wiązanie C++ do libprelude
113Group: Libraries
114Requires: %{name}-libs = %{version}-%{release}
115
116%description c++
117libpreludecpp - C++ binding for libprelude.
118
119%description c++ -l pl.UTF-8
120libpreludecpp - wiązanie C++ do libprelude.
121
122%package c++-devel
123Summary: Header file for libpreludecpp library
124Summary(pl.UTF-8): Pliki nagłówkowe biblioteki libpreludecpp
125Group: Development/Libraries
126Requires: %{name}-c++ = %{version}-%{release}
127Requires: %{name}-devel = %{version}-%{release}
128Requires: libstdc++-devel
129
130%description c++-devel
131Header file for libpreludecpp library - C++ binding for libprelude.
132
133%description c++-devel -l pl.UTF-8
134Pliki nagłówkowe biblioteki libpreludecpp - wiązań C++ do libprelude.
135
136%package c++-static
137Summary: Static libpreludecpp library
138Summary(pl.UTF-8): Statyczna biblioteka libpreludecpp
139Group: Development/Libraries
140Requires: %{name}-c++-devel = %{version}-%{release}
141
142%description c++-static
143Static libpreludecpp library.
144
145%description c++-static -l pl.UTF-8
146Statyczna biblioteka libpreludecpp.
147
38968c27 148%package -n lua-prelude
9bae6390
JB
149Summary: PreludeEasy - libprelude Lua bindings
150Summary(pl.UTF-8): PreludeEasy - dowiązania języka Lua do libprelude
38968c27 151Group: Development/Languages
eb068d3a 152Requires: %{name}-c++ = %{version}-%{release}
38968c27
JB
153
154%description -n lua-prelude
9bae6390 155PreludeEasy - libprelude Lua bindings.
38968c27
JB
156
157%description -n lua-prelude -l pl.UTF-8
9bae6390 158PreludeEasy - dowiązania języka Lua do libprelude.
38968c27 159
f1347e6d 160%package -n perl-libprelude
eb068d3a
JB
161Summary: Prelude Perl module - low-level Perl binding for libprelude
162Summary(pl.UTF-8): Moduł Perla Prelude - niskopoziomowe wiązanie Perla do libprelude
f1347e6d 163Group: Development/Languages/Perl
d0949742 164Requires: %{name}-libs = %{version}-%{release}
f1347e6d
AM
165
166%description -n perl-libprelude
eb068d3a 167Prelude Perl module - low-level Perl binding for libprelude.
7758741a 168
5db7d1dc 169%description -n perl-libprelude -l pl.UTF-8
eb068d3a
JB
170Moduł Perla Prelude - niskopoziomowe wiązanie Perla do libprelude.
171
172%package -n perl-PreludeEasy
173Summary: PreludeEasy - high-level Perl binding for libprelude
174Summary(pl.UTF-8): PreludeEasy - wysokopoziomowe wiązanie Perla do libprelude
175Group: Development/Languages/Perl
176Requires: %{name}-c++ = %{version}-%{release}
177
178%description -n perl-PreludeEasy
179PreludeEasy - high-level Perl binding for libprelude.
180
181%description -n perl-PreludeEasy -l pl.UTF-8
182PreludeEasy - wysokopoziomowe wiązanie Perla do libprelude.
f1347e6d
AM
183
184%package -n python-libprelude
eb068d3a
JB
185Summary: Low-level Python binding for libprelude
186Summary(pl.UTF-8): Niskopoziomowe wiązanie Pythona do libprelude
f1347e6d 187Group: Development/Languages/Python
d0949742 188Requires: %{name}-libs = %{version}-%{release}
f1347e6d
AM
189
190%description -n python-libprelude
eb068d3a 191Low-level Python binding for libprelude.
7758741a 192
5db7d1dc 193%description -n python-libprelude -l pl.UTF-8
eb068d3a
JB
194Niskopoziomowe wiązanie Pythona do libprelude.
195
196%package -n python-PreludeEasy
197Summary: PreludeEasy - high-level Python binding for libprelude
198Summary(pl.UTF-8): PreludeEasy - wysokopoziomowe wiązanie Pythona do libprelude
199Group: Development/Languages/Python
200Requires: %{name}-c++ = %{version}-%{release}
201
202%description -n python-PreludeEasy
203PreludeEasy - high-level Python binding for libprelude.
204
205%description -n python-PreludeEasy -l pl.UTF-8
206PreludeEasy - wysokopoziomowe wiązanie Pythona do libprelude.
f1347e6d 207
9bae6390
JB
208%package -n ruby-prelude
209Summary: PreludeEasy - libprelude Ruby bindings
210Summary(pl.UTF-8): PreludeEasy - dowiązania języka Ruby do libprelude
211Group: Development/Languages
eb068d3a 212Requires: %{name}-c++ = %{version}-%{release}
9bae6390
JB
213
214%description -n ruby-prelude
215PreludeEasy - libprelude Ruby bindings.
216
217%description -n ruby-prelude -l pl.UTF-8
218PreludeEasy - dowiązania języka Ruby do libprelude.
219
f1347e6d 220%prep
6de9ce54 221%setup -q
30591219 222%patch0 -p1
38968c27
JB
223
224%if %{with python}
225# regenerate with fresh swig for gcc 4.6+
226%{__rm} bindings/python/{_PreludeEasy.cxx,PreludeEasy.py}
227%endif
228%if %{with ruby}
229# same for ruby 1.9
38968c27 230%{__rm} bindings/ruby/PreludeEasy.cxx
9bae6390 231%patch1 -p1
38968c27 232%endif
e2f29a7c
JR
233%if %{with perl}
234# regenerate with fresh swig for perl 5.20
235%{__rm} bindings/low-level/perl/Prelude.c
236%endif
38968c27 237
4ddd3a0d
MK
238%patch2 -p1
239%patch3 -p1
240%patch4 -p1
7df98bd9 241%patch5 -p1
4ddd3a0d 242
38968c27 243sed -i -e 's/lua >= 5.1/lua51 >= 5.1/' configure.in
f1347e6d
AM
244
245%build
d0949742
JB
246%{__libtoolize}
247%{__aclocal} -I m4 -I libmissing/m4
248%{__autoconf}
249%{__autoheader}
250%{__automake}
f1347e6d 251%configure \
62e43182 252 am_cv_ruby_rbexecdir=%{ruby_vendorarchdir} \
f1347e6d 253 --enable-gtk-doc \
38968c27
JB
254 --enable-static \
255 --with%{!?with_lua:out}-lua \
f4f6dcd7 256 --with%{!?with_perl:out}-perl \
257 --with%{!?with_python:out}-python \
d0949742
JB
258 --with-html-dir=%{_gtkdocdir}/libprelude \
259 --with-perl-installdirs=vendor
6de9ce54 260
f1347e6d
AM
261%{__make}
262
62e43182
JR
263cd bindings/perl
264%{__make} clean
265%{__perl} Makefile.PL \
266 INSTALLDIRS=vendor \
267%{__make}
268
f1347e6d
AM
269%install
270rm -rf $RPM_BUILD_ROOT
271
272%{__make} install \
273 DESTDIR=$RPM_BUILD_ROOT
274
62e43182
JR
275%{__make} -C bindings/perl install \
276 DESTDIR=$RPM_BUILD_ROOT
277
9bae6390
JB
278%if %{with lua}
279%{__rm} $RPM_BUILD_ROOT%{_libdir}/PreludeEasy.{la,a}
280%endif
9320b06b 281%if %{with python}
f1347e6d
AM
282%py_ocomp $RPM_BUILD_ROOT%{py_sitedir}
283%py_comp $RPM_BUILD_ROOT%{py_sitedir}
d0949742 284%py_postclean
9320b06b 285%endif
9bae6390 286%if %{with ruby}
62e43182 287%{__rm} $RPM_BUILD_ROOT%{ruby_vendorarchdir}/PreludeEasy.{la,a}
38968c27 288%endif
f1347e6d
AM
289
290%clean
291rm -rf $RPM_BUILD_ROOT
292
6c16cb84 293%post libs -p /sbin/ldconfig
7758741a 294%postun libs -p /sbin/ldconfig
f1347e6d 295
eb068d3a
JB
296%post c++ -p /sbin/ldconfig
297%postun c++ -p /sbin/ldconfig
298
f1347e6d
AM
299%files
300%defattr(644,root,root,755)
d0949742
JB
301%doc AUTHORS ChangeLog LICENSE.README NEWS README
302%attr(755,root,root) %{_bindir}/prelude-adduser
303%attr(755,root,root) %{_bindir}/prelude-admin
f1347e6d
AM
304%dir %{_sysconfdir}/prelude
305%dir %{_sysconfdir}/prelude/default
38968c27
JB
306%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/prelude/default/client.conf
307%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/prelude/default/global.conf
308%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/prelude/default/idmef-client.conf
309%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/prelude/default/tls.conf
f1347e6d 310%dir %{_sysconfdir}/prelude/profile
d0949742 311%{_mandir}/man1/prelude-admin.1*
f1347e6d
AM
312
313%files libs
314%defattr(644,root,root,755)
d0949742
JB
315%attr(755,root,root) %{_libdir}/libprelude.so.*.*.*
316%attr(755,root,root) %ghost %{_libdir}/libprelude.so.2
f1347e6d
AM
317
318%files devel
319%defattr(644,root,root,755)
320%attr(755,root,root) %{_bindir}/libprelude-config
d0949742
JB
321%attr(755,root,root) %{_libdir}/libprelude.so
322%{_libdir}/libprelude.la
eb068d3a
JB
323%dir %{_includedir}/libprelude
324%{_includedir}/libprelude/*.h
d0949742 325%{_aclocaldir}/libprelude.m4
f1347e6d 326%{_gtkdocdir}/libprelude
81042991 327%{_pkgconfigdir}/libprelude.pc
f1347e6d
AM
328
329%files static
330%defattr(644,root,root,755)
d0949742 331%{_libdir}/libprelude.a
eb068d3a
JB
332
333%files c++
334%defattr(644,root,root,755)
335%attr(755,root,root) %{_libdir}/libpreludecpp.so.*.*.*
336%attr(755,root,root) %ghost %{_libdir}/libpreludecpp.so.0
337
338%files c++-devel
339%defattr(644,root,root,755)
340%attr(755,root,root) %{_libdir}/libpreludecpp.so
341%{_libdir}/libpreludecpp.la
342%{_includedir}/libprelude/idmef*.hxx
343%{_includedir}/libprelude/prelude*.hxx
344
345%files c++-static
346%defattr(644,root,root,755)
30591219 347%{_libdir}/libpreludecpp.a
f1347e6d 348
38968c27
JB
349%if %{with lua}
350%files -n lua-prelude
351%defattr(644,root,root,755)
352%attr(755,root,root) %{_libdir}/PreludeEasy.so
353%endif
354
9320b06b 355%if %{with perl}
f1347e6d
AM
356%files -n perl-libprelude
357%defattr(644,root,root,755)
f1347e6d 358%{perl_vendorarch}/Prelude.pm
d0949742 359%dir %{perl_vendorarch}/auto/Prelude
d0949742 360%attr(755,root,root) %{perl_vendorarch}/auto/Prelude/Prelude.so
eb068d3a
JB
361
362%files -n perl-PreludeEasy
363%defattr(644,root,root,755)
364%{perl_vendorarch}/PreludeEasy.pm
38968c27 365%dir %{perl_vendorarch}/auto/PreludeEasy
38968c27 366%attr(755,root,root) %{perl_vendorarch}/auto/PreludeEasy/PreludeEasy.so
9320b06b 367%endif
f1347e6d 368
9320b06b 369%if %{with python}
f1347e6d
AM
370%files -n python-libprelude
371%defattr(644,root,root,755)
d0949742
JB
372%attr(755,root,root) %{py_sitedir}/_prelude.so
373%{py_sitedir}/prelude.py[co]
eb068d3a
JB
374%{py_sitedir}/prelude-%{version}-py*.egg-info
375
376%files -n python-PreludeEasy
377%defattr(644,root,root,755)
378%attr(755,root,root) %{py_sitedir}/_PreludeEasy.so
30591219 379%{py_sitedir}/PreludeEasy.py[co]
eb068d3a 380%{py_sitedir}/PreludeEasy-%{version}-py*.egg-info
9320b06b 381%endif
9bae6390
JB
382
383%if %{with ruby}
384%files -n ruby-prelude
385%defattr(644,root,root,755)
62e43182 386%attr(755,root,root) %{ruby_vendorarchdir}/PreludeEasy.so
9bae6390 387%endif
This page took 0.161564 seconds and 4 git commands to generate.