]> git.pld-linux.org Git - packages/audit.git/blob - audit.spec
- no need for -fPIC with gcc < 3.4 (no -pie support)
[packages/audit.git] / audit.spec
1 Summary:        User space tools for 2.6 kernel auditing
2 Summary(pl):    Narzêdzia przestrzeni u¿ytkownika do audytu j±der 2.6
3 Name:           audit
4 Version:        1.0.3
5 Release:        1.1
6 License:        GPL
7 Group:          Daemons
8 Source0:        http://people.redhat.com/sgrubb/audit/%{name}-%{version}.tar.gz
9 # Source0-md5:  950daad97adfa3134289aa5b4e885f8f
10 # http://people.redhat.com/sgrubb/audit/audit.h
11 Source1:        audit.h
12 Source2:        %{name}d.init
13 Source3:        %{name}d.sysconfig
14 URL:            http://people.redhat.com/sgrubb/audit/
15 BuildRequires:  autoconf >= 2.59
16 BuildRequires:  automake >= 1.9
17 BuildRequires:  libtool
18 BuildRequires:  linux-libc-headers >= 2.6.11
19 PreReq:         rc-scripts
20 Requires(post,preun):   /sbin/chkconfig
21 Requires:       %{name}-libs = %{version}-%{release}
22 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
23
24 %define         _sbindir        /sbin
25
26 %description
27 The audit package contains the user space utilities for storing and
28 processing the audit records generate by the audit subsystem in the
29 Linux 2.6 kernel.
30
31 %description -l pl
32 Ten pakiet zawiera narzêdzia przestrzeni u¿ytkownika do przechowywania
33 i przetwarzania rekordów audytu generowanych przez podsystem audytu w
34 j±drach Linuksa 2.6.
35
36 %package libs
37 Summary:        Dynamic libaudit library
38 Summary(pl):    Biblioteka dynamiczna libaudit
39 License:        LGPL
40 Group:          Libraries
41
42 %description libs
43 The audit-libs package contains the dynamic library needed for
44 applications to use the audit framework.
45
46 %description libs -l pl
47 Ten pakiet zawiera bibliotekê dynamiczn± potrzebn± dla aplikacji
48 u¿ywaj±cych ¶rodowiska audytu.
49
50 %package libs-devel
51 Summary:        Header files for libaudit library
52 Summary(pl):    Pliki nag³ówkowe biblioteki libaudio
53 License:        LGPL
54 Group:          Development/Libraries
55 Requires:       %{name}-libs = %{version}-%{release}
56 Requires:       linux-libc-headers >= 7:2.6.12.0-4
57
58 %description libs-devel
59 The audit-libs-devel package contains the header files needed for
60 developing applications that need to use the audit framework library.
61
62 %description libs-devel -l pl
63 Ten pakiet zawiera pliki nag³ówkowe potrzebne do tworzenia aplikacji
64 u¿ywaj±cych biblioteki ¶rodowiska audytu.
65
66 %package libs-static
67 Summary:        Static libaudit library
68 Summary(pl):    Statyczna biblioteka libaudit
69 License:        LGPL
70 Group:          Development/Libraries
71 Requires:       %{name}-libs-devel = %{version}-%{release}
72
73 %description libs-static
74 The audit-libs-static package contains the static library for
75 developing applications that need to use the audit framework library.
76
77 %description libs-static -l pl
78 Ten pakiet zawiera statyczn± bibliotekê do tworzenia aplikacji
79 u¿ywaj±cych ¶rodowiska audytu.
80
81 %prep
82 %setup -q
83
84 install -D %{SOURCE1} lib/linux/audit.h
85 install -D %{SOURCE1} src/mt/linux/audit.h
86
87 %build
88 %{__libtoolize}
89 %{__aclocal}
90 %{__autoconf}
91 %{__autoheader}
92 %{__automake}
93 %configure
94 # override auditd_CFLAGS to avoid -fPIE unsupported by gcc 3.3
95 %{__make} \
96         auditd_CFLAGS=
97
98 %install
99 rm -rf $RPM_BUILD_ROOT
100 install -d $RPM_BUILD_ROOT%{_var}/log/audit
101
102 %{__make} install \
103         DESTDIR=$RPM_BUILD_ROOT
104
105 install -d $RPM_BUILD_ROOT/%{_lib}
106 mv -f $RPM_BUILD_ROOT%{_libdir}/libaudit.so.* $RPM_BUILD_ROOT/%{_lib}
107 ln -sf /%{_lib}/$(cd $RPM_BUILD_ROOT/%{_lib} ; echo libaudit.so.*.*.*) \
108         $RPM_BUILD_ROOT%{_libdir}/libaudit.so
109
110 # We manually install this since Makefile doesn't
111 install -d $RPM_BUILD_ROOT%{_includedir}
112 install lib/libaudit.h $RPM_BUILD_ROOT%{_includedir}
113
114 install %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/auditd
115 install %{SOURCE3} $RPM_BUILD_ROOT/etc/sysconfig/auditd
116
117 %clean
118 rm -rf $RPM_BUILD_ROOT
119
120 %post   libs -p /sbin/ldconfig
121 %postun libs -p /sbin/ldconfig
122
123 %post
124 /sbin/chkconfig --add auditd
125 if [ -f /var/lock/subsys/auditd ]; then
126         /etc/rc.d/init.d/auditd restart >&2
127 else
128         echo "Run \"/etc/rc.d/init.d/auditd start\" to start audit daemon." >&2
129 fi
130
131 %preun
132 if [ "$1" = "0" ]; then
133         if [ -f /var/lock/subsys/auditd ]; then
134                 /etc/rc.d/init.d/auditd stop >&2
135         fi
136         /sbin/chkconfig --del auditd
137 fi
138
139 %files
140 %defattr(644,root,root,755)
141 %doc AUTHORS ChangeLog README THANKS TODO sample.rules
142 %attr(750,root,root) %{_sbindir}/auditctl
143 %attr(750,root,root) %{_sbindir}/auditd
144 %attr(750,root,root) %{_sbindir}/ausearch
145 %attr(750,root,root) %{_sbindir}/autrace
146 %attr(754,root,root) /etc/rc.d/init.d/auditd
147 %config(noreplace) %attr(640,root,root) %{_sysconfdir}/auditd.conf
148 %config(noreplace) %attr(640,root,root) %{_sysconfdir}/audit.rules
149 %config(noreplace) %attr(640,root,root) %verify(not md5 mtime size) /etc/sysconfig/auditd
150 %attr(750,root,root) %dir %{_var}/log/audit
151 %{_mandir}/man8/*
152
153 %files libs
154 %defattr(644,root,root,755)
155 %attr(755,root,root) /%{_lib}/libaudit.so.*.*.*
156
157 %files libs-devel
158 %defattr(644,root,root,755)
159 %attr(755,root,root) %{_libdir}/libaudit.so
160 %{_libdir}/libaudit.la
161 %{_includedir}/libaudit.h
162 %{_mandir}/man3/*
163
164 %files libs-static
165 %defattr(644,root,root,755)
166 %{_libdir}/libaudit.a
This page took 0.060552 seconds and 4 git commands to generate.