[5875] | 1 | %define real_name load |
---|
| 2 | |
---|
[9004] | 3 | Summary: Control when subroutines will be loaded |
---|
[5875] | 4 | Name: perl-%{real_name} |
---|
[9004] | 5 | Version: 0.23 |
---|
[5875] | 6 | Release: 1%{?_dist_release} |
---|
[9004] | 7 | |
---|
[5875] | 8 | License: Artistic or GPL+ |
---|
| 9 | Group: Development/Libraries |
---|
| 10 | URL: http://search.cpan.org/dist/load/ |
---|
| 11 | Source: http://www.cpan.org/authors/id/E/EL/ELIZABETH/load-%{version}.tar.gz |
---|
| 12 | BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root |
---|
| 13 | |
---|
| 14 | BuildArch: noarch |
---|
| 15 | BuildRequires: perl |
---|
| 16 | BuildRequires: perl(ExtUtils::MakeMaker) |
---|
| 17 | Requires: perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version)) |
---|
| 18 | |
---|
| 19 | %description |
---|
| 20 | The "load" pragma allows a module developer to give the application |
---|
| 21 | developer more options with regards to optimize for memory or CPU |
---|
| 22 | usage. The "load" pragma gives more control on the moment when |
---|
| 23 | subroutines are loaded and start taking up memory. This allows the |
---|
| 24 | application developer to optimize for CPU usage (by loading all of a |
---|
| 25 | module at compile time and thus reducing the amount of CPU used during |
---|
| 26 | the execution of an application). Or allow the application developer |
---|
| 27 | to optimize for memory usage, by loading subroutines only when they |
---|
| 28 | are actually needed, thereby however increasing the amount of CPU |
---|
| 29 | needed during execution. |
---|
| 30 | |
---|
| 31 | %prep |
---|
| 32 | %setup -n %{real_name}-%{version} |
---|
| 33 | |
---|
| 34 | %build |
---|
| 35 | %{expand: %%define optflags %{optflags} -fPIC} |
---|
| 36 | perl Makefile.PL INSTALLDIRS=vendor OPTIMIZE="%{optflags}" |
---|
| 37 | make %{?_smp_mflags} |
---|
| 38 | |
---|
| 39 | %install |
---|
| 40 | rm -rf %{buildroot} |
---|
| 41 | make pure_install DESTDIR=%{buildroot} |
---|
| 42 | find %{buildroot} -type f -name .packlist -exec rm -f {} ';' |
---|
| 43 | find %{buildroot} -depth -type d -exec rmdir {} ';' 2>/dev/null |
---|
| 44 | %{_fixperms} %{buildroot} |
---|
| 45 | |
---|
| 46 | %check |
---|
| 47 | make test |
---|
| 48 | |
---|
| 49 | %clean |
---|
| 50 | %{__rm} -rf %{buildroot} |
---|
| 51 | |
---|
| 52 | %files |
---|
| 53 | %defattr(-, root, root, -) |
---|
| 54 | %doc MANIFEST README CHANGELOG TODO |
---|
| 55 | %doc %{_mandir}/man3/load.3pm* |
---|
| 56 | %{perl_vendorlib}/load.pm |
---|
| 57 | |
---|
| 58 | %changelog |
---|
[9004] | 59 | * Sat Oct 11 2014 Ryoichi INAGAKI <ryo1@toki.waseda.jp> - 0.23-1 |
---|
| 60 | - updated to 0.23 |
---|
| 61 | - build with perl 5.16.3 |
---|
| 62 | |
---|
[5875] | 63 | * Sat Mar 10 2012 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 0.20-1 |
---|
| 64 | - initial build for Vine Linux |
---|