summaryrefslogtreecommitdiff
path: root/perl-MIME-tools.spec
blob: 511de38f52a79f157219ac9f22ec508e50b0358a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
#
# Conditional build:
%bcond_without	tests	# do not perform "make test"
#
%define		pdir	MIME
%define		pnam	tools
Summary:	MIME::tools - modules for parsing (and creating!) MIME entities
Summary(pl.UTF-8):	MIME::tools - zestaw modułów do operacji na danych w formacie MIME
Name:		perl-MIME-tools
Version:	5.510
Release:	1
# same as perl
License:	GPL v1+ or Artistic
Group:		Development/Languages/Perl
Source0:	http://www.cpan.org/modules/by-module/MIME/%{pdir}-%{pnam}-%{version}.tar.gz
# Source0-md5:	5f79177746057c8254246f4401ae2411
URL:		http://search.cpan.org/dist/MIME-tools/
BuildRequires:	perl-devel >= 1:5.8.0
%if %{with tests}
BuildRequires:	perl(File::Path) >= 1
BuildRequires:	perl(File::Spec) >= 0.6
BuildRequires:	perl(IO::File) >= 1.13
BuildRequires:	perl-File-Temp >= 0.18
BuildRequires:	perl-MIME-Base64 >= 2.20
BuildRequires:	perl-MailTools >= 1.05
BuildRequires:	perl-Test-Deep
%endif
BuildRequires:	rpm-perlprov >= 4.1-13
BuildRequires:	rpmbuild(macros) >= 1.663
Requires:	perl-MailTools >= 1.05
BuildArch:	noarch
BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)

# optional
%define		_noautoreq_perl	Convert::BinHex

%description
MIME-tools is a collection of Perl5 MIME:: modules for parsing,
decoding and generating single- or multipart (even nested multipart)
MIME messages. (Yes, kids, that means you can send messages with
attached GIF files).

%description -l pl.UTF-8
MIME::tools to zestaw modułów MIME:: dla Perla 5 do analizy,
dekodowania oraz tworzenia jedno- i wieloczęściowych (a nawet
zagnieżdżonych wieloczęściowych) wiadomości MIME (tak, to znaczy, że
można wysyłać wiadomości z dołączonymi plikami GIF).

%prep
%setup -q -n %{pdir}-%{pnam}-%{version}

%build
%{__perl} Makefile.PL \
	INSTALLDIRS=vendor
%{__make}

%{?with_tests:%{__make} test}

%install
rm -rf $RPM_BUILD_ROOT
install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}

%{__make} install \
	DESTDIR=$RPM_BUILD_ROOT

install examples/* $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
rm -f $RPM_BUILD_ROOT%{perl_vendorarch}/auto/MIME-tools/.packlist

%clean
rm -rf $RPM_BUILD_ROOT

%files
%defattr(644,root,root,755)
%doc README*
%{perl_vendorlib}/MIME/Body.pm
%{perl_vendorlib}/MIME/Decoder.pm
%{perl_vendorlib}/MIME/Entity.pm
%{perl_vendorlib}/MIME/Head.pm
%{perl_vendorlib}/MIME/Parser.pm
%{perl_vendorlib}/MIME/Tools.pm
%{perl_vendorlib}/MIME/WordDecoder.pm
%{perl_vendorlib}/MIME/Words.pm
%{perl_vendorlib}/MIME/Decoder
%{perl_vendorlib}/MIME/Field
%{perl_vendorlib}/MIME/Parser
%{_mandir}/man3/MIME::Body.3pm*
%{_mandir}/man3/MIME::Decoder*.3pm*
%{_mandir}/man3/MIME::Entity.3pm*
%{_mandir}/man3/MIME::Field::*.3pm*
%{_mandir}/man3/MIME::Head.3pm*
%{_mandir}/man3/MIME::Parser*.3pm*
%{_mandir}/man3/MIME::Tools.3pm*
%{_mandir}/man3/MIME::WordDecoder.3pm*
%{_mandir}/man3/MIME::Words.3pm*
%{_examplesdir}/%{name}-%{version}