3 %bcond_without tests # do not perform "make test"
7 Summary: Math::NumSeq -- number sequences
12 Group: Development/Languages/Perl
13 Source0: http://www.cpan.org/modules/by-module/Math/%{pdir}-%{pnam}-%{version}.tar.gz
14 # Source0-md5: c3d6104e4ce98cbb2b46239ed258c2cf
15 URL: http://search.cpan.org/dist/Math-NumSeq/
16 BuildRequires: perl-devel >= 1:5.8.0
17 BuildRequires: rpm-perlprov >= 4.1-13
19 BuildRequires: perl(Math::Factor::XS) >= 0.40
20 BuildRequires: perl(Math::Prime::XS) >= 0.23
21 BuildRequires: perl-constant-defer >= 1
22 BuildRequires: perl-File-HomeDir
23 BuildRequires: perl-Math-Libm
24 BuildRequires: perl-Module-Util
27 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
30 This is a base class for some number sequences. Sequence objects can
31 iterate through values and some sequences have random access and/or a
34 The idea is to generate things like squares or primes in a generic way.
35 Some sequences, like squares, are so easy there's no need for a class except
36 for the genericness. Other sequences are trickier and an iterator is a good
37 way to go through values. The iterating tries to be progressive, so not
38 calculating too far ahead yet doing reasonable size chunks for efficiency.
40 Sequence values have an integer index "i" starting either from i=0 or i=1 or
41 whatever best suits the sequence. The values can be anything, positive,
42 negative, fractional, etc.
44 The intention is that all modules Math::NumSeq::Foo are sequence classes,
45 and that supporting things are deeper, such as under
46 Math::NumSeq::Something::Helper or Math::NumSeq::Base::SharedStuff.
49 %setup -q -n %{pdir}-%{pnam}-%{version}
52 %{__perl} Makefile.PL \
56 OPTIMIZE="%{rpmcflags}"
58 %{?with_tests:%{__make} test}
61 rm -rf $RPM_BUILD_ROOT
63 %{__make} pure_install \
64 DESTDIR=$RPM_BUILD_ROOT
66 install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
67 cp -a examples $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
70 rm -rf $RPM_BUILD_ROOT
73 %defattr(644,root,root,755)
75 %{perl_vendorlib}/Math/NumSeq
76 %{perl_vendorlib}/Math/NumSeq.pm
78 %{_examplesdir}/%{name}-%{version}