annotate syslog2iptables.spec.in @ 36:6a2f26976898

shutdown removes iptables entries that we added
author carl
date Thu, 08 Nov 2007 10:52:56 -0800
parents ee9553116dbf
children d9ae11033b4b
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
11
a9b52f657f08 finish coding 1.0 version
carl
parents: 10
diff changeset
1 %define localstatedir /var/lib
a9b52f657f08 finish coding 1.0 version
carl
parents: 10
diff changeset
2
10
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
3 Summary: Syslog to iptables dynamic firewall
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
4 Name: @PACKAGE@
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
5 Version: @VERSION@
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
6 Release: %{?custom_release}%{!?custom_release:1}
31
carl
parents: 18
diff changeset
7 License: GPL
10
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
8 Group: System Environment/Daemons
11
a9b52f657f08 finish coding 1.0 version
carl
parents: 10
diff changeset
9 Source: http://www.five-ten-sg.com/@PACKAGE@/packages/@PACKAGE@-@VERSION@.tar.gz
10
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
10 BuildRoot: %{_tmppath}/%{name}-%{version}-buildroot
11
a9b52f657f08 finish coding 1.0 version
carl
parents: 10
diff changeset
11 URL: http://www.five-ten-sg.com/@PACKAGE@/
10
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
12 Vendor: 510 Software Group
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
13 Packager: 510 Software Group
18
b34e716781ed prevent auto-requires in rpm building
carl
parents: 15
diff changeset
14 AutoReqProv: no
b34e716781ed prevent auto-requires in rpm building
carl
parents: 15
diff changeset
15
b34e716781ed prevent auto-requires in rpm building
carl
parents: 15
diff changeset
16 Requires(post,preun): /sbin/chkconfig
b34e716781ed prevent auto-requires in rpm building
carl
parents: 15
diff changeset
17 Requires(post,preun): /sbin/service
10
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
18 Requires: iptables
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
19 Requires: coreutils
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
20 BuildRequires: gcc gcc-c++
18
b34e716781ed prevent auto-requires in rpm building
carl
parents: 15
diff changeset
21 Requires: libc.so.6, libgcc_s.so.1, libm.so.6, libpthread.so.0, libstdc++.so.6
10
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
22
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
23
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
24 %description
11
a9b52f657f08 finish coding 1.0 version
carl
parents: 10
diff changeset
25
a9b52f657f08 finish coding 1.0 version
carl
parents: 10
diff changeset
26 @PACKAGE@ is a simple adaptive firewall. It maintains the INPUT chain of the iptables firewall set based on syslog entries.
10
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
27
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
28 %prep
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
29
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
30
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
31 %setup
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
32
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
33
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
34 %build
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
35 ./configure --prefix=%{_prefix} \
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
36 --bindir=%{_bindir} --mandir=%{_mandir} \
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
37 --localstatedir=%{localstatedir} --libdir=%{_libdir} \
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
38 --datadir=%{_datadir} --includedir=%{_includedir} \
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
39 --sysconfdir=%{_sysconfdir}
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
40 make
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
41
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
42
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
43 %install
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
44 if [ "$RPM_BUILD_ROOT" = "/" -o -z "$RPM_BUILD_ROOT" ] ; then
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
45 echo sorry, you probably do not want me to delete the old buildroot at $RPM_BUILD_ROOT
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
46 exit 1
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
47 fi
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
48 rm -rf $RPM_BUILD_ROOT
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
49 make prefix=$RPM_BUILD_ROOT%{_prefix} bindir=$RPM_BUILD_ROOT%{_bindir} \
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
50 mandir=$RPM_BUILD_ROOT%{_mandir} libdir=$RPM_BUILD_ROOT%{_libdir} \
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
51 localstatedir=$RPM_BUILD_ROOT%{localstatedir} \
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
52 datadir=$RPM_BUILD_ROOT%{_datadir} \
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
53 includedir=$RPM_BUILD_ROOT%{_includedir} \
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
54 sysconfdir=$RPM_BUILD_ROOT%{_sysconfdir} install
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
55 mkdir -p $RPM_BUILD_ROOT/etc/rc.d/init.d
12
c2a2e35a85ac final documentation, rpm builds properly
carl
parents: 11
diff changeset
56 mkdir -p $RPM_BUILD_ROOT%{_datadir}/doc/@PACKAGE@-@VERSION@
33
carl
parents: 31
diff changeset
57 mv -f $RPM_BUILD_ROOT%{_sysconfdir}/@PACKAGE@ $RPM_BUILD_ROOT/etc/rc.d/init.d
12
c2a2e35a85ac final documentation, rpm builds properly
carl
parents: 11
diff changeset
58 mv AUTHORS COPYING ChangeLog NEWS README $RPM_BUILD_ROOT%{_datadir}/doc/@PACKAGE@-@VERSION@
10
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
59
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
60
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
61 %clean
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
62
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
63
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
64 %pre
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
65
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
66
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
67 %post
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
68 /sbin/chkconfig --add @PACKAGE@
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
69
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
70
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
71 %preun
31
carl
parents: 18
diff changeset
72 [ $1 = 0 ] && /sbin/service @PACKAGE@ stop || :
10
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
73
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
74
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
75 %postun
31
carl
parents: 18
diff changeset
76 [ $1 = 0 ] && /sbin/chkconfig --del @PACKAGE@
10
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
77
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
78
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
79 %files
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
80 %defattr(-,root,root)
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
81 %{_sbindir}/*
12
c2a2e35a85ac final documentation, rpm builds properly
carl
parents: 11
diff changeset
82 %doc %{_mandir}/*
c2a2e35a85ac final documentation, rpm builds properly
carl
parents: 11
diff changeset
83 %docdir %{_datadir}/doc/@PACKAGE@-@VERSION@
c2a2e35a85ac final documentation, rpm builds properly
carl
parents: 11
diff changeset
84 %{_datadir}/doc/@PACKAGE@-@VERSION@
10
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
85 %config(noreplace) %{_sysconfdir}/@PACKAGE@.conf
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
86 /etc/rc.d/init.d/@PACKAGE@
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
87
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
88 %changelog
31
carl
parents: 18
diff changeset
89 * Thu Aug 30 2007 Carl Byington 1.5
carl
parents: 18
diff changeset
90 - Fix pre/post scripts
carl
parents: 18
diff changeset
91
10
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
92 * Thu Dec 08 2005 Carl Byington 1.0
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
93 - initial revision based on dnsbl spec file
5dfe0138b4f9 initial coding
carl
parents:
diff changeset
94 - and http://www.fedora.us/docs/rpm-packaging-guidelines.html