From 4addb216f52f134cf9a8b7b1a98acca88907eae7 Mon Sep 17 00:00:00 2001 From: Jean-Philippe Pialasse Date: Thu, 23 Jan 2025 21:14:02 -0500 Subject: [PATCH] * Thu Jan 23 2025 Jean-Philippe Pialasse 2.13-2.sme - import to SME11 --- Class-Method-Modifiers-2.13.tar.gz | 3 + perl-Class-Method-Modifiers.spec | 133 ++++++++++++++++++++--------- 2 files changed, 98 insertions(+), 38 deletions(-) create mode 100644 Class-Method-Modifiers-2.13.tar.gz diff --git a/Class-Method-Modifiers-2.13.tar.gz b/Class-Method-Modifiers-2.13.tar.gz new file mode 100644 index 0000000..e45a56a --- /dev/null +++ b/Class-Method-Modifiers-2.13.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ab5807f71018a842de6b7a4826d6c1f24b8d5b09fcce5005a3309cf6ea40fd63 +size 41385 diff --git a/perl-Class-Method-Modifiers.spec b/perl-Class-Method-Modifiers.spec index 68f15a0..f0f5616 100644 --- a/perl-Class-Method-Modifiers.spec +++ b/perl-Class-Method-Modifiers.spec @@ -1,55 +1,112 @@ -%define name perl-Class-Method-Modifiers -%define version 1.0 -%define release 1 -Summary: This is what perl-Class-Method-Modifiers does. -Name: %{name} -Version: %{version} -Release: %{release}%{?dist} -Source: %{name}-%{version}.tar.gz -License: GNU GPL version 2 -Group: SMEserver/addon -BuildRoot: %{_tmppath}/%{name}-buildroot -Prefix: %{_prefix} -BuildArchitectures: noarch -BuildRequires: smeserver-devtools -Requires: smeserver-release >= 11.0 -AutoReqProv: no +# Run optional tests +%if ! (0%{?rhel}) +%{bcond_without perl_Class_Method_Modifiers_enables_optional_test} +%else +%{bcond_with perl_Class_Method_Modifiers_enables_optional_test} +%endif +Name: perl-Class-Method-Modifiers +Version: 2.13 +Release: 2%{?org_tag}%{?dist} +Summary: Provides Moose-like method modifiers +License: GPL+ or Artistic +Group: Development/Libraries +URL: http://search.cpan.org/dist/Class-Method-Modifiers/ +Source0: http://localhost/cpan//authors/id/S/SA/SARTAK/Class-Method-Modifiers-%{version}.tar.gz +BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) +BuildArch: noarch +# Module Build +BuildRequires: coreutils +BuildRequires: findutils +BuildRequires: make +BuildRequires: perl-interpreter +BuildRequires: perl-generators +BuildRequires: perl(ExtUtils::MakeMaker) +#BuildRequires: perl(ExtUtils::MakeMaker) >= 6.42 +BuildRequires: perl(strict) +BuildRequires: perl(warnings) +# Module Runtime +BuildRequires: perl(B) +BuildRequires: perl(base) +BuildRequires: perl(Carp) +BuildRequires: perl(Exporter) +# Test Suite +BuildRequires: perl(File::Spec) +BuildRequires: perl(if) +BuildRequires: perl(Test::Fatal) +BuildRequires: perl(Test::More) >= 0.88 +BuildRequires: perl(Test::Requires) +BuildRequires: perl(Test::Needs) +BuildRequires: perl(version) +# Optional Test Requirements +%if 0%{!?perl_bootstrap:1} && %{with perl_Class_Method_Modifiers_enables_optional_test} +BuildRequires: perl(CPAN::Meta::Requirements) >= 2.121 +BuildRequires: perl(CPAN::Meta) >= 2.120900 +BuildRequires: perl(Moose) +%endif +# Runtime +Requires: perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version)) +Requires: perl(B) +Requires: perl(Carp) +Requires: perl(Exporter) + %description -Method modifiers are a convenient feature from the CLOS (Common Lisp Object System) world. +Method modifiers are a powerful feature from the CLOS (Common Lisp Object +System) world. +In its most basic form, a method modifier is just a method that calls +'$self->SUPER::foo(@_)'. I for one have trouble remembering that exact +invocation, so my classes seldom re-dispatch to their base classes. Very +bad! -%changelog -* Day MMMM DD YYYY 1.0-1.sme -- Initial code - create RPM [SME:99999] +'Class::Method::Modifiers' provides three modifiers: 'before', 'around', +and 'after'. 'before' and 'after' are run just before and after the method +they modify, but can not really affect that original method. 'around' is +run in place of the original method, with a hook to easily call that +original method. See the 'MODIFIERS' section for more details on how the +particular modifiers work. %prep +%setup -q -n Class-Method-Modifiers-%{version} -%setup -q +# Drop unnecessary exec permissions from test files +chmod -c -x t/*.t %build +perl Makefile.PL INSTALLDIRS=vendor +make %{?_smp_mflags} %install -rm -rf $RPM_BUILD_ROOT -(cd root ; find . -depth -print | cpio -dump $RPM_BUILD_ROOT) -rm -f %{name}-%{version}-filelist -/sbin/e-smith/genfilelist $RPM_BUILD_ROOT \ -> %{name}-%{version}-filelist -#echo "%doc COPYING" >> %{name}-%{version}-filelist -#--dir 'attr(755,user,grp)' \ -#--file 'attr(755,root,root)' \ +rm -rf %{buildroot} + +make pure_install PERL_INSTALL_ROOT=%{buildroot} + +find %{buildroot} -type f -name .packlist -exec rm -f {} \; +find %{buildroot} -depth -type d -exec rmdir {} 2>/dev/null \; + +%{_fixperms} %{buildroot}/* + +%check +make test %clean -cd .. -rm -rf %{name}-%{version} +rm -rf %{buildroot} -%pre +%files +%defattr(-,root,root,-) +%doc Changes +%{perl_vendorlib}/* +%{_mandir}/man3/* -%preun +%changelog +* Thu Jan 23 2025 Jean-Philippe Pialasse 2.13-2.sme +- import to SME11 -%post +* Fri Nov 27 2020 Gavin Carr 2.13-1 +- Update to version 2.13. -%postun -#uninstall -%files -f %{name}-%{version}-filelist -%defattr(-,root,root) +* Fri Aug 08 2014 Gavin Carr 2.10-1 +- Update to version 2.10. + +* Fri Aug 12 2011 Gavin Carr 1.07-1 +- Specfile autogenerated by cpanspec 1.79.