]> git.pld-linux.org Git - packages/spamassassin.git/blob - spamassassin.spec
- updated to 2.64
[packages/spamassassin.git] / spamassassin.spec
1 # TODO:
2 # - SECURITY: http://securitytracker.com/alerts/2004/Aug/1010903.html
3 #
4 # Conditional build:
5 %bcond_with  tests      # perform "make test"
6 #
7 %include        /usr/lib/rpm/macros.perl
8 %define pdir    Mail
9 %define pnam    SpamAssassin
10 Summary:        A spam filter for email which can be invoked from mail delivery agents
11 Summary(pl):    Filtr antyspamowy, przeznaczony dla programów dostarczaj±cych pocztê (MDA)
12 Name:           spamassassin
13 Version:        2.64
14 Release:        0.1
15 License:        GPL v1+ or Artistic
16 Group:          Applications/Mail
17 Source0:        http://old.spamassassin.org/released/%{pdir}-%{pnam}-%{version}.tar.gz
18 # Source0-md5:  a82a9dab95462d102e253edb99091fdd
19 Source1:        %{name}.sysconfig
20 Patch0:         %{name}-rc-script.patch
21 URL:            http://spamassassin.org/
22 BuildRequires:  openssl-devel >= 0.9.6m
23 BuildRequires:  perl-devel >= 5.6
24 %if %{with tests}
25 BuildRequires:  perl-HTML-Parser >= 3
26 # are these really needed?
27 BuildRequires:  perl-MailTools
28 BuildRequires:  perl-Mail-Audit
29 BuildRequires:  perl-MIME-Base64
30 BuildRequires:  perl-MIME-tools
31 %endif
32 BuildRequires:  rpm-perlprov >= 4.0.2-104
33 PreReq:         rc-scripts
34 Requires(post,preun):   /sbin/chkconfig
35 Requires:       perl-Mail-SpamAssassin >= %{version}
36 Obsoletes:      SpamAssassin
37 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
38
39 %define         _noautoreq      'perl(Razor2::Client::Agent)' 'perl(Razor::Agent)' 'perl(Razor::Client)' 'perl(DBI)'
40
41 %description
42 SpamAssassin provides you with a way to reduce if not completely
43 eliminate Unsolicited Commercial Email (SPAM) from your incoming
44 email. It can be invoked by a MDA such as sendmail or postfix, or can
45 be called from a procmail script, .forward file, etc. It uses a
46 genetic-algorithm evolved scoring system to identify messages which
47 look spammy, then adds headers to the message so they can be filtered
48 by the user's mail reading software. This distribution includes the
49 spamd/spamc components which create a server that considerably speeds
50 processing of mail.
51
52 %description -l pl
53 SpamAssassin udostêpnia Ci mo¿liwo¶æ zredukowania, je¶li nie
54 kompletnego wyeliminowania Niezamawianej Komercyjnej Poczty
55 (Unsolicited Commercial Email, spamu) z Twojej poczty. Mo¿e byæ
56 wywo³ywany z MDA, np. Sendmaila czy Postfixa, lub z pliku ~/.forward
57 itp. U¿ywa ogólnego algorytmu oceniania w celu identyfikacji
58 wiadomo¶ci, które wygl±daj± na SPAM, po czym dodaje nag³ówki do
59 wiadomo¶ci, umo¿liwiaj±c filtrowanie przez oprogramowanie u¿ytkownika.
60 Ta dystrybucja zawiera programy spamd/spamc, umo¿liwiaj±ce
61 uruchomienie serwera, co znacznie przyspieszy proces przetwarzania
62 poczty.
63
64 %package tools
65 Summary:        Miscleanous tools for SpamAssassin
66 Summary(pl):    Przeró¿ne narzêdzia zwi±zane z SpamAssassin
67 Group:          Applications/Mail
68 Obsoletes:      SpamAssassin-tools
69
70 %description tools
71 Miscleanous tools from various authors, distributed with SpamAssassin.
72 See /usr/share/doc/spamassassin-tools-*/.
73
74 %description tools -l pl
75 Przeró¿ne narzêdzia, dystrybuowane razem z SpamAssassin. Zobacz
76 /usr/share/doc/spamassassin-tools-*/.
77
78 %package spamd
79 Summary:        spamd - daemonized version of spamassassin
80 Summary(pl):    spamd - spamassassin w postaci demona
81 Group:          Applications/Mail
82
83 %description spamd
84 The purpose of this program is to provide a daemonized version of the
85 spamassassin executable. The goal is improving throughput performance
86 for automated mail checking.
87
88 This is intended to be used alongside "spamc", a fast, low-overhead C
89 client program.
90
91 %description spamd -l pl
92 Spamd jest "demoniczn±" wersj± spamassassina. Jego zadaniem jest
93 poprawa wydajno¶ci automatycznego sprawdzania poczty.
94
95 Spamd powinien byæ u¿ywany wespó³ ze "spamc", który jest szybkim i
96 wydajnym programem klienckim.
97
98 %package spamc
99 Summary:        spamc - client for spamd
100 Summary(pl):    spamc - klient dla spamd
101 Group:          Applications/Mail
102
103 %description spamc
104 Spamc is the client half of the spamc/spamd pair. It should be used in
105 place of "spamassassin" in scripts to process mail. It will read the
106 mail from STDIN, and spool it to its connection to spamd, then read
107 the result back and print it to STDOUT. Spamc has extremely low
108 overhead in loading, so it should be much faster to load than the
109 whole spamassassin program.
110
111 %description spamc -l pl
112 Spamc powinien byæ u¿ywany zamiast "spamassassina" w skryptach
113 przetwarzaj±cych pocztê. Zczytuje pocztê ze STDIN, kolejkuje j± a
114 nastêpnie przekazuje spamd'owi, odczytuje wynik i podaje go na STDOUT.
115 Spamc stara siê nie obci±¿aæ zbytnio procesora podczas ³adowania,
116 dziêki czemu powinien dzia³aæ szybciej ni¿ sam spamassassin.
117
118 %package -n perl-Mail-SpamAssassin
119 Summary:        Mail::SpamAssassin - SpamAssassin e-mail filter libraries
120 Summary(pl):    Mail::SpamAssassin - biblioteki filtra poczty SpamAssassin
121 Group:          Development/Languages/Perl
122 Requires:       perl-HTML-Parser >= 3
123
124 %description -n perl-Mail-SpamAssassin
125 Mail::SpamAssassin is a Mail::Audit plugin to identify spam using text
126 analysis and several internet-based realtime blacklists. Using its
127 rule base, it uses a wide range of heuristic tests on mail headers and
128 body text to identify ``spam'', also known as unsolicited commercial
129 email. Once identified, the mail can then be optionally tagged as spam
130 for later filtering using the user's own mail user-agent application.
131
132 %description -n perl-Mail-SpamAssassin -l pl
133 Mail::SpamAssassin jest pluginem dla Mail::Audit, s³u¿±cym do
134 identyfikacji spamu przy u¿yciu analizy zawarto¶ci i/lub internetowych
135 czarnych list. Do zidentyfikowania jako ,,spam'' stosuje szeroki
136 zakres testów heurystycznych na nag³ówkach i tre¶ci, posi³kuj±c siê
137 stworzon± wcze¶niej baz± regu³. Po zidentyfikowaniu, poczta mo¿e byæ
138 oznaczona jako spam w celu pó¼niejszego wyfiltrowania, np. przy u¿yciu
139 aplikacji do czytania poczty.
140
141 %prep
142 %setup -q -n %{pdir}-%{pnam}-%{version}
143 %patch0 -p0
144
145 %build
146 echo "postmaster@localhost" | \
147 %{__perl} Makefile.PL \
148         PREFIX=%{_prefix} \
149         SYSCONFDIR=%{_sysconfdir} \
150         RUN_RAZOR1_TESTS=0 \
151         RUN_RAZOR2_TESTS=0
152 %{__make} OPTIMIZE="%{rpmcflags}"
153
154 %{?with_tests:%{__make} test}
155
156 %install
157 rm -rf $RPM_BUILD_ROOT
158 install -d $RPM_BUILD_ROOT{/etc/{sysconfig,rc.d/init.d},%{_sysconfdir}/mail/spamassassin}
159
160 %{__make} install \
161         PREFIX=$RPM_BUILD_ROOT%{_prefix} \
162         INSTALLMAN1DIR=$RPM_BUILD_ROOT%{_mandir}/man1 \
163         INSTALLMAN3DIR=$RPM_BUILD_ROOT%{_mandir}/man3
164
165 install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/spamassassin
166
167 install rules/local.cf $RPM_BUILD_ROOT%{_sysconfdir}/mail/spamassassin
168
169 # shouldn't this script be called `spamd' instead?
170 install spamd/pld-rc-script.sh $RPM_BUILD_ROOT/etc/rc.d/init.d/spamassassin
171
172 rm -f spamd/{*.sh,*.conf,spam*} contrib/snp.tar.gz
173
174 %post spamd
175 /sbin/chkconfig --add spamassassin
176 if [ -f /var/lock/subsys/spamd ]; then
177         /etc/rc.d/init.d/spamassassin restart 1>&2
178 else
179         echo 'Run "/etc/rc.d/init.d/spamassassin start" to start the spamd daemon.'
180 fi
181
182 %preun spamd
183 if [ "$1" = "0" ]; then
184         if [ -f /var/lock/subsys/spamd ]; then
185                 /etc/rc.d/init.d/spamassassin stop 1>&2
186         fi
187         /sbin/chkconfig --del spamassassin
188 fi
189
190 %clean
191 rm -rf $RPM_BUILD_ROOT
192
193 %files
194 %defattr(644,root,root,755)
195 %doc BUGS Changes COPYRIGHT INSTALL README TRADEMARK USAGE
196 %doc procmailrc.example
197 %attr(755,root,root) %{_bindir}/sa-learn
198 %attr(755,root,root) %{_bindir}/spamassassin
199 %{_mandir}/man1/sa-learn*
200 %{_mandir}/man1/spamassassin*
201
202 %files tools
203 %defattr(644,root,root,755)
204 %doc sql tools masses contrib
205
206 %files spamd
207 %defattr(644,root,root,755)
208 %doc spamd/*
209 %attr(754,root,root) /etc/rc.d/init.d/spamassassin
210 %attr(600,root,root) %config(noreplace) /etc/sysconfig/spamassassin
211 %attr(755,root,root) %{_bindir}/spamd
212 %{_mandir}/man1/spamd*
213
214 %files spamc
215 %defattr(644,root,root,755)
216 %attr(755,root,root) %{_bindir}/spamc
217 %{_mandir}/man1/spamc*
218
219 %files -n perl-Mail-SpamAssassin
220 %defattr(644,root,root,755)
221 %doc sample-nonspam.txt sample-spam.txt
222 %dir %{_sysconfdir}/mail/spamassassin
223 %config(noreplace) %{_sysconfdir}/mail/spamassassin/*
224 %dir %{_datadir}/spamassassin
225 %config(noreplace) %{_datadir}/spamassassin/*
226 %{perl_sitelib}/Mail/*
227 %{_mandir}/man3/*
This page took 0.047178 seconds and 4 git commands to generate.