perl-Class-Tiny package init
This commit is contained in:
parent
55cddc984b
commit
e715a020da
BIN
Class-Tiny-1.006.tar.gz
Normal file
BIN
Class-Tiny-1.006.tar.gz
Normal file
Binary file not shown.
59
perl-Class-Tiny.spec
Normal file
59
perl-Class-Tiny.spec
Normal file
@ -0,0 +1,59 @@
|
||||
#%if ! (0%{?rhel})
|
||||
%bcond_without perl_Class_Tiny_enables_optional_test
|
||||
#%else
|
||||
#%bcond_with perl_Class_Tiny_enables_optional_test
|
||||
#%endif
|
||||
Name: perl-Class-Tiny
|
||||
Version: 1.006
|
||||
Release: 1
|
||||
Summary: Minimalist class construction
|
||||
License: ASL 2.0
|
||||
URL: https://metacpan.org/release/Class-Tiny
|
||||
Source0: https://cpan.metacpan.org/authors/id/D/DA/DAGOLDEN/Class-Tiny-%{version}.tar.gz
|
||||
BuildArch: noarch
|
||||
BuildRequires: make perl-generators perl-interpreter perl(:VERSION) >= 5.6
|
||||
BuildRequires: perl(ExtUtils::MakeMaker) >= 6.76 perl(strict) perl(warnings) perl(Carp)
|
||||
BuildRequires: perl(mro) perl(base) perl(Exporter) perl(File::Spec) perl(lib) perl(subs)
|
||||
BuildRequires: perl(Test::More) >= 0.96
|
||||
%if %{with perl_Class_Tiny_enables_optional_test}
|
||||
BuildRequires: perl(Test::FailWarnings)
|
||||
%endif
|
||||
Requires: perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version)) perl(mro)
|
||||
%global __requires_exclude %{?__requires_exclude:%__requires_exclude|}^perl\\(Devel::GlobalDestruction\\)
|
||||
%description
|
||||
This module offers a minimalist class construction kit in around 120 lines
|
||||
of code. Here is a list of features:
|
||||
* defines attributes via import arguments
|
||||
* generates read-write accessors
|
||||
* supports lazy attribute defaults
|
||||
* supports custom accessors
|
||||
* superclass provides a standard new constructor
|
||||
* new takes a hash reference or list of key/value pairs
|
||||
* new has heuristics to catch constructor attribute typos
|
||||
* new calls BUILD for each class from parent to child
|
||||
* superclass provides a DESTROY method
|
||||
* DESTROY calls DEMOLISH for each class from child to parent
|
||||
|
||||
%prep
|
||||
%setup -q -n Class-Tiny-%{version}
|
||||
|
||||
%build
|
||||
perl Makefile.PL INSTALLDIRS=vendor NO_PACKLIST=1
|
||||
make %{?_smp_mflags}
|
||||
|
||||
%install
|
||||
make pure_install DESTDIR=$RPM_BUILD_ROOT
|
||||
%{_fixperms} $RPM_BUILD_ROOT/*
|
||||
|
||||
%check
|
||||
make test
|
||||
|
||||
%files
|
||||
%license LICENSE
|
||||
%doc Changes CONTRIBUTING.mkdn README
|
||||
%{perl_vendorlib}/*
|
||||
%{_mandir}/man3/*
|
||||
|
||||
%changelog
|
||||
* Fri May 14 2021 xxxxxx <xxxxxx@huawei.com> - 1.006-1
|
||||
- package init
|
||||
Loading…
x
Reference in New Issue
Block a user