Removing gateways[] list - no longer used.
[privoxy.git] / junkbuster-suse.spec
1 # $Id: junkbuster-suse.spec,v 1.2 2001/06/07 17:18:44 swa Exp $
2 #
3 # Written by and Copyright (C) 2001 the SourceForge
4 # IJBSWA team.  http://ijbswa.sourceforge.net
5 #
6 # Based on the Internet Junkbuster originally written
7 # by and Copyright (C) 1997 Anonymous Coders and 
8 # Junkbusters Corporation.  http://www.junkbusters.com
9 #
10 # This program is free software; you can redistribute it 
11 # and/or modify it under the terms of the GNU General
12 # Public License as published by the Free Software
13 # Foundation; either version 2 of the License, or (at
14 # your option) any later version.
15 #
16 # This program is distributed in the hope that it will
17 # be useful, but WITHOUT ANY WARRANTY; without even the
18 # implied warranty of MERCHANTABILITY or FITNESS FOR A
19 # PARTICULAR PURPOSE.  See the GNU General Public
20 # License for more details.
21 #
22 # The GNU General Public License should be included with
23 # this file.  If not, you can view it at
24 # http://www.gnu.org/copyleft/gpl.html
25 # or write to the Free Software Foundation, Inc., 59
26 # Temple Place - Suite 330, Boston, MA  02111-1307, USA.
27 #
28 # $Log: junkbuster-suse.spec,v $
29 # Revision 1.2  2001/06/07 17:18:44  swa
30 # header fixed
31 #
32 #
33 # neededforbuild  -ijb
34 # usedforbuild    -ijb aaa_base aaa_dir autoconf automake base bash bindutil binutils bison bzip compress cpio cracklib db devs diffutils e2fsprogs file fileutils findutils flex gawk gcc gdbm gdbm-devel gettext glibc glibc-devel gpm gppshare groff gzip kbd less libtool libz lx_suse make mktemp modutils ncurses ncurses-devel net-tools netcfg nkitb pam pam-devel patch perl pgp ps rcs rpm sendmail sh-utils shadow strace syslogd sysvinit texinfo textutils timezone unzip util-linux vim xdevel xf86 xshared
35
36 Vendor:       http://ijbswa.sourceforge.net
37 Distribution: defineme
38 Name:         junkbuster
39 Packager:     Stefan Waldherr <stefan@waldherr.org>
40
41 Copyright:    GPL
42 Group:        Networking/Utilities
43 Provides:     ijb
44 Obsoletes:    ijb
45 Autoreqprov:  on
46 Version: 2.9
47 Release: 4
48 Summary:      The Internet Junkbuster
49 Source:  http://www.waldherr.org/junkbuster/ijbswa.tar.gz
50 atch:   ijb20.dif
51
52 #
53 # -----------------------------------------------------------------------------
54 #
55 %description
56 The Internet Junkbuster (TM) blocks unwanted banner ads and protects
57 your privacy from cookies and other threats. It's free under the GPL
58 (no warranty), runs under *NIX and works with almost any browser. You
59 need to clear you browser's cache and specify the proxy-server,
60 described in /usr/doc/junkbuster.  This is a modified version which
61 returns a blank GIF for blocked images by default.  But you can
62 configure this via /etc/junkbuster/config.
63
64 Authors:
65 --------
66     http://ijbswa.sourceforge.net
67
68 SuSE series: n
69
70 #
71 # -----------------------------------------------------------------------------
72 #
73 %prep
74 %setup -n ijb20
75 %patch
76
77 #
78 # -----------------------------------------------------------------------------
79 #
80 %build
81 make
82 cat > /etc/init.d/junkbuster << EOT
83 #! /bin/sh
84 # Copyright (c) 1999 SuSE GmbH Nuremberg, Germany.  All rights reserved.
85 #
86 # Author: Daniel Bischof <daniel@suse.de>, 1999
87 #
88 # /sbin/init.d/junkbuster
89 #
90 ### BEGIN INIT INFO
91 # Provides:       junkbuster ijb
92 # Required-Start: $network syslog
93 # Required-Stop:
94 # Default-Start:  3 5
95 # Default-Stop:
96 # Description:    Starts the Internet Junkbuster
97 ### END INIT INFO
98 . /etc/rc.config
99 base=\${0##*/}
100 link=\${base#*[SK][0-9][0-9]}
101 #test \$link = \$base && START_IJB=yes
102 #test "\$START_IJB" = "yes" || exit 0
103 return=\$rc_done
104 case "\$1" in
105     start)
106         echo -n "Starting The Internet Junkbuster"
107         su - nobody -c 'nohup /usr/sbin/junkbuster /etc/ijb/junkbstr.ini < /dev/null > /dev/null &'
108         sleep 1
109         echo -e "\$return"
110         ;;
111     stop)
112         echo -n "Shutting down The Internet Junkbuster"
113         killproc -TERM /usr/sbin/junkbuster || return=\$rc_failed
114         echo -e "\$return"
115         ;;
116     restart|reload)
117         \$0 stop && \$0 start || return=\$rc_failed
118         ;;
119     status)
120         checkproc /usr/sbin/junkbuster && echo OK || echo No process
121         ;;
122     *)
123         echo "Usage: \$0 {start|restart|status|stop}"
124         exit 1
125 esac
126 test "\$return" = "\$rc_done" || exit 1
127 exit 0
128 EOT
129 chmod 755 /etc/init.d/junkbuster
130 ln -sf /etc/init.d/junkbuster /usr/sbin/rcjunkbuster
131
132 #
133 # -----------------------------------------------------------------------------
134 #
135 %install
136 install -m 755 junkbuster /usr/sbin
137 install -d /etc/ijb
138 install -m 644 *.ini /etc/ijb
139 install -m 644 junkbuster.1 /usr/share/man/man1
140 %{?suse_check}
141
142 #
143 # -----------------------------------------------------------------------------
144 #
145 %post
146 sbin/insserv etc/init.d/junkbuster
147
148 #
149 # -----------------------------------------------------------------------------
150 #
151 %postun
152 sbin/insserv etc/init.d/
153
154 #
155 # -----------------------------------------------------------------------------
156 #
157 %files
158 %doc README *.html
159 /usr/sbin/junkbuster
160 /usr/share/man/man1/junkbuster.1.gz
161 %config(noreplace) /etc/ijb
162 /etc/init.d/junkbuster
163 /usr/sbin/rcjunkbuster
164
165 #
166 # -----------------------------------------------------------------------------
167 #
168 %changelog -n junkbuster
169 * Wed Feb 14 2001 - uli@suse.de
170 - fixed init script
171 * Wed Dec 06 2000 - bjacke@suse.de
172 - renamed package to junkbuster
173 - fixed copyright tag
174 * Thu Nov 30 2000 - uli@suse.de
175 - moved init script to /etc/init.d
176 * Wed Feb 16 2000 - kukuk@suse.de
177 - Move /usr/man -> /usr/share/man
178 - Mark /etc/ijb as "config(noreplace)"
179 * Mon Sep 20 1999 - uli@suse.de
180 - fixed init script
181 * Mon Sep 13 1999 - bs@suse.de
182 - ran old prepare_spec on spec file to switch to new prepare_spec.
183 * Thu Apr 01 1999 - daniel@suse.de
184 - do not start ijb as root (security)
185 * Tue Mar 30 1999 - daniel@suse.de
186 - donĀ“t use saclfile.ini
187 * Tue Mar 30 1999 - daniel@suse.de
188 - small fix to whitelist-configuration,
189   version is and was 2.0.2 WITHOUT Stefan Waldherr's patches
190   (http://www.waldherr.org/junkbuster/)
191 * Mon Mar 01 1999 - daniel@suse.de
192 - new package: version 2.0