]> git.pld-linux.org Git - packages/perl-Mail-SpamTest-Bayesian.git/blob - perl-Mail-SpamTest-Bayesian.spec
f639cc618045e464be36480a8baac00a200de9a2
[packages/perl-Mail-SpamTest-Bayesian.git] / perl-Mail-SpamTest-Bayesian.spec
1 #
2 # Conditional build:
3 %bcond_without  tests   # do not perform "make test"
4 #
5 %include        /usr/lib/rpm/macros.perl
6 %define         pdir    Mail
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
11 Version:        0.02
12 Release:        4
13 # same as perl
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
19 %if %{with tests}
20 BuildRequires:  perl(MIME::Parser) >= 5.406
21 BuildRequires:  perl-BerkeleyDB >= 0.17
22 %endif
23 BuildRequires:  rpm-perlprov >= 4.1-13
24 BuildArch:      noarch
25 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
26
27 %description
28 This module implements the Bayesian spam-testing algorithm described
29 by Paul Graham at <http://www.paulgraham.com/spam.html>.
30
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.
36
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>.
40
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.
47
48 %prep
49 %setup -q -n %{pdir}-%{pnam}-%{version}
50
51 %build
52 %{__perl} Makefile.PL \
53         INSTALLDIRS=vendor
54 %{__make}
55
56 %{?with_tests:%{__make} test}
57
58 %install
59 rm -rf $RPM_BUILD_ROOT
60
61 %{__make} install \
62         DESTDIR=$RPM_BUILD_ROOT
63
64 %clean
65 rm -rf $RPM_BUILD_ROOT
66
67 %files
68 %defattr(644,root,root,755)
69 %doc Change* README
70 %dir %{perl_vendorlib}/Mail/SpamTest
71 %{perl_vendorlib}/Mail/SpamTest/*.pm
72 %{_mandir}/man3/*
This page took 0.049355 seconds and 2 git commands to generate.