Normalize CPAN version
See https://github.com/openSUSE/cpanspec/issues/47 for details OBS-URL: https://build.opensuse.org/package/show/devel:languages:perl/perl-Algorithm-RectanglesContainingDot?expand=0&rev=4
This commit is contained in:
@@ -1,7 +1,7 @@
|
|||||||
#
|
#
|
||||||
# spec file for package perl-Algorithm-RectanglesContainingDot (Version 0.02)
|
# spec file for package perl-Algorithm-RectanglesContainingDot
|
||||||
#
|
#
|
||||||
# Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
# Copyright (c) 2024 SUSE LLC
|
||||||
#
|
#
|
||||||
# All modifications and additions to the file contributed by third parties
|
# All modifications and additions to the file contributed by third parties
|
||||||
# remain the property of their copyright owners, unless otherwise agreed
|
# remain the property of their copyright owners, unless otherwise agreed
|
||||||
@@ -12,25 +12,25 @@
|
|||||||
# license that conforms to the Open Source Definition (Version 1.9)
|
# license that conforms to the Open Source Definition (Version 1.9)
|
||||||
# published by the Open Source Initiative.
|
# published by the Open Source Initiative.
|
||||||
|
|
||||||
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
||||||
#
|
#
|
||||||
|
|
||||||
Name: perl-Algorithm-RectanglesContainingDot
|
|
||||||
Version: 0.02
|
|
||||||
Release: 1
|
|
||||||
License: GPL+ or Artistic
|
|
||||||
%define cpan_name Algorithm-RectanglesContainingDot
|
%define cpan_name Algorithm-RectanglesContainingDot
|
||||||
Summary: find rectangles containing a given dot
|
Name: perl-Algorithm-RectanglesContainingDot
|
||||||
Url: http://search.cpan.org/dist/Algorithm-RectanglesContainingDot/
|
Version: 0.20.0
|
||||||
Group: Development/Libraries/Perl
|
Release: 0
|
||||||
Source: http://www.cpan.org/authors/id/S/SA/SALVA/%{cpan_name}-%{version}.tar.gz
|
# 0.02 -> normalize -> 0.20.0
|
||||||
|
%define cpan_version 0.02
|
||||||
|
License: Artistic-1.0 OR GPL-1.0-or-later
|
||||||
|
Summary: Find rectangles containing a given dot
|
||||||
|
URL: https://metacpan.org/release/%{cpan_name}
|
||||||
|
Source0: https://cpan.metacpan.org/authors/id/S/SA/SALVA/%{cpan_name}-%{cpan_version}.tar.gz
|
||||||
BuildArch: noarch
|
BuildArch: noarch
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
||||||
BuildRequires: perl
|
BuildRequires: perl
|
||||||
BuildRequires: perl-macros
|
BuildRequires: perl-macros
|
||||||
BuildRequires: perl(ExtUtils::MakeMaker)
|
Provides: perl(Algorithm::RectanglesContainingDot) = %{version}
|
||||||
BuildRequires: perl(Test::More)
|
%undefine __perllib_provides
|
||||||
Requires: perl(Test::More)
|
|
||||||
%{perl_requires}
|
%{perl_requires}
|
||||||
|
|
||||||
%description
|
%description
|
||||||
@@ -50,38 +50,34 @@ Its usage is very simple:
|
|||||||
|
|
||||||
$a->add_rectangle($name, $x0, $y0, $x1, $y1);
|
$a->add_rectangle($name, $x0, $y0, $x1, $y1);
|
||||||
|
|
||||||
Rectangles are identified by a name that can be any perl scalar
|
Rectangles are identified by a name that can be any perl scalar (typically
|
||||||
(typically an integer or a string).
|
an integer or a string).
|
||||||
|
|
||||||
($x0, $y0) and ($x1, $y1) correspond to the coordinates of the
|
($x0, $y0) and ($x1, $y1) correspond to the coordinates of the left-botton
|
||||||
left-botton and right-top vertices respectively.
|
and right-top vertices respectively.
|
||||||
|
|
||||||
* 3) call the search method for every dot:
|
* 3) call the search method for every dot:
|
||||||
|
|
||||||
@rects = $a->rectangles_containing_dot($x, $y)
|
@rects = $a->rectangles_containing_dot($x, $y)
|
||||||
|
|
||||||
Returns the names of the rectangles containing the dot ($x, $y).
|
Returns the names of the rectangles containing the dot ($x, $y).
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n %{cpan_name}-%{version}
|
%autosetup -n %{cpan_name}-%{cpan_version}
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%{__perl} Makefile.PL INSTALLDIRS=vendor
|
perl Makefile.PL INSTALLDIRS=vendor
|
||||||
%{__make} %{?_smp_mflags}
|
%make_build
|
||||||
|
|
||||||
%check
|
%check
|
||||||
%{__make} test
|
make test
|
||||||
|
|
||||||
%install
|
%install
|
||||||
%perl_make_install
|
%perl_make_install
|
||||||
%perl_process_packlist
|
%perl_process_packlist
|
||||||
%perl_gen_filelist
|
%perl_gen_filelist
|
||||||
|
|
||||||
%clean
|
|
||||||
%{__rm} -rf %{buildroot}
|
|
||||||
|
|
||||||
%files -f %{name}.files
|
%files -f %{name}.files
|
||||||
%defattr(-,root,root,755)
|
|
||||||
%doc Changes README
|
%doc Changes README
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
Reference in New Issue
Block a user