1 | # Run optional tests
|
---|
2 | #%{bcond_without perl_Class_Method_Modifiers_enables_optional_test}
|
---|
3 |
|
---|
4 | Name: perl-Class-Method-Modifiers
|
---|
5 | Summary: Provides Moose-like method modifiers
|
---|
6 | Version: 2.12
|
---|
7 | Release: 1%{?dist}
|
---|
8 | License: GPL+ or Artistic
|
---|
9 | Vendor: bww bitwise works GmbH
|
---|
10 | URL: http://search.cpan.org/dist/Class-Method-Modifiers
|
---|
11 | Source0: http://search.cpan.org/CPAN/authors/id/E/ET/ETHER/Class-Method-Modifiers-%{version}.tar.gz
|
---|
12 | BuildArch: noarch
|
---|
13 | # Module Build
|
---|
14 | BuildRequires: coreutils
|
---|
15 | BuildRequires: findutils
|
---|
16 | BuildRequires: make
|
---|
17 | #BuildRequires: perl-interpreter
|
---|
18 | BuildRequires: perl-generators
|
---|
19 | BuildRequires: perl(ExtUtils::MakeMaker)
|
---|
20 | BuildRequires: perl(strict)
|
---|
21 | BuildRequires: perl(warnings)
|
---|
22 | # Module Runtime
|
---|
23 | BuildRequires: perl(B)
|
---|
24 | BuildRequires: perl(base)
|
---|
25 | BuildRequires: perl(Carp)
|
---|
26 | BuildRequires: perl(Exporter)
|
---|
27 | # Test Suite
|
---|
28 | #BuildRequires: perl(File::Spec)
|
---|
29 | #BuildRequires: perl(if)
|
---|
30 | #BuildRequires: perl(Test::Fatal)
|
---|
31 | #BuildRequires: perl(Test::More) >= 0.88
|
---|
32 | #BuildRequires: perl(Test::Requires)
|
---|
33 | # Optional Test Requirements
|
---|
34 | #%if 0%{!?perl_bootstrap:1} && %{with perl_Class_Method_Modifiers_enables_optional_test}
|
---|
35 | #BuildRequires: perl(CPAN::Meta) >= 2.120900
|
---|
36 | #BuildRequires: perl(Moose)
|
---|
37 | #%endif
|
---|
38 | # Runtime
|
---|
39 | Requires: perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version))
|
---|
40 | Requires: perl(B)
|
---|
41 | Requires: perl(Carp)
|
---|
42 | Requires: perl(Exporter)
|
---|
43 |
|
---|
44 | # Avoid doc-file dependencies
|
---|
45 | %{?perl_default_filter}
|
---|
46 |
|
---|
47 | %description
|
---|
48 | Method modifiers are a powerful feature from the CLOS (Common Lisp Object
|
---|
49 | System) world.
|
---|
50 |
|
---|
51 | In its most basic form, a method modifier is just a method that calls
|
---|
52 | '$self->SUPER::foo(@_)'. I for one have trouble remembering that exact
|
---|
53 | invocation, so my classes seldom re-dispatch to their base classes. Very
|
---|
54 | bad!
|
---|
55 |
|
---|
56 | 'Class::Method::Modifiers' provides three modifiers: 'before', 'around',
|
---|
57 | and 'after'. 'before' and 'after' are run just before and after the method
|
---|
58 | they modify, but can not really affect that original method. 'around' is
|
---|
59 | run in place of the original method, with a hook to easily call that
|
---|
60 | original method. See the 'MODIFIERS' section for more details on how the
|
---|
61 | particular modifiers work.
|
---|
62 |
|
---|
63 | %prep
|
---|
64 | %setup -q -n Class-Method-Modifiers-%{version}
|
---|
65 |
|
---|
66 | # Drop unnecessary exec permissions from test files
|
---|
67 | chmod -c -x t/*.t
|
---|
68 |
|
---|
69 | %build
|
---|
70 | perl Makefile.PL INSTALLDIRS=vendor
|
---|
71 | make %{?_smp_mflags}
|
---|
72 | make manifypods
|
---|
73 |
|
---|
74 | %install
|
---|
75 | make pure_install DESTDIR=%{buildroot}
|
---|
76 | find %{buildroot} -type f -name .packlist -delete
|
---|
77 | %{_fixperms} %{buildroot}
|
---|
78 |
|
---|
79 | %check
|
---|
80 | #make test
|
---|
81 |
|
---|
82 | %files
|
---|
83 | %license LICENSE
|
---|
84 | %doc Changes CONTRIBUTING README t/
|
---|
85 | %{perl_vendorlib}/Class/
|
---|
86 | %{_mandir}/man3/*.3*
|
---|
87 |
|
---|
88 | %changelog
|
---|
89 | * Thu Mar 13 2018 Elbert Pol <elbert.pol@gmail.com> - 2.000006-1
|
---|
90 | - initial rpm for OS2
|
---|
91 |
|
---|