]>
Commit | Line | Data |
---|---|---|
279bcb8c | 1 | # |
2 | # Conditional build: | |
3 | %bcond_without tests # do not perform "make test" | |
721761e8 | 4 | |
279bcb8c | 5 | %define pdir CGI |
6 | %define pnam Compile | |
7 | %include /usr/lib/rpm/macros.perl | |
8 | Summary: CGI::Compile - Compile .cgi scripts to a code reference like ModPerl::Registry | |
279bcb8c | 9 | Name: perl-CGI-Compile |
3d9b7143 | 10 | Version: 0.15 |
279bcb8c | 11 | Release: 1 |
12 | # same as perl | |
13 | License: GPL v1+ or Artistic | |
14 | Group: Development/Languages/Perl | |
15 | Source0: http://www.cpan.org/modules/by-module/CGI/%{pdir}-%{pnam}-%{version}.tar.gz | |
3d9b7143 | 16 | # Source0-md5: 2fcf4bc473107130229f4e0a98c756ce |
721761e8 | 17 | URL: http://search.cpan.org/dist/CGI-Compile/ |
279bcb8c | 18 | BuildRequires: perl-devel >= 1:5.8.0 |
19 | BuildRequires: rpm-perlprov >= 4.1-13 | |
20 | %if %{with tests} | |
21 | BuildRequires: perl(File::pushd) | |
22 | BuildRequires: perl(Test::NoWarnings) | |
23 | BuildRequires: perl-Test-Requires | |
24 | %endif | |
25 | BuildArch: noarch | |
26 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
27 | ||
28 | %description | |
29 | CGI::Compile is an utility to compile CGI scripts into a code | |
30 | reference that can run many times on its own namespace, as long as the | |
31 | script is ready to run on a persistent environment. | |
32 | ||
3d9b7143 | 33 | NOTE: for best results, load CGI::Compile before any modules used by |
34 | your CGIs. | |
279bcb8c | 35 | |
279bcb8c | 36 | %prep |
37 | %setup -q -n %{pdir}-%{pnam}-%{version} | |
38 | ||
39 | %build | |
40 | %{__perl} Makefile.PL \ | |
41 | INSTALLDIRS=vendor | |
42 | %{__make} | |
43 | ||
44 | %{?with_tests:%{__make} test} | |
45 | ||
46 | %install | |
47 | rm -rf $RPM_BUILD_ROOT | |
48 | ||
49 | %{__make} pure_install \ | |
50 | DESTDIR=$RPM_BUILD_ROOT | |
51 | ||
52 | %clean | |
53 | rm -rf $RPM_BUILD_ROOT | |
54 | ||
55 | %files | |
56 | %defattr(644,root,root,755) | |
57 | %doc Changes README | |
58 | %{perl_vendorlib}/CGI/*.pm | |
59 | %{_mandir}/man3/* |