3 %bcond_without tests # do not perform "make test"
5 %include /usr/lib/rpm/macros.perl
7 %define pnam SpamTest-Bayesian
8 Summary: Mail::SpamTest::Bayesian - Perl extension for Bayesian spam-testing
9 Summary(pl.UTF-8): Mail::SpamTest::Bayesian - rozszerzenie Perla do wykrywania spamu metodą bayesowską
10 Name: perl-Mail-SpamTest-Bayesian
14 License: GPL v1+ or Artistic
15 Group: Development/Languages/Perl
16 Source0: http://www.cpan.org/modules/by-module/%{pdir}/%{pdir}-%{pnam}-%{version}.tar.gz
17 # Source0-md5: b3656a57490c6ff342ba180da3ec9762
18 BuildRequires: perl-devel >= 1:5.8.0
20 BuildRequires: perl(MIME::Parser) >= 5.406
21 BuildRequires: perl-BerkeleyDB >= 0.17
23 BuildRequires: rpm-perlprov >= 4.1-13
25 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
28 This module implements the Bayesian spam-testing algorithm described
29 by Paul Graham at <http://www.paulgraham.com/spam.html>.
31 In short: the system is trained by exposure to mailboxes of known spam
32 and non-spam messages. These are (1) MIME-decoded, and non-text parts
33 deleted; (2) tokenised. The database files spam.db and nonspam.db
34 contain lists of tokens and the number of messages in which they have
35 occurred; general.db holds a message count.
37 %description -l pl.UTF-8
38 Ten moduł jest implementacją bayesowskiego algorytmu wykrywania spamu
39 opisanego przez Paula Grahama w <http://www.paulgraham.com/spam.html>.
41 W skrócie: system jest uczony poprzez przedstawianie skrzynek z
42 wiadomościami, o których wiadomo, że zawierają spam lub go nie
43 zawierają. Są one (1) zakodowane MIME, z usuniętymi częściami
44 nietekstowymi; (2) ztokenizowane. Pliki baz danych spam.db i
45 nonspam.db zawierają listy tokenów i liczby wiadomości, w których
46 wystąpiły; general.db przechowuje liczbę wiadomości.
49 %setup -q -n %{pdir}-%{pnam}-%{version}
52 %{__perl} Makefile.PL \
56 %{?with_tests:%{__make} test}
59 rm -rf $RPM_BUILD_ROOT
62 DESTDIR=$RPM_BUILD_ROOT
65 rm -rf $RPM_BUILD_ROOT
68 %defattr(644,root,root,755)
70 %dir %{perl_vendorlib}/Mail/SpamTest
71 %{perl_vendorlib}/Mail/SpamTest/*.pm