]>
Commit | Line | Data |
---|---|---|
5d1de8ff MP |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without tests # do not perform "make test" | |
4 | # | |
5d1de8ff MP |
5 | %define pdir Sub |
6 | %define pnam Exporter | |
7 | Summary: Sub::Exporter - a sophisticated exporter for custom-built routines | |
daa6e392 | 8 | Summary(pl.UTF-8): Sub::Exporter - wymyślny eksporter dla własnych funkcji |
5d1de8ff | 9 | Name: perl-Sub-Exporter |
95478d63 | 10 | Version: 0.988 |
5d1de8ff MP |
11 | Release: 1 |
12 | # same as perl | |
13 | License: GPL v1+ or Artistic | |
14 | Group: Development/Languages/Perl | |
daa6e392 | 15 | Source0: http://www.cpan.org/modules/by-module/Sub/%{pdir}-%{pnam}-%{version}.tar.gz |
95478d63 | 16 | # Source0-md5: 9ccc63fd0f1d77e3e1a24bec07e05638 |
daa6e392 | 17 | URL: http://search.cpan.org/dist/Sub-Exporter/ |
803e166c | 18 | BuildRequires: perl-ExtUtils-MakeMaker >= 6.30 |
5d1de8ff MP |
19 | BuildRequires: perl-devel >= 1:5.8.0 |
20 | BuildRequires: rpm-perlprov >= 4.1-13 | |
21 | %if %{with tests} | |
803e166c | 22 | BuildRequires: perl-Data-OptList >= 0.100 |
7e688036 | 23 | BuildRequires: perl-Package-Generator |
daa6e392 JB |
24 | BuildRequires: perl-Params-Util >= 0.14 |
25 | BuildRequires: perl-Sub-Install >= 0.92 | |
12d2d960 | 26 | BuildRequires: perl-Test-Simple >= 0.96 |
5d1de8ff MP |
27 | %endif |
28 | BuildArch: noarch | |
29 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
30 | ||
31 | %description | |
5d1de8ff MP |
32 | The biggest benefit of Sub::Exporter over existing exporters |
33 | (including the ubiquitous Exporter.pm) is its ability to build new | |
34 | coderefs for export, rather than to simply export code identical to | |
35 | that found in the exporting package. | |
36 | ||
daa6e392 JB |
37 | %description -l pl.UTF-8 |
38 | Największą zaletą modułu Sub::Exporter w stosunku do istniejących | |
39 | wcześniej eksporterów (wraz z wszechobecnym Exporter.pm) jest | |
40 | możliwość budowania nowych coderefów do exportowania zamiast zwykłego | |
41 | eksportowania kodu identycznego do tego, jaki można znaleźć w | |
42 | eksportowanym pakiecie. | |
5d1de8ff MP |
43 | |
44 | %prep | |
45 | %setup -q -n %{pdir}-%{pnam}-%{version} | |
46 | ||
47 | %build | |
48 | %{__perl} Makefile.PL \ | |
49 | INSTALLDIRS=vendor | |
50 | %{__make} | |
51 | ||
52 | %{?with_tests:%{__make} test} | |
53 | ||
54 | %install | |
55 | rm -rf $RPM_BUILD_ROOT | |
56 | ||
57 | %{__make} install \ | |
58 | DESTDIR=$RPM_BUILD_ROOT | |
59 | ||
7e688036 JB |
60 | # exist as man |
61 | %{__rm} $RPM_BUILD_ROOT%{perl_vendorlib}/Sub/Exporter/*.pod | |
62 | ||
5d1de8ff MP |
63 | %clean |
64 | rm -rf $RPM_BUILD_ROOT | |
65 | ||
66 | %files | |
67 | %defattr(644,root,root,755) | |
68 | %doc Changes README | |
7e688036 | 69 | %{perl_vendorlib}/Sub/Exporter.pm |
2cb7bd19 | 70 | %dir %{perl_vendorlib}/Sub/Exporter |
71 | %{perl_vendorlib}/Sub/Exporter/*.pm | |
7e688036 | 72 | %{_mandir}/man3/Sub::Exporter*.3pm* |