1 |
%define upstream_name File-Temp |
2 |
%define upstream_version 0.22 |
3 |
|
4 |
Name: perl-%{upstream_name} |
5 |
Version: %perl_convert_version %{upstream_version} |
6 |
Release: %mkrel 2 |
7 |
|
8 |
Summary: Return name and handle of a temporary file safely |
9 |
License: GPL+ or Artistic |
10 |
Group: Development/Perl |
11 |
URL: http://search.cpan.org/dist/%{upstream_name} |
12 |
Source0: http://www.cpan.org/modules/by-module/File/%{upstream_name}-%{upstream_version}.tar.gz |
13 |
|
14 |
Buildarch: noarch |
15 |
|
16 |
|
17 |
%description |
18 |
File::Temp can be used to create and open temporary files in a safe way. There |
19 |
is both a function interface and an object-oriented interface. The File::Temp |
20 |
constructor or the tempfile() function can be used to return the name and the |
21 |
open filehandle of a temporary file. The tempdir() function can be used to |
22 |
create a temporary directory. |
23 |
|
24 |
%prep |
25 |
%setup -q -n %{upstream_name}-%{upstream_version} |
26 |
|
27 |
%build |
28 |
%{__perl} Makefile.PL INSTALLDIRS=vendor |
29 |
%make CFLAGS="%{optflags}" |
30 |
|
31 |
%install |
32 |
rm -rf %{buildroot} |
33 |
%makeinstall_std |
34 |
|
35 |
mv %{buildroot}%{_mandir}/man3/File::Temp.3pm \ |
36 |
%{buildroot}%{_mandir}/man3/File::Temp-%{upstream_version}.3pm |
37 |
|
38 |
%check |
39 |
%__make test |
40 |
|
41 |
%clean |
42 |
rm -rf %{buildroot} |
43 |
|
44 |
%files |
45 |
%defattr(-,root,root) |
46 |
%doc ChangeLog README META.yml |
47 |
%{perl_vendorlib}/File |
48 |
%{_mandir}/*/* |