1 |
Name: ulogd |
2 |
Version: 1.24 |
3 |
Release: 2%{?dist} |
4 |
Summary: The userspace logging daemon for netfilter |
5 |
License: GPL |
6 |
Group: System Environment/Daemons |
7 |
URL: http://gnumonks.org/projects/ulogd |
8 |
Source0: http://ftp.netfilter.org/pub/ulogd/ulogd-%{version}.tar.bz2 |
9 |
Source1: ulogd.logrotate |
10 |
Source2: ulogd.8 |
11 |
Patch1: ulogd-1.21-logdir.patch |
12 |
Patch2: ulogd-1.02-init.patch |
13 |
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) |
14 |
Requires(post): initscripts, chkconfig |
15 |
Requires(postun): initscripts, chkconfig |
16 |
BuildRequires: mysql-devel |
17 |
BuildRequires: mysql-devel |
18 |
BuildRequires: postgresql-devel |
19 |
BuildRequires: /usr/include/pcap.h |
20 |
|
21 |
%description |
22 |
Ulogd is an universal logging daemon for the ULOG target of netfilter, the |
23 |
Linux 2.4+ firewalling subsystem. Ulogd is able to log packets in various |
24 |
formats to different targets (text files, databases, etc..). It has an |
25 |
easy-to-use plugin interface to add new protocols and new output targets. |
26 |
|
27 |
%package mysql |
28 |
Summary: MySQL output plugin for ulogd |
29 |
Group: System Environment/Daemons |
30 |
Requires: %{name} = %{version} |
31 |
|
32 |
%description mysql |
33 |
Ulogd-mysql is a MySQL output plugin for ulogd. It enables logging of |
34 |
firewall information into a MySQL database. |
35 |
|
36 |
%package pgsql |
37 |
Summary: PostgreSQL output plugin for ulogd |
38 |
Group: System Environment/Daemons |
39 |
Requires: %{name} = %{version} |
40 |
|
41 |
%description pgsql |
42 |
Ulogd-pgsql is a PostgreSQL output plugin for ulogd. It enables logging of |
43 |
firewall information into a PostgreSQL database. |
44 |
|
45 |
%prep |
46 |
%setup -q |
47 |
%patch1 -p1 -b .logdir |
48 |
%patch2 -p1 -b .fedora |
49 |
|
50 |
%build |
51 |
%configure --with-mysql --with-pgsql |
52 |
# Does not support parallel builds |
53 |
make |
54 |
|
55 |
%install |
56 |
rm -rf $RPM_BUILD_ROOT |
57 |
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir} |
58 |
mkdir -p $RPM_BUILD_ROOT%{_libdir}/ulogd |
59 |
mkdir -p $RPM_BUILD_ROOT%{_sbindir}/sbin |
60 |
make DESTDIR=$RPM_BUILD_ROOT install |
61 |
|
62 |
mkdir -p $RPM_BUILD_ROOT%{_initrddir} |
63 |
install -m755 ulogd.init $RPM_BUILD_ROOT%{_initrddir}/ulogd |
64 |
|
65 |
mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/log/ulogd |
66 |
|
67 |
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d |
68 |
install -m644 %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d/ulogd |
69 |
|
70 |
mkdir -p $RPM_BUILD_ROOT%{_mandir}/man8 |
71 |
sed -e 's/@VERSION@/%{version}/g' %{SOURCE2} > $RPM_BUILD_ROOT%{_mandir}/man8/ulogd.8 |
72 |
gzip $RPM_BUILD_ROOT%{_mandir}/man8/ulogd.8 |
73 |
|
74 |
|
75 |
%post |
76 |
/sbin/chkconfig --add ulogd |
77 |
|
78 |
%preun |
79 |
if [ "$1" = 0 ]; then |
80 |
/sbin/service ulogd stop > /dev/null 2>&1 ||: |
81 |
/sbin/chkconfig --del ulogd |
82 |
fi |
83 |
|
84 |
%postun |
85 |
if [ "$1" -ge "1" ]; then |
86 |
/sbin/service ulogd reload > /dev/null 2>&1 ||: |
87 |
fi |
88 |
|
89 |
|
90 |
%clean |
91 |
rm -rf $RPM_BUILD_ROOT |
92 |
|
93 |
%files |
94 |
%defattr(-,root,root,) |
95 |
%doc COPYING AUTHORS README |
96 |
%doc doc/ulogd.txt doc/ulogd.a4.ps doc/ulogd.html |
97 |
%doc doc/mysql.table* doc/pgsql.table |
98 |
%{_sbindir}/ulogd |
99 |
%config(noreplace) %{_sysconfdir}/ulogd.conf |
100 |
%config(noreplace) %{_sysconfdir}/rc.d/init.d/ulogd |
101 |
%{_libdir}/ulogd |
102 |
%dir %{_localstatedir}/log/ulogd |
103 |
%config(noreplace) %{_sysconfdir}/logrotate.d/ulogd |
104 |
%{_mandir}/man8/ulogd.8.gz |
105 |
%exclude %{_libdir}/ulogd/ulogd_MYSQL.so |
106 |
%exclude %{_libdir}/ulogd/ulogd_PGSQL.so |
107 |
|
108 |
%files mysql |
109 |
%defattr(0644,root,root,0755) |
110 |
%{_libdir}/ulogd/ulogd_MYSQL.so |
111 |
|
112 |
%files pgsql |
113 |
%defattr(0644,root,root,0755) |
114 |
%{_libdir}/ulogd/ulogd_PGSQL.so |
115 |
|
116 |
%changelog |
117 |
* Sun Apr 29 2007 Shad L. Lords <slords@mail.com> |
118 |
- Clean up spec so package can be built by koji/plague |
119 |
|
120 |
* Thu Aug 31 2006 Aurelien Bompard <abompard@fedoraproject.org> 1.24-2 |
121 |
- rebuild |
122 |
|
123 |
* Wed Feb 22 2006 Aurelien Bompard <gauret[AT]free.fr> 1.24-1 |
124 |
- version 1.24 |
125 |
- drop patch3 (applied upstream) |
126 |
- drop patch4 (upstream uses mysql-config to detect libdir now) |
127 |
- drop patch5 (applied upstream) |
128 |
|
129 |
* Tue Feb 21 2006 Aurelien Bompard <gauret[AT]free.fr> 1.23-3 |
130 |
- rebuild for FC5 |
131 |
|
132 |
* Sun Jul 24 2005 Aurelien Bompard <gauret[AT]free.fr> 1.23-2 |
133 |
- compress rotated logs |
134 |
- start after mysql in the init process |
135 |
- use dist tag |
136 |
|
137 |
* Tue Apr 19 2005 Aurelien Bompard <gauret[AT]free.fr> 1.23-1.fc4 |
138 |
- version 1.23 |
139 |
- change release tag for FC4 |
140 |
- add patch for GCC4 (upstream bug #323) |
141 |
|
142 |
* Fri Apr 7 2005 Michael Schwendt <mschwendt[AT]users.sf.net> |
143 |
- rebuilt |
144 |
|
145 |
* Wed Mar 09 2005 Aurelien Bompard <gauret[AT]free.fr> 1.22-1 |
146 |
- version 1.22 |
147 |
- add gpg signature to sources |
148 |
|
149 |
* Sun Feb 20 2005 Aurelien Bompard <gauret[AT]free.fr> 1.21-1 |
150 |
- version 1.21 |
151 |
|
152 |
* Fri Dec 17 2004 Michael Schwendt <mschwendt[AT]users.sf.net> 1.02-8 |
153 |
- revise x86_64 patch to remove more hardcoded /lib badness |
154 |
|
155 |
* Fri Dec 17 2004 Michael Schwendt <mschwendt[AT]users.sf.net> 1.02-7 |
156 |
- x86_64, patch configure to look for mysql/pgsql below %%_libdir. |
157 |
- delete undefined %%epoch in mysql/pgsql sub package dep. |
158 |
|
159 |
* Sun Oct 31 2004 Aurelien Bompard <gauret[AT]free.fr> 1.02-6 |
160 |
- apply Michael Schwendt's suggestions in bug 1598 |
161 |
|
162 |
* Wed Oct 20 2004 Aurelien Bompard <gauret[AT]free.fr> 0:1.02-0.fdr.5 |
163 |
- enable MySQL and PostgreSQL in subpackages |
164 |
- add man page from Debian |
165 |
|
166 |
* Wed Oct 06 2004 Aurelien Bompard <gauret[AT]free.fr> 0:1.02-0.fdr.4 |
167 |
- apply QA suggestions (bug 1598) |
168 |
|
169 |
* Sat Jul 10 2004 Aurelien Bompard <gauret[AT]free.fr> 0:1.02-0.fdr.3 |
170 |
- disable parallel builds |
171 |
- add chkconfig to Requires(pre,post) |
172 |
- set the right mode for /etc/logrotate.d/ulogd |
173 |
- rotate weekly |
174 |
|
175 |
* Sun May 16 2004 Aurelien Bompard <gauret[AT]free.fr> 0:1.02-0.fdr.2 |
176 |
- Add Epoch: 0 |