]> git.pld-linux.org Git - packages/perl-Regexp-Tr.git/blob - perl-Regexp-Tr.spec
e93acd4dbe92a1fc226cb9705112f2bf3aacf30a
[packages/perl-Regexp-Tr.git] / perl-Regexp-Tr.spec
1 #
2 # Conditional build:
3 %bcond_without  tests   # do not perform "make test"
4 #
5 %include        /usr/lib/rpm/macros.perl
6 %define         pdir    Regexp
7 %define         pnam    Tr
8 Summary:        Regexp::Tr - run-time-compiled tr/// objects
9 Summary(pl.UTF-8):      Regexp::Tr - obiekty tr/// kompilowane w czasie wykonywania
10 Name:           perl-Regexp-Tr
11 Version:        0.05
12 Release:        2
13 # same as perl
14 License:        GPL v1+ or Artistic
15 Group:          Development/Languages/Perl
16 Source0:        http://www.cpan.org/modules/by-module/%{pdir}/%{pdir}-%{pnam}-%{version}.tar.gz
17 # Source0-md5:  1c01cb427ae8cfeba5d92fb392336510
18 BuildRequires:  perl-devel >= 1:5.8.0
19 BuildRequires:  rpm-perlprov >= 4.1-13
20 BuildArch:      noarch
21 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
22
23 %description
24 One very useful ability of Perl is to do relatively cheap
25 transliteration via the tr/// regex operator. Unfortunately, Perl
26 requires tr/// to be known at compile-time. The common solution has
27 been to put an eval around any dynamic tr/// operations, but that is
28 very expensive to be used often (for instance, within a loop). This
29 module solves that problem by compiling the tr/// a single time and
30 allowing the user to use it repeatedly and delete it when it it no
31 longer useful.
32
33 %description -l pl.UTF-8
34 Jedna z bardzo przydatnych możliwości Perla to w miarę tania zamiana
35 znaków przez operator tr///. Niestety Perl wymaga, aby tr/// było
36 znane w czasie kompilacji. Popularne rozwiązanie to otoczenie przez
37 eval wszystkich dynamicznych operacji tr///, ale ma to bardzo duży
38 narzut czasowy, jeśli jest używane często (na przykład w pętli). Ten
39 moduł rozwiązuje problem poprzez kompilowanie wyrażenia tr/// jeden
40 raz, a następnie pozwolenie użytkownikowi na wielokrotne używanie go
41 i usunięcie, kiedy przestaje być potrzebne.
42
43 %prep
44 %setup -q -n %{pdir}-%{pnam}-%{version}
45
46 %build
47 %{__perl} Makefile.PL \
48         INSTALLDIRS=vendor
49 %{__make}
50
51 %{?with_tests:%{__make} test}
52
53 %install
54 rm -rf $RPM_BUILD_ROOT
55
56 %{__make} install \
57         DESTDIR=$RPM_BUILD_ROOT
58
59 %clean
60 rm -rf $RPM_BUILD_ROOT
61
62 %files
63 %defattr(644,root,root,755)
64 %doc README
65 %{perl_vendorlib}/Regexp/Tr.pm
66 %{_mandir}/man3/*
This page took 0.625413 seconds and 2 git commands to generate.