]> git.pld-linux.org Git - packages/ulogd.git/blob - ulogd.spec
- URL fixes and other cosmetics
[packages/ulogd.git] / ulogd.spec
1 Summary:        ULOGD - the Userspace Logging Daemon for iptables
2 Summary(pl):    Demon loguj±cy w trybie u¿ytkownika dla iptables
3 Name:           ulogd
4 Version:        1.00
5 Release:        1
6 License:        GPL
7 Group:          Networking/Daemons
8 Source0:        ftp://ftp.netfilter.org/pub/ulogd/%{name}-%{version}.tar.bz2
9 # Source0-md5:  debd61d22f28ca9f4505bb488a1a1e1c
10 Source1:        %{name}.init
11 Source2:        %{name}.sysconfig
12 Source3:        %{name}.logrotate
13 Source4:        %{name}.conf
14 URL:            http://gnumonks.org/projects/ulogd/
15 BuildRequires:  autoconf
16 BuildRequires:  mysql-devel
17 Requires(post,preun):   /sbin/chkconfig
18 Requires(post): fileutils
19 #Requires:      kernel >= 2.4.0test9
20 Requires:       iptables
21 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
22
23 %define         _sysconfdir     /etc
24
25 %description
26 This packages is intended for passing packets from the kernel to
27 userspace to do some logging there. It should work like that:
28 - register a target called ULOG with netfilter
29 - if the target is hit:
30   - send the packet out using netlink multicast facility
31   - return NF_ACCEPT immediately.
32
33 %description -l pl
34 Ten pakiet ma s³u¿yæ do wysy³ania pakietów z j±dra do przestrzeni
35 u¿ytkownika w celu logowania. Powinien dzia³aæ tak:
36 - zarejestrowaæ w netfilterze cel o nazwie ULOG
37 - je¿eli cel zosta³ osi±gniêty:
38   - wys³aæ pakiet poprzez netlink
39   - zwróciæ natychmiast NF_ACCEPT.
40
41 %package mysql
42 Summary:        MySQL plugin for ulogd
43 Summary(pl):    Wtyczka MySQL dla ulogd
44 Group:          Networking/Daemons
45 Requires:       mysql
46 Obsoletes:      iptables-ulogd-mysql
47
48 %description mysql
49 MySQL plugin for ulogd.
50
51 %description mysql -l pl
52 Wtyczka MySQL dla ulogd.
53
54 %prep
55 %setup -q
56
57 %build
58 %{__autoconf}
59 %configure \
60         --with-mysql
61 %{__make}
62
63 %install
64 rm -rf $RPM_BUILD_ROOT
65 install -d $RPM_BUILD_ROOT{%{_sbindir},/etc/{sysconfig,logrotate.d,rc.d/init.d}} \
66         $RPM_BUILD_ROOT/var/log
67
68 %{__make} install DESTDIR=$RPM_BUILD_ROOT
69
70 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/ulogd
71 install %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/ulogd
72 install %{SOURCE3} $RPM_BUILD_ROOT/etc/logrotate.d/ulogd
73 install %{SOURCE4} $RPM_BUILD_ROOT%{_sysconfdir}
74
75
76 touch $RPM_BUILD_ROOT/var/log/ulogd{,.pktlog}
77
78 %clean
79 rm -rf $RPM_BUILD_ROOT
80
81 %post
82 if [ ! -f /var/log/ulogd ]; then
83         touch /var/log/ulogd{,.pktlog}
84         chmod 640 /var/log/ulogd{,.pktlog}
85 fi
86
87 /sbin/chkconfig --add ulogd
88 if [ -f /var/lock/subsys/ulogd ]; then
89         /etc/rc.d/init.d/ulogd restart 1>&2
90 else
91         echo "Run \"/etc/rc.d/init.d/ulogd start\" to start ulogd daemon." 1>&2
92 fi
93
94 %preun
95 if [ "$1" = "0" ]; then
96         if [ -f /var/lock/subsys/ulogd ]; then
97                 /etc/rc.d/init.d/ulogd stop 1>&2
98         fi
99         /sbin/chkconfig --del ulogd
100 fi
101
102 %files
103 %defattr(644,root,root,755)
104 %doc Changes doc/*.{ps,txt,html}
105 %attr(640,root,root) %config(noreplace) %verify(not mtime md5 size) /etc/sysconfig/ulogd
106 %attr(640,root,root) %config(noreplace) %verify(not mtime md5 size) %{_sysconfdir}/ulogd.conf
107 %attr(640,root,root) /etc/logrotate.d/ulogd
108 %attr(754,root,root) /etc/rc.d/init.d/ulogd
109
110 %attr(755,root,root) %{_sbindir}/*
111 %attr(755,root,root) %{_libdir}/ulogd/ulogd_[BLOP]*.so
112
113 %attr(640,root,root) %ghost /var/log/*
114
115 %files mysql
116 %defattr(644,root,root,755)
117 %doc doc/mysql*
118 %attr(755,root,root) %{_libdir}/ulogd/ulogd_MYSQL.so
This page took 0.073963 seconds and 4 git commands to generate.