3 %bcond_without tests # do not perform "make test"
6 %define pnam Geometry-Voronoi
7 Summary: Math::Geometry::Voronoi - compute Voronoi diagrams from sets of points
8 Name: perl-Math-Geometry-Voronoi
11 License: GPL v1+ or Artistic
12 Group: Development/Languages/Perl
13 Source0: http://www.cpan.org/modules/by-module/Math/%{pdir}-%{pnam}-%{version}.tar.gz
14 # Source0-md5: 44392be55ff56870aaff286dd735a5e2
15 URL: http://search.cpan.org/dist/Math-Geometry-Voronoi/
16 BuildRequires: perl-devel >= 1:5.8.0
17 BuildRequires: rpm-perlprov >= 4.1-13
19 BuildRequires: perl-Class-Accessor
20 BuildRequires: perl-Params-Validate
22 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
25 This module computes Voronoi diagrams from a set of input points. Info
26 on Voronoi diagrams can be found here:
28 http://en.wikipedia.org/wiki/Voronoi_diagram
30 This module is a wrapper around a C implementation found here:
32 http://www.derekbradley.ca/voronoi.html
34 Which is itself a modification of code by Steve Fortune, the inventor
35 of the algorithm used (Fortune's algorithm):
38 %setup -q -n %{pdir}-%{pnam}-%{version}
41 %{__perl} Makefile.PL \
45 OPTIMIZE="%{rpmcflags}"
47 %{?with_tests:%{__make} test}
50 rm -rf $RPM_BUILD_ROOT
52 %{__make} pure_install \
53 DESTDIR=$RPM_BUILD_ROOT
55 install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
56 cp -a examples $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
59 rm -rf $RPM_BUILD_ROOT
62 %defattr(644,root,root,755)
64 %{perl_vendorarch}/Math/Geometry/Voronoi.pm
65 %dir %{perl_vendorarch}/auto/Math/Geometry/Voronoi
66 %attr(755,root,root) %{perl_vendorarch}/auto/Math/Geometry/Voronoi/Voronoi.so
68 %{_examplesdir}/%{name}-%{version}