]>
Commit | Line | Data |
---|---|---|
2d7a8fae ER |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without tests # do not perform "make test" | |
4 | ||
5 | %define pdir ExtUtils | |
6 | %define pnam MakeMaker-CPANfile | |
2d7a8fae ER |
7 | Summary: CPANfile support for ExtUtils::MakeMaker |
8 | Name: perl-ExtUtils-MakeMaker-CPANfile | |
9 | Version: 0.06 | |
10 | Release: 1 | |
11 | License: GPL+ or Artistic | |
12 | Group: Development/Libraries | |
13 | Source0: http://www.cpan.org/modules/by-module/%{pdir}/%{pdir}-%{pnam}-%{version}.tar.gz | |
14 | # Source0-md5: 8e1a42d67b57ed15e08e25872dd84cac | |
15 | URL: http://search.cpan.org/dist/ExtUtils-MakeMaker-CPANfile/ | |
16 | BuildRequires: perl(ExtUtils::MakeMaker) >= 6.17 | |
17 | BuildRequires: perl(version) >= 0.76 | |
18 | BuildRequires: perl-Module-CPANfile | |
19 | BuildRequires: rpm-perlprov >= 4.1-13 | |
20 | %if %{with tests} | |
21 | BuildRequires: perl(Test::More) >= 0.88 | |
22 | %endif | |
23 | Requires: perl(ExtUtils::MakeMaker) >= 6.17 | |
24 | Requires: perl(version) >= 0.76 | |
25 | BuildArch: noarch | |
26 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
27 | ||
28 | %description | |
29 | ExtUtils::MakeMaker::CPANfile loads cpanfile in your distribution and | |
30 | modifies parameters for WriteMakefile in your Makefile.PL. Just use it | |
31 | instead of ExtUtils::MakeMaker (which should be loaded internally), | |
32 | and prepare cpanfile. | |
33 | ||
34 | %prep | |
35 | %setup -q -n %{pdir}-%{pnam}-%{version} | |
36 | ||
37 | %build | |
38 | %{__perl} Makefile.PL \ | |
39 | INSTALLDIRS=vendor | |
40 | %{?with_tests:%{__make} test} | |
41 | ||
42 | %install | |
43 | rm -rf $RPM_BUILD_ROOT | |
44 | %{__make} pure_install \ | |
45 | DESTDIR=$RPM_BUILD_ROOT | |
46 | ||
47 | find $RPM_BUILD_ROOT -type f -name .packlist | xargs rm | |
48 | ||
49 | %check | |
50 | make test | |
51 | ||
52 | %clean | |
53 | rm -rf $RPM_BUILD_ROOT | |
54 | ||
55 | %files | |
56 | %defattr(644,root,root,755) | |
57 | %doc Changes LICENSE README.md | |
54302f40 ER |
58 | %dir %{perl_vendorlib}/ExtUtils/MakeMaker |
59 | %{perl_vendorlib}/ExtUtils/MakeMaker/CPANfile.pm | |
60 | %{_mandir}/man3/ExtUtils::MakeMaker::CPANfile.3pm* |