]> git.pld-linux.org Git - packages/ulogd.git/blame - ulogd.spec
- use macros in %{pre,post}{,un}
[packages/ulogd.git] / ulogd.spec
CommitLineData
e591aab5
JR
1Summary: ULOGD - the Userspace Logging Daemon for iptables
2Name: ulogd
57154dc8 3Version: 0.95
cfdad27b 4Release: 2
e591aab5
JR
5License: GPL
6Group: Networking/Daemons
264b4e4b 7Group(de): Netzwerkwesen/Server
e591aab5
JR
8Group(pl): Sieciowe/Serwery
9Source0: ftp://ftp.sunbeam.franken.de/pub/netfilter/%{name}-%{version}.tar.gz
264b4e4b 10Source1: %{name}.init
11Source2: %{name}.sysconfig
12Source3: %{name}.logrotate
13Source4: %{name}.conf
e591aab5
JR
14Patch0: %{name}-DESTDIR.patch
15BuildRequires: sgml-tools
16BuildRequires: sgmls
17BuildRequires: mysql-devel
18#Requires: kernel >= 2.4.0test9
19Requires: iptables
cfdad27b 20Prereq: /sbin/chkconfig
e591aab5
JR
21BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
22
23%define _sysconfdir /etc
24
25%description
264b4e4b 26This packages is intended for passing packets from the kernel to
27userspace to do some logging there. It should work like that:
e591aab5
JR
28
29- Register a target called ULOG with netfilter
30- if the target is hit:
264b4e4b 31 - send the packet out using netlink multicast facility
32 - return NF_ACCEPT immediately
e591aab5
JR
33
34%package mysql
35Summary: Mysql plugin for ulogd
36Group: Networking/Daemons
264b4e4b 37Group(de): Netzwerkwesen/Server
e591aab5
JR
38Group(pl): Sieciowe/Serwery
39Requires: mysql
40Obsoletes: iptables-ulogd-mysql
41
42%description mysql
43mysql plugin for ulogd
44
45%prep
46%setup -q
47%patch0 -p1
48
49%build
264b4e4b 50%configure \
51 --with-mysql
e591aab5
JR
52%{__make}
53
54%install
55rm -rf $RPM_BUILD_ROOT
c6e1358b 56install -d $RPM_BUILD_ROOT{%{_sbindir},/etc/{sysconfig,logrotate.d,rc.d/init.d}} \
264b4e4b 57 $RPM_BUILD_ROOT/var/log
e591aab5
JR
58
59%{__make} install DESTDIR=$RPM_BUILD_ROOT
60
264b4e4b 61install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/ulogd
62install %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/ulogd
63install %{SOURCE3} $RPM_BUILD_ROOT/etc/logrotate.d/ulogd
e591aab5
JR
64install %{SOURCE4} $RPM_BUILD_ROOT%{_sysconfdir}/
65
66gzip -9nf Changes doc/*.{ps,txt,table}
67
68touch $RPM_BUILD_ROOT/var/log/ulogd{,.pktlog}
69
70%clean
71rm -rf $RPM_BUILD_ROOT
72
73%post
74if [ ! -f /var/log/ulogd ]; then
75 touch /var/log/ulogd{,.pktlog}
76 chmod 640 /var/log/ulogd{,.pktlog}
77fi
b0ff08b6 78DESC="ulogd daemon"; %chkconfig_add
e591aab5
JR
79
80%preun
b0ff08b6 81%chkconfig_del
e591aab5
JR
82
83%files
84%defattr(644,root,root,755)
85%doc Changes.gz doc/*.{ps,txt}.gz
86%attr(640,root,root) %config(noreplace) %verify(not mtime md5 size) /etc/sysconfig/ulogd
264b4e4b 87%attr(640,root,root) %config(noreplace) %verify(not mtime md5 size) %{_sysconfdir}/ulogd.conf
e591aab5
JR
88%attr(640,root,root) /etc/logrotate.d/ulogd
89%attr(754,root,root) /etc/rc.d/init.d/ulogd
90
91%attr(755,root,root) %{_sbindir}/*
92%attr(755,root,root) %{_libdir}/ulogd/ulogd_[BLOP]*.so
93
94%attr(640,root,root) %ghost /var/log/*
95
96%files mysql
264b4e4b 97%defattr(644,root,root,755)
e591aab5
JR
98%doc doc/mysql*
99%attr(755,root,root) %{_libdir}/ulogd/ulogd_MYSQL.so
This page took 0.097816 seconds and 4 git commands to generate.