%define upstream_name constant %define upstream_version 1.24 Name: perl-%{upstream_name} Version: %perl_convert_version %{upstream_version} Release: %mkrel 3 Summary: Define compile-time constants License: GPL+ or Artistic Group: Development/Perl Url: http://search.cpan.org/dist/%{upstream_name} Source0: http://www.cpan.org/modules/by-module//%{upstream_name}-%{upstream_version}.tar.gz BuildRequires: perl(ExtUtils::MakeMaker) BuildRequires: perl(Module::Build) >= 0.280.800 BuildRequires: perl(Test::More) BuildArch: noarch Provides: perl(constant) %description This pragma allows you to declare constants at compile-time. When you declare a constant such as 'PI' using the method shown above, each machine your script runs upon can have as many digits of accuracy as it can use. Also, your program will be easier to read, more likely to be maintained (and maintained correctly), and far less likely to send a space probe to the wrong planet because nobody noticed the one equation in which you wrote '3.14195'. When a constant is used in an expression, Perl replaces it with its value at compile time, and may then optimize the expression further. In particular, any code in an 'if (CONSTANT)' block will be optimized away if the constant is false. %prep %setup -q -n %{upstream_name}-%{upstream_version} %build %{__perl} Makefile.PL INSTALLDIRS=vendor %make %check make test %install %makeinstall_std %files %doc Changes META.json META.yml MYMETA.yml README eg %{_mandir}/man3/* %perl_vendorlib/* %changelog * Wed Mar 27 2013 jquelin <jquelin> 1.240.0-3.mga3 + Revision: 405589 - perl 5.16.3 rebuild * Sun Jan 13 2013 umeabot <umeabot> 1.240.0-2.mga3 + Revision: 375426 - Mass Rebuild - https://wiki.mageia.org/en/Feature:Mageia3MassRebuild * Tue Jan 08 2013 jquelin <jquelin> 1.240.0-1.mga3 + Revision: 341870 - update to 1.24 + kharec <kharec> - update to 1.21 * Sat Jun 11 2011 spuhler <spuhler> 1.190.0-2.mga2 + Revision: 104029 - increase rel for rebuild * Tue Jan 18 2011 jquelin <jquelin> 1.190.0-1.mga1 + Revision: 22210 - cleaning spec file - imported package perl-constant