init package
This commit is contained in:
parent
4a68f027c2
commit
6b1e9b5ffb
BIN
Sub-Name-0.21.tar.gz
Normal file
BIN
Sub-Name-0.21.tar.gz
Normal file
Binary file not shown.
65
perl-Sub-Name.spec
Normal file
65
perl-Sub-Name.spec
Normal file
@ -0,0 +1,65 @@
|
|||||||
|
Name: perl-Sub-Name
|
||||||
|
Version: 0.21
|
||||||
|
Release: 9
|
||||||
|
Summary: (Re)name a sub
|
||||||
|
License: GPL+ or Artistic
|
||||||
|
URL: https://metacpan.org/release/Sub-Name
|
||||||
|
Source0: https://cpan.metacpan.org/authors/id/E/ET/ETHER/Sub-Name-%{version}.tar.gz
|
||||||
|
|
||||||
|
BuildRequires: coreutils, findutils, perl-interpreter, perl-devel, perl-generators
|
||||||
|
BuildRequires: perl(ExtUtils::MakeMaker), perl(Exporter) >= 5.57, perl(strict)
|
||||||
|
BuildRequires: perl(warnings), perl(XSLoader), perl(B), perl(B::Deparse), perl(Carp)
|
||||||
|
BuildRequires: perl(feature), perl(File::Spec), perl(if), perl(Test::More) >= 0.88
|
||||||
|
BuildRequires: perl(CPAN::Meta) >= 2.120900, perl(Devel::CheckBin)
|
||||||
|
Requires: perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version))
|
||||||
|
|
||||||
|
%description
|
||||||
|
This module has only one function, which is also exported by default:
|
||||||
|
subname NAME, CODEREF
|
||||||
|
|
||||||
|
Assigns a new name to referenced sub. If package specification is
|
||||||
|
omitted in the name, then the current package is used. The return
|
||||||
|
value is the sub.
|
||||||
|
|
||||||
|
The name is only used for informative routines (caller, Carp, etc).
|
||||||
|
You won't be able to actually invoke the sub by the given name.
|
||||||
|
To allow that, you need to do glob-assignment yourself.
|
||||||
|
|
||||||
|
Note that for anonymous closures (subs that reference lexicals declared
|
||||||
|
outside the sub itself) you can name each instance of the closure differently,
|
||||||
|
which can be very useful for debugging.
|
||||||
|
|
||||||
|
%package help
|
||||||
|
Summary: man files for %{name}
|
||||||
|
Requires: man
|
||||||
|
|
||||||
|
%description help
|
||||||
|
This package includes man files for %{name}.
|
||||||
|
|
||||||
|
%prep
|
||||||
|
%autosetup -n Sub-Name-%{version} -p1
|
||||||
|
|
||||||
|
%build
|
||||||
|
perl Makefile.PL INSTALLDIRS=vendor optimize="%{optflags}"
|
||||||
|
%make_build
|
||||||
|
|
||||||
|
%install
|
||||||
|
make pure_install DESTDIR=$RPM_BUILD_ROOT NO_PACKLIST=1
|
||||||
|
find $RPM_BUILD_ROOT -type f -name '*.bs' -empty -delete
|
||||||
|
%{_fixperms} $RPM_BUILD_ROOT
|
||||||
|
|
||||||
|
%check
|
||||||
|
make test
|
||||||
|
|
||||||
|
%files
|
||||||
|
%license LICENCE
|
||||||
|
%doc CONTRIBUTING README
|
||||||
|
%{perl_vendorarch}/auto/Sub/
|
||||||
|
%{perl_vendorarch}/Sub/
|
||||||
|
|
||||||
|
%files help
|
||||||
|
%{_mandir}/man*/*
|
||||||
|
|
||||||
|
%changelog
|
||||||
|
* Sat Jan 11 2020 openEuler Buildteam <buildteam@openeuler.org> - 0.21-9
|
||||||
|
- Package init
|
||||||
Loading…
x
Reference in New Issue
Block a user