]> git.pld-linux.org Git - packages/bogofilter.git/blob - bogofilter.spec
- up to 1.1.5
[packages/bogofilter.git] / bogofilter.spec
1 # TODO:
2 # - make separate package linked with sqlite
3 # - make milter subpackage
4 # - maybe make some separate package with contrib perl scripts?
5 # - remove bogus banner
6 #
7 Summary:        Bayesian Spam Filter
8 Summary(pl.UTF-8):      Bayesowski Filtr Antyspamowy
9 Name:           bogofilter
10 Version:        1.1.5
11 Release:        1
12 License:        GPL v2
13 Group:          Applications/Mail
14 Source0:        http://mesh.dl.sourceforge.net/bogofilter/%{name}-%{version}.tar.bz2
15 # Source0-md5:  d524be9e9c43d9dbb593d7a3c4564f5d
16 Patch0:         %{name}-home_etc.patch
17 URL:            http://bogofilter.sourceforge.net/
18 BuildRequires:  autoconf >= 2.53
19 BuildRequires:  automake
20 BuildRequires:  db-devel
21 BuildRequires:  flex
22 BuildRequires:  gsl-devel
23 Requires:       gsl >= 1.4
24 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
25
26 %define         specflags_ia32  -fomit-frame-pointer
27
28 %description
29 Bogofilter is a Bayesian spam filter. In its normal mode of operation,
30 it takes an email message or other text on standard input, does a
31 statistical check against lists of "good" and "bad" words, and returns
32 a status code indicating whether or not the message is spam.
33 Bogofilter is designed with fast algorithms (including Berkeley DB
34 system), coded directly in C, and tuned for speed, so it can be used
35 for production by sites that process a lot of mail.
36
37 %description -l pl.UTF-8
38 Bogofilter jest bayesowski filtrem antyspamowym. W podstawowym trybie
39 działania na emailu lub innym tekście odczytanym na wejściu wykonuje
40 statystyczne testy na występowanie "dobrych" i "złych" słów i zwraca
41 kod powrotu wskazujący czy wiadomość jest spamem, czy też nie.
42 Bogofilter jest zaprojektowany z użyciem szybkich algorytmów
43 (włączając w to Berkeley DB), napisany w czystym C i "podkręcony" pod
44 kątem szybkości, a więc może być używany na systemach "produkcyjnych",
45 które przetwarzają duże ilości poczty.
46
47 %prep
48 %setup -q
49 %patch0 -p1
50
51 %build
52 %{__aclocal}
53 %{__autoconf}
54 %{__autoheader}
55 %{__automake}
56 %configure
57 %{__make}
58
59 %install
60 rm -rf $RPM_BUILD_ROOT
61
62 %{__make} install \
63         DESTDIR=$RPM_BUILD_ROOT
64
65 cp $RPM_BUILD_ROOT%{_sysconfdir}/bogofilter.cf.example $RPM_BUILD_ROOT%{_sysconfdir}/bogofilter.cf
66
67 install bogogrep $RPM_BUILD_ROOT%{_bindir}
68 # Some apps from contrib:
69 install contrib/bfproxy.pl $RPM_BUILD_ROOT%{_bindir}
70 install contrib/bogominitrain.pl $RPM_BUILD_ROOT%{_bindir}
71 install contrib/mime.get.rfc822.pl $RPM_BUILD_ROOT%{_bindir}
72 install contrib/printmaildir.pl $RPM_BUILD_ROOT%{_bindir}
73 install contrib/spamitarium.pl $RPM_BUILD_ROOT%{_bindir}
74 install contrib/stripsearch.pl $RPM_BUILD_ROOT%{_bindir}
75 install contrib/trainbogo.sh $RPM_BUILD_ROOT%{_bindir}
76
77 # Some final cleanups:
78 rm -f $RPM_BUILD_ROOT%{_bindir}/lexertest
79
80 %clean
81 rm -rf $RPM_BUILD_ROOT
82
83 # That banner is bogus - no sense to have it _while_ upgrading...
84 # It should be some trigger...
85 # It makes at least sense that someone will read this file
86 # before running bogofilter after upgrade and corrupt his db as
87 # it happened before. Bogofilter is not service/daemon by default
88 # so its not run automaticaly after upgrade. One can still backup
89 # his db.
90 %pre
91 %banner %{name} -e <<'EOF'
92
93 WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING
94 ------------------------------------------------------------------------
95 POTENTIAL FOR DATA CORRUPTION DURING UPDATES
96
97 If you plan to upgrade your database library, if only as a side effect
98 of an operating system upgrade, DO HEED the relevant documentation, for
99 instance, the %{_docdir}/%{name}-%{version}/README.db file.
100 You may need to prepare the upgrade with the old version of the software.
101
102 Otherwise, you may cause irrecoverable damage to your databases.
103
104 DO backup your databases before making the upgrade.
105 ------------------------------------------------------------------------
106 WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING
107
108 EOF
109
110 %files
111 %defattr(644,root,root,755)
112 %doc AUTHORS GETTING.STARTED RELEASE* NEWS* README doc/{README.*,bogofilter-SA*,integrating*} TODO
113 %doc contrib/{bogofilter-qfe.sh,bogofilter-milter.pl,dot-qmail-bogofilter-default,*.example,parmtest.sh}
114 %doc contrib/{README.*,randomtrain.sh,scramble.sh}
115 %config(noreplace,missingok) %verify(not md5 mtime size) %{_sysconfdir}/bogofilter.cf
116 %attr(755,root,root) %{_bindir}/*
117 %{_mandir}/man1/*
This page took 0.059578 seconds and 3 git commands to generate.