]> git.pld-linux.org Git - SPECS.git/blob - perl-Sub-Name.spec
SPECS updated Mon 29 Apr 22:05:02 CEST 2024
[SPECS.git] / perl-Sub-Name.spec
1 #
2 # Conditional build:
3 %bcond_without  tests   # unit tests
4 #
5 %define pdir    Sub
6 %define pnam    Name
7 Summary:        Sub::Name - (re)name a sub
8 Summary(pl.UTF-8):      Sub::Name - nazwanie/zmiana nazwy podprogramu
9 Name:           perl-Sub-Name
10 Version:        0.27
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/Sub/%{pdir}-%{pnam}-%{version}.tar.gz
16 # Source0-md5:  c7f7c5fce6f9a3575dc3ffdd519b3911
17 URL:            https://metacpan.org/dist/Sub-Name
18 BuildRequires:  perl-ExtUtils-MakeMaker
19 %if %{with tests}
20 BuildRequires:  perl(Exporter) >= 5.57
21 BuildRequires:  perl-Devel-CheckBin
22 BuildRequires:  perl-Test-Simple >= 0.88
23 %endif
24 BuildRequires:  perl-devel >= 1:5.8.0
25 BuildRequires:  rpm-perlprov >= 4.1-13
26 BuildRequires:  rpmbuild(macros) >= 1.745
27 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
28
29 %description
30 This module has only one function, which is also exported by default:
31
32 Assigns a new name to referenced sub. If package specification is
33 omitted in the name, then the current package is used. The return
34 value is the sub.
35
36 %description -l pl.UTF-8
37 Ten moduł ma tylko jedną funkcję, eksportowaną domyślnie. Przypisuje
38 ona nową nazwę do wskazanego podprogramu. Jeśli specyfikacja pakietu
39 została pominięta w nazwie, użyty jest pakiet bieżący. Wartością
40 zwracaną jset podprogram.
41
42 %prep
43 %setup -q -n %{pdir}-%{pnam}-%{version}
44
45 %build
46 %{__perl} Makefile.PL \
47         INSTALLDIRS=vendor
48 %{__make} \
49         CC="%{__cc}" \
50         OPTIMIZE="%{rpmcflags}"
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
60 %clean
61 rm -rf $RPM_BUILD_ROOT
62
63 %files
64 %defattr(644,root,root,755)
65 %doc Changes README
66 %{perl_vendorarch}/Sub/Name.pm
67 %dir %{perl_vendorarch}/auto/Sub/Name
68 %attr(755,root,root) %{perl_vendorarch}/auto/Sub/Name/Name.so
69 %{_mandir}/man3/Sub::Name.3pm*
This page took 0.20559 seconds and 3 git commands to generate.