]> git.pld-linux.org Git - packages/audit.git/blame - audit.spec
- rel 5
[packages/audit.git] / audit.spec
CommitLineData
e5a8c0d8
JB
1#
2# Conditional build:
3%bcond_without pie # auditd as PIE binary
526a1f46 4%bcond_without prelude # prelude audisp plugin
57f09668 5%bcond_without python # don't build python bindings
e5a8c0d8 6#
54697230 7Summary: User space tools for 2.6 kernel auditing
7f0a1e1e 8Summary(pl.UTF-8): Narzędzia przestrzeni użytkownika do audytu jąder 2.6
54697230 9Name: audit
4c11c375 10Version: 1.7.13
1e78f2d9 11Release: 5
ab8f94cb 12License: GPL v2+
54697230
JB
13Group: Daemons
14Source0: http://people.redhat.com/sgrubb/audit/%{name}-%{version}.tar.gz
4c11c375 15# Source0-md5: 967776cbec046043ef02ffefe0e89cb7
de2a21fd
JB
16Source2: %{name}d.init
17Source3: %{name}d.sysconfig
80475ae6 18Patch0: %{name}-install.patch
1e78f2d9 19Patch1: %{name}-pthread.patch
54697230
JB
20URL: http://people.redhat.com/sgrubb/audit/
21BuildRequires: autoconf >= 2.59
10583781 22BuildRequires: automake >= 1:1.9
e5a8c0d8 23%{?with_pie:BuildRequires: gcc >= 5:3.4}
0a348a92 24BuildRequires: gettext-devel >= 0.14.6
10583781 25BuildRequires: glibc-headers >= 6:2.3.6
1e78f2d9 26BuildRequires: heimdal-devel
5e4a6748 27BuildRequires: intltool
10583781 28BuildRequires: libstdc++-devel
526a1f46 29%{?with_prelude:BuildRequires: libprelude-devel}
54697230 30BuildRequires: libtool
80475ae6 31BuildRequires: linux-libc-headers >= 7:2.6.20
792ef7a1 32BuildRequires: openldap-devel
57f09668 33%if %{with python}
84214962 34BuildRequires: python-devel >= 1:2.5
9ee6c1ce 35BuildRequires: rpm-pythonprov
7e695d35 36BuildRequires: swig-python
57f09668 37%endif
38BuildRequires: rpmbuild(macros) >= 1.268
ab8f94cb 39BuildRequires: sed >= 4.0
54697230
JB
40Requires(post,preun): /sbin/chkconfig
41Requires: %{name}-libs = %{version}-%{release}
96102055 42Requires: rc-scripts
526a1f46 43Obsoletes: audit-audispd-plugins
54697230
JB
44BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
45
46%define _sbindir /sbin
ab8f94cb
JB
47# use /lib, because this path is put in /usr/share/.../settings.py
48%define _libexecdir %{_prefix}/lib
54697230
JB
49
50%description
51The audit package contains the user space utilities for storing and
52processing the audit records generate by the audit subsystem in the
53Linux 2.6 kernel.
54
b27e8f95
JR
55%description -l pl.UTF-8
56Ten pakiet zawiera narzędzia przestrzeni użytkownika do przechowywania
57i przetwarzania rekordów audytu generowanych przez podsystem audytu w
58jądrach Linuksa 2.6.
54697230
JB
59
60%package libs
5a56b716 61Summary: Dynamic audit libraries
7f0a1e1e 62Summary(pl.UTF-8): Biblioteki dynamiczne audit
ab8f94cb 63License: LGPL v2.1+
54697230
JB
64Group: Libraries
65
66%description libs
5a56b716 67The audit-libs package contains the dynamic libraries needed for
54697230
JB
68applications to use the audit framework.
69
b27e8f95 70%description libs -l pl.UTF-8
5a56b716 71Ten pakiet zawiera biblioteki dynamiczne potrzebne dla aplikacji
b27e8f95 72używających środowiska audytu.
54697230
JB
73
74%package libs-devel
5a56b716 75Summary: Header files for audit libraries
7f0a1e1e 76Summary(pl.UTF-8): Pliki nagłówkowe bibliotek audit
ab8f94cb 77License: LGPL v2.1+
54697230
JB
78Group: Development/Libraries
79Requires: %{name}-libs = %{version}-%{release}
ab8f94cb 80Requires: linux-libc-headers >= 7:2.6.20
54697230
JB
81
82%description libs-devel
83The audit-libs-devel package contains the header files needed for
84developing applications that need to use the audit framework library.
85
b27e8f95
JR
86%description libs-devel -l pl.UTF-8
87Ten pakiet zawiera pliki nagłówkowe potrzebne do tworzenia aplikacji
88używających biblioteki środowiska audytu.
54697230
JB
89
90%package libs-static
5a56b716 91Summary: Static audit libraries
7f0a1e1e 92Summary(pl.UTF-8): Statyczne biblioteki audit
ab8f94cb 93License: LGPL v2.1+
54697230
JB
94Group: Development/Libraries
95Requires: %{name}-libs-devel = %{version}-%{release}
96
97%description libs-static
5a56b716
JB
98The audit-libs-static package contains the static libraries for
99developing applications that need to use the audit framework.
54697230 100
b27e8f95 101%description libs-static -l pl.UTF-8
5a56b716 102Ten pakiet zawiera statyczne biblioteki do tworzenia aplikacji
b27e8f95 103używających środowiska audytu.
54697230 104
526a1f46
JB
105%package plugin-prelude
106Summary: prelude plugin for audispd
107Summary(pl.UTF-8): Wtyczka prelude dla audispd
108Group: Daemons
109Requires: %{name} = %{version}-%{release}
110
111%description plugin-prelude
112audisp-prelude is a plugin for the audit event dispatcher daemon,
113audispd, that uses libprelude to send IDMEF alerts for possible
114Intrusion Detection events.
115
116%description plugin-prelude -l pl.UTF-8
117audisp-prelude to wtyczka demona audispd przekazującego zdarzenia
118audytowe wykorzystująca libprelude do wysyłania alarmów IDMEF o
119prawdopodobnych zdarzeniach IDS.
120
9ee6c1ce
JB
121%package -n python-audit
122Summary: Python interface to libaudit library
7f0a1e1e 123Summary(pl.UTF-8): Pythonowy interfejs do biblioteki libaudit
ab8f94cb 124License: LGPL v2.1+
9ee6c1ce
JB
125Group: Libraries/Python
126Requires: %{name}-libs = %{version}-%{release}
127
128%description -n python-audit
129Python interface to libaudit library.
130
b27e8f95 131%description -n python-audit -l pl.UTF-8
9ee6c1ce
JB
132Pythonowy interfejs do biblioteki libaudit.
133
ab8f94cb
JB
134%package -n system-config-audit
135Summary: Utility for editing audit configuration
136Summary(pl.UTF-8): Narzędzie do zmiany konfiguracji audytu
137License: GPL v2
138Group: Applications/System
139Requires: %{name} = %{version}-%{release}
df9476f1 140Version: 0.4.8
6fc26f9b 141Requires: python-pygtk-glade >= 2:2.0
ab8f94cb
JB
142Requires: usermode
143#Requires: usermode-gtk ???
144
145%description -n system-config-audit
146An utility for editing audit configuration.
147
148%description -n system-config-audit -l pl.UTF-8
149Narzędzie do zmiany konfiguracji audytu.
150
54697230
JB
151%prep
152%setup -q
eb9b3ab9 153%patch0 -p1
1e78f2d9 154%patch1 -p1
1a8b063a 155
3d5ad897 156%if !%{with python}
b89f6d79 157sed 's#swig/Makefile ##' -i configure.ac
9d3991e5 158sed 's/swig//' -i Makefile.am
57f09668 159%endif
160
ab8f94cb
JB
161sed -i -e 's,/main\.py,/main.pyc,' system-config-audit/src/system-config-audit.in
162
54697230
JB
163%build
164%{__libtoolize}
165%{__aclocal}
166%{__autoconf}
167%{__autoheader}
168%{__automake}
0a348a92 169cd system-config-audit
526a1f46 170%{__libtoolize}
0a348a92
JB
171%{__aclocal}
172%{__autoconf}
173%{__autoheader}
174%{__automake}
175cd ..
cc094a3e 176%configure \
526a1f46 177 --with-apparmor \
1e78f2d9 178 --enable-gssapi-krb5 \
526a1f46 179 %{?with_prelude:--with-prelude}
e5a8c0d8
JB
180# override auditd_{C,LD}FLAGS to avoid -fPIE unsupported by gcc 3.3
181%{__make} \
aac5fae1 182 %{!?with_pie:auditd_CFLAGS="-D_REENTRANT -D_GNU_SOURCE" auditd_LDFLAGS="-Wl,-z,relro"}
54697230 183
bf2e6acc
JB
184# temporarily not included in all
185%{__make} -C auparse
186
54697230
JB
187%install
188rm -rf $RPM_BUILD_ROOT
189install -d $RPM_BUILD_ROOT%{_var}/log/audit
190
191%{__make} install \
192 DESTDIR=$RPM_BUILD_ROOT
193
bf2e6acc
JB
194# temporarily not included in all
195%{__make} -C auparse install \
196 DESTDIR=$RPM_BUILD_ROOT
197
54697230
JB
198install -d $RPM_BUILD_ROOT/%{_lib}
199mv -f $RPM_BUILD_ROOT%{_libdir}/libaudit.so.* $RPM_BUILD_ROOT/%{_lib}
fef538cf 200ln -sf /%{_lib}/$(basename $RPM_BUILD_ROOT/%{_lib}/libaudit.so.*.*.*) \
1a8b063a 201 $RPM_BUILD_ROOT%{_libdir}/libaudit.so
8ba70267 202mv -f $RPM_BUILD_ROOT%{_libdir}/libauparse.so.* $RPM_BUILD_ROOT/%{_lib}
fef538cf 203ln -sf /%{_lib}/$(basename $RPM_BUILD_ROOT/%{_lib}/libauparse.so.*.*.*) \
8ba70267 204 $RPM_BUILD_ROOT%{_libdir}/libauparse.so
54697230
JB
205
206# We manually install this since Makefile doesn't
207install -d $RPM_BUILD_ROOT%{_includedir}
208install lib/libaudit.h $RPM_BUILD_ROOT%{_includedir}
209
de2a21fd
JB
210install %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/auditd
211install %{SOURCE3} $RPM_BUILD_ROOT/etc/sysconfig/auditd
212
57f09668 213%if %{with python}
eb9b3ab9 214%py_comp $RPM_BUILD_ROOT%{py_sitescriptdir}
8e99bb72 215%py_ocomp $RPM_BUILD_ROOT%{py_sitescriptdir}
eb9b3ab9 216rm -f $RPM_BUILD_ROOT%{py_sitescriptdir}/*.py
8e99bb72 217rm -f $RPM_BUILD_ROOT%{py_sitedir}/*.{la,a}
ab8f94cb
JB
218
219%py_postclean $RPM_BUILD_ROOT%{_datadir}/system-config-audit
220%find_lang system-config-audit
57f09668 221%endif
9ee6c1ce 222
54697230
JB
223%clean
224rm -rf $RPM_BUILD_ROOT
225
226%post libs -p /sbin/ldconfig
227%postun libs -p /sbin/ldconfig
228
229%post
230/sbin/chkconfig --add auditd
2a6b8c9c 231%service auditd restart "audit daemon"
54697230
JB
232
233%preun
234if [ "$1" = "0" ]; then
2a6b8c9c 235 %service auditd stop
54697230
JB
236 /sbin/chkconfig --del auditd
237fi
238
239%files
240%defattr(644,root,root,755)
bd0730be 241%doc AUTHORS ChangeLog README THANKS TODO
2bfdaebd 242%attr(750,root,root) %{_bindir}/aulast
08b12da9
JB
243%attr(750,root,root) %{_bindir}/aulastlog
244%attr(750,root,root) %{_bindir}/ausyscall
80475ae6 245%attr(750,root,root) %{_sbindir}/audispd
54697230
JB
246%attr(750,root,root) %{_sbindir}/auditctl
247%attr(750,root,root) %{_sbindir}/auditd
e5a8c0d8 248%attr(750,root,root) %{_sbindir}/aureport
54697230
JB
249%attr(750,root,root) %{_sbindir}/ausearch
250%attr(750,root,root) %{_sbindir}/autrace
08b12da9 251%attr(755,root,root) %{_sbindir}/audisp-remote
2f4ad87a 252%attr(755,root,root) %{_sbindir}/audispd-zos-remote
0a348a92
JB
253%dir %{_sysconfdir}/audisp
254%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/audisp/audispd.conf
08b12da9 255%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/audisp/audisp-remote.conf
2f4ad87a 256%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/audisp/zos-remote.conf
0a348a92
JB
257%dir %{_sysconfdir}/audisp/plugins.d
258%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/audisp/plugins.d/af_unix.conf
08b12da9 259%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/audisp/plugins.d/au-remote.conf
792ef7a1 260%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/audisp/plugins.d/audispd-zos-remote.conf
0a348a92 261%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/audisp/plugins.d/syslog.conf
7630c8d3
JB
262%dir %{_sysconfdir}/audit
263%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/audit/auditd.conf
264%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/audit/audit.rules
80475ae6 265%attr(754,root,root) /etc/rc.d/init.d/auditd
f6ae0a53 266%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/auditd
54697230 267%attr(750,root,root) %dir %{_var}/log/audit
0a348a92 268%{_mandir}/man5/audispd.conf.5*
08b12da9 269%{_mandir}/man5/audisp-remote.conf.5*
80475ae6 270%{_mandir}/man5/auditd.conf.5*
526a1f46 271%{_mandir}/man5/ausearch-expression.5*
2f4ad87a 272%{_mandir}/man5/zos-remote.conf.5*
08b12da9 273%{_mandir}/man8/audisp-remote.8*
526a1f46
JB
274%{_mandir}/man8/audispd-zos-remote.8*
275%{_mandir}/man8/audispd.8*
276%{_mandir}/man8/auditctl.8*
277%{_mandir}/man8/auditd.8*
2bfdaebd 278%{_mandir}/man8/aulast.8*
526a1f46
JB
279%{_mandir}/man8/aulastlog.8*
280%{_mandir}/man8/aureport.8*
281%{_mandir}/man8/ausearch.8*
08b12da9 282%{_mandir}/man8/ausyscall.8*
526a1f46 283%{_mandir}/man8/autrace.8*
54697230
JB
284
285%files libs
286%defattr(644,root,root,755)
287%attr(755,root,root) /%{_lib}/libaudit.so.*.*.*
fef538cf 288%attr(755,root,root) %ghost /%{_lib}/libaudit.so.0
8ba70267 289%attr(755,root,root) /%{_lib}/libauparse.so.*.*.*
fef538cf 290%attr(755,root,root) %ghost /%{_lib}/libauparse.so.0
7630c8d3 291%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/libaudit.conf
54697230
JB
292
293%files libs-devel
294%defattr(644,root,root,755)
295%attr(755,root,root) %{_libdir}/libaudit.so
8ba70267 296%attr(755,root,root) %{_libdir}/libauparse.so
54697230 297%{_libdir}/libaudit.la
8ba70267 298%{_libdir}/libauparse.la
6d3a6f20 299%{_includedir}/auparse*.h
54697230 300%{_includedir}/libaudit.h
526a1f46
JB
301%{_mandir}/man3/audit_*.3*
302%{_mandir}/man3/auparse_*.3*
303%{_mandir}/man3/ausearch_*.3*
304%{_mandir}/man3/get_auditfail_action.3*
305%{_mandir}/man3/set_aumessage_mode.3*
54697230
JB
306
307%files libs-static
308%defattr(644,root,root,755)
309%{_libdir}/libaudit.a
8ba70267 310%{_libdir}/libauparse.a
9ee6c1ce 311
526a1f46
JB
312%if %{with prelude}
313%files plugin-prelude
314%defattr(644,root,root,755)
315%attr(755,root,root) %{_sbindir}/audisp-prelude
316%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/audisp/audisp-prelude.conf
317%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/audisp/plugins.d/au-prelude.conf
318%{_mandir}/man5/audisp-prelude.conf.5*
319%{_mandir}/man8/audisp-prelude.8*
320%endif
321
57f09668 322%if %{with python}
9ee6c1ce
JB
323%files -n python-audit
324%defattr(644,root,root,755)
325%attr(755,root,root) %{py_sitedir}/_audit.so
84214962 326%attr(755,root,root) %{py_sitedir}/auparse.so
4c11c375 327%{py_sitedir}/audit.py[co]
ab8f94cb
JB
328
329%files -n system-config-audit -f system-config-audit.lang
330%defattr(644,root,root,755)
331%attr(755,root,root) %{_bindir}/system-config-audit
332%attr(755,root,root) %{_libexecdir}/system-config-audit-server
333%{_datadir}/system-config-audit
334%{_desktopdir}/system-config-audit.desktop
57f09668 335%endif
This page took 0.125095 seconds and 4 git commands to generate.