]>
Commit | Line | Data |
---|---|---|
d4c252b3 JB |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without tests # do not perform "make test" | |
4 | # | |
5 | %include /usr/lib/rpm/macros.perl | |
0c0ad801 | 6 | %define pdir Mail |
7 | %define pnam RFC822-Address | |
d4c252b3 | 8 | Summary: Mail::RFC822::Address - validating email addresses according to RFC822 |
24d32da1 | 9 | Summary(pl.UTF-8): Mail::RFC822::Address - sprawdzanie poprawności adresów e-mail wg RFC822 |
d4c252b3 JB |
10 | Name: perl-Mail-RFC822-Address |
11 | Version: 0.3 | |
12 | Release: 1 | |
13 | License: BSD-like | |
14 | Group: Development/Languages/Perl | |
15 | Source0: http://www.cpan.org/modules/by-module/%{pdir}/%{pdir}-%{pnam}-%{version}.tar.gz | |
16 | # Source0-md5: 0bd88b2ffedd95a4a920053fd6d0b709 | |
17 | BuildRequires: perl-devel >= 1:5.8.0 | |
18 | BuildRequires: rpm-perlprov >= 4.1-13 | |
19 | BuildArch: noarch | |
20 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
21 | ||
22 | %description | |
23 | Mail::RFC822::Address validates email addresses against the grammar | |
24 | described in RFC 822 using regular expressions. How to validate a user | |
25 | supplied email address is a FAQ (see perlfaq9): the only sure way to | |
26 | see if a supplied email address is genuine is to send an email to it | |
27 | and see if the user recieves it. The one useful check that can be | |
28 | performed on an address is to check that the email address is | |
29 | syntactically valid. That is what this module does. | |
30 | ||
31 | This module is functionally equivalent to RFC::RFC822::Address, but | |
32 | uses regular expressions rather than the Parse::RecDescent parser. | |
33 | This means that startup time is greatly reduced making it suitable for | |
34 | use in transient scripts such as CGI scripts. | |
35 | ||
3b6c4917 JR |
36 | %description -l pl.UTF-8 |
37 | Mail::RFC822::Address sprawdza poprawność adresów e-mail wg gramatyki | |
38 | opisanej w RFC 822 przy użyciu wyrażeń regularnych. Sposób sprawdzenia | |
39 | poprawności adresu e-mail podanego przez użytkownika jest w FAQ | |
d4c252b3 | 40 | (perlfaq9): jedynym sposobem sprawdzenia, czy podany adres jest |
3b6c4917 JR |
41 | prawdziwy jest wysłanie na niego wiadomości i sprawdzenie, czy |
42 | użytkownik ją otrzyma. Jedyny użyteczny test który można wykonać na | |
d4c252b3 | 43 | adresie to sprawdzenie, czy adres jest poprawny syntaktycznie - i to |
3b6c4917 | 44 | właśnie robi moduł. |
d4c252b3 | 45 | |
3b6c4917 JR |
46 | Ten moduł jest funkcjonalnie równoważny RFC::RFC822::Address, ale |
47 | używa wyrażeń regularnych zamiast analizatora Parse::RecDescent. | |
48 | Oznacza to znaczne zmniejszenie czasu ładowania, co czyni moduł | |
49 | przydatnym do używania w skryptach np. CGI. | |
d4c252b3 JB |
50 | |
51 | %prep | |
52 | %setup -q -n %{pdir}-%{pnam}-%{version} | |
53 | ||
54 | %build | |
55 | %{__perl} Makefile.PL \ | |
56 | INSTALLDIRS=vendor | |
57 | ||
58 | %{__make} | |
59 | ||
60 | %{?with_tests:%{__make} test} | |
61 | ||
62 | %install | |
63 | rm -rf $RPM_BUILD_ROOT | |
64 | ||
65 | %{__make} install \ | |
66 | DESTDIR=$RPM_BUILD_ROOT | |
67 | ||
68 | %clean | |
69 | rm -rf $RPM_BUILD_ROOT | |
70 | ||
71 | %files | |
72 | %defattr(644,root,root,755) | |
73 | %doc Changes | |
74 | %{perl_vendorlib}/Mail/RFC822 | |
75 | %{_mandir}/man3/* |