]>
Commit | Line | Data |
---|---|---|
06750394 AM |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without tests # do not perform "make test" | |
4 | # | |
5 | %define pdir POSIX | |
6 | %define pnam strftime-Compiler | |
7 | %include /usr/lib/rpm/macros.perl | |
8 | Summary: POSIX::strftime::Compiler - GNU C library compatible strftime for loggers and servers | |
9 | Name: perl-POSIX-strftime-Compiler | |
10 | Version: 0.42 | |
751a225f | 11 | Release: 2 |
06750394 AM |
12 | # same as perl |
13 | License: GPL v1+ or Artistic | |
14 | Group: Development/Languages/Perl | |
15 | Source0: http://www.cpan.org/modules/by-module/POSIX/%{pdir}-%{pnam}-%{version}.tar.gz | |
16 | # Source0-md5: c0a5f76b1b0ce9cdb90d627b017e6cf5 | |
17 | URL: https://metacpan.org/release/POSIX-strftime-Compiler/ | |
18 | BuildRequires: perl-Module-Build | |
19 | BuildRequires: perl-devel >= 1:5.8.0 | |
20 | BuildRequires: rpm-perlprov >= 4.1-13 | |
21 | %if %{with tests} | |
22 | %endif | |
23 | BuildArch: noarch | |
24 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
25 | ||
26 | %description | |
27 | POSIX::strftime::Compiler provides GNU C library compatible strftime(3). But this module will not affected | |
28 | by the system locale. This feature is useful when you want to write loggers, servers and portable applications. | |
29 | ||
30 | For generate same result strings on any locale, POSIX::strftime::Compiler wraps POSIX::strftime and | |
31 | converts some format characters to perl code | |
32 | ||
33 | %prep | |
34 | %setup -q -n %{pdir}-%{pnam}-%{version} | |
35 | ||
36 | %build | |
37 | %{__perl} Build.PL \ | |
38 | destdir=$RPM_BUILD_ROOT \ | |
39 | installdirs=vendor | |
40 | ./Build | |
41 | ||
42 | %{?with_tests:./Build test} | |
43 | ||
44 | %install | |
45 | rm -rf $RPM_BUILD_ROOT | |
46 | ||
47 | ./Build install | |
48 | ||
49 | install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version} | |
50 | cp -a eg $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version} | |
51 | ||
52 | %clean | |
53 | rm -rf $RPM_BUILD_ROOT | |
54 | ||
55 | %files | |
56 | %defattr(644,root,root,755) | |
57 | %doc Changes | |
751a225f AM |
58 | %{perl_vendorlib}/POSIX/strftime |
59 | %{_mandir}/man3/POSIX::strftime::Compiler.3* | |
06750394 | 60 | %{_examplesdir}/%{name}-%{version} |