Accepting request 72088 from devel:languages:perl

OBS-URL: https://build.opensuse.org/request/show/72088
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/perl-Eval-Closure?expand=0&rev=3
This commit is contained in:
Sascha Peilicke 2011-05-31 11:38:06 +00:00 committed by Git OBS Bridge
parent 31cc70f138
commit c6d49bf02d
4 changed files with 47 additions and 46 deletions

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:01b390e56a10378d3ed343c9a711967354c41a9fa73957b1c0f2b13d99e86260
size 15351

3
Eval-Closure-0.05.tar.gz Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:42454a624b0b7d20e3e8214b1fd875d6e1610004bdf72ad84ea976f1f643647f
size 15491

View File

@ -1,3 +1,11 @@
-------------------------------------------------------------------
Wed May 4 10:55:03 UTC 2011 - coolo@opensuse.org
- updated to 0.05
- make sure Perl::Tidy doesn't look at @ARGV (rafl)
- stop using Memoize, it apparently doesn't work properly under mod_perl
in some situations (mateu)
-------------------------------------------------------------------
Sat Apr 16 00:41:51 CET 2011 - pascal.bleser@opensuse.org

View File

@ -1,5 +1,5 @@
#
# spec file for package perl-Eval-Closure
# spec file for package perl-Eval-Closure (Version 0.05)
#
# Copyright (c) 2011 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
@ -15,73 +15,66 @@
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
Name: perl-Eval-Closure
Version: 0.03
Version: 0.05
Release: 1
Summary: Safely and cleanly create closures via string eval
Source: http://search.cpan.org/CPAN/authors/id/D/DO/DOY/Eval-Closure-%{version}.tar.gz
Url: http://search.cpan.org/dist/Eval-Closure
License: GPL+ or Artistic
%define cpan_name Eval-Closure
Summary: safely and cleanly create closures via string eval
Url: http://search.cpan.org/dist/Eval-Closure/
Group: Development/Libraries/Perl
License: Perl License
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%{perl_requires}
BuildRequires: perl-macros
BuildRequires: make
BuildRequires: perl(Test::Requires)
BuildRequires: perl(Test::Output)
BuildRequires: perl(Test::More) >= 0.88
BuildRequires: perl(Test::Fatal)
BuildRequires: perl(ExtUtils::MakeMaker) >= 6.31
BuildRequires: perl(Try::Tiny)
BuildRequires: perl(Scalar::Util)
BuildRequires: perl(Sub::Exporter)
Requires: perl(Try::Tiny)
Requires: perl(Scalar::Util)
Requires: perl(Sub::Exporter)
%if 0%{?suse_version} >= 1120
Source: http://www.cpan.org/authors/id/D/DO/DOY/%{cpan_name}-%{version}.tar.gz
BuildArch: noarch
%endif
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildRequires: perl
BuildRequires: perl-macros
BuildRequires: perl(Sub::Exporter)
BuildRequires: perl(Test::Fatal)
BuildRequires: perl(Test::More) >= 0.88
BuildRequires: perl(Test::Requires)
BuildRequires: perl(Try::Tiny)
Requires: perl(Sub::Exporter)
Requires: perl(Try::Tiny)
Recommends: perl(Perl::Tidy)
%{perl_requires}
%description
String eval is often used for dynamic code generation. For instance,
"Moose" uses it heavily, to generate inlined versions of accessors and
'Moose' uses it heavily, to generate inlined versions of accessors and
constructors, which speeds code up at runtime by a significant amount.
String eval is not without its issues however - it's difficult to control
the scope it's used in (which determines which variables are in scope
inside the eval), and it can be quite slow, especially if doing a large
number of evals.
This module attempts to solve both of those problems. It provides an
"eval_closure" function, which evals a string in a clean environment,
other than a fixed list of specified variables. It also caches the result
of the eval, so that doing repeated evals of the same source, even with a
'eval_closure' function, which evals a string in a clean environment, other
than a fixed list of specified variables. It also caches the result of the
eval, so that doing repeated evals of the same source, even with a
different environment, will be much faster (but note that the description
is part of the string to be evaled, so it must also be the same (or
non-existent) if caching is to work properly).
%prep
%setup -q -n "Eval-Closure-%{version}"
%__sed -i '/^auto_install/d' Makefile.PL
%setup -q -n %{cpan_name}-%{version}
%build
%__perl Makefile.PL PREFIX="%{_prefix}"
%__make %{?_smp_flags}
%{__perl} Makefile.PL INSTALLDIRS=vendor
%{__make} %{?_smp_mflags}
%check
%{__make} test
%install
%perl_make_install
%perl_process_packlist
%check
%__make test
%perl_gen_filelist
%clean
%{?buildroot:%__rm -rf "%{buildroot}"}
%{__rm} -rf %{buildroot}
%files -f %{name}.files
%defattr(-,root,root,755)
%doc Changes LICENSE README weaver.ini
%files
%defattr(-,root,root)
%doc README Changes LICENSE
%dir %{perl_vendorlib}/Eval
%{perl_vendorlib}/Eval/Closure.pm
%doc %{perl_man3dir}/Eval::Closure.%{perl_man3ext}%{ext_man}
%changelog