forked from pool/perl-Data-Validate-IP
update to 0.20 and update license OBS-URL: https://build.opensuse.org/request/show/204959 OBS-URL: https://build.opensuse.org/package/show/devel:languages:perl/perl-Data-Validate-IP?expand=0&rev=2
78 lines
2.4 KiB
RPMSpec
78 lines
2.4 KiB
RPMSpec
# vim: set sw=4 ts=4 et nu:
|
|
#
|
|
# spec file for package perl-Data-Validate-IP
|
|
#
|
|
# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
|
#
|
|
# All modifications and additions to the file contributed by third parties
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
# upon. The license for this file, and modifications and additions to the
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
# license for the pristine package is not an Open Source License, in which
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
# published by the Open Source Initiative.
|
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
#
|
|
|
|
|
|
Name: perl-Data-Validate-IP
|
|
Version: 0.20
|
|
Release: 0
|
|
Summary: Ipv4 and ipv6 validation methods
|
|
License: GPL-1.0+ or Artistic-1.0
|
|
Group: Development/Libraries/Perl
|
|
Source: http://search.cpan.org/CPAN/authors/id/D/DR/DROLSKY/Data-Validate-IP-%{version}.tar.gz
|
|
Url: http://search.cpan.org/dist/Data-Validate-IP
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
%{perl_requires}
|
|
BuildRequires: make
|
|
BuildRequires: perl-macros
|
|
BuildRequires: perl(ExtUtils::MakeMaker)
|
|
BuildRequires: perl(Net::Netmask)
|
|
BuildRequires: perl(NetAddr::IP)
|
|
BuildRequires: perl(Test::More)
|
|
BuildRequires: perl(Test::Requires)
|
|
Requires: perl(Net::Netmask)
|
|
Requires: perl(NetAddr::IP)
|
|
%if 0%{?suse_version} >= 1120
|
|
BuildArch: noarch
|
|
%endif
|
|
|
|
%description
|
|
This module collects ip validation routines to make input validation, and
|
|
untainting easier and more readable.
|
|
All functions return an untainted value if the test passes, and undef if
|
|
it fails. This means that you should always check for a defined status
|
|
explicitly. Don't assume the return will be true. (e.g. is_username('0'))
|
|
The value to test is always the first (and often only) argument.
|
|
|
|
%prep
|
|
%setup -q -n "Data-Validate-IP-%{version}"
|
|
%__sed -i '/^auto_install/d' Makefile.PL
|
|
|
|
%build
|
|
%__perl Makefile.PL PREFIX="%{_prefix}"
|
|
%__make %{?_smp_flags}
|
|
|
|
%install
|
|
%perl_make_install
|
|
%perl_process_packlist
|
|
|
|
%check
|
|
%__make test
|
|
|
|
%clean
|
|
%{?buildroot:%__rm -rf "%{buildroot}"}
|
|
|
|
%files
|
|
%defattr(-,root,root)
|
|
%doc Changes README
|
|
%dir %{perl_vendorlib}/Data
|
|
%dir %{perl_vendorlib}/Data/Validate
|
|
%{perl_vendorlib}/Data/Validate/IP.pm
|
|
%doc %{perl_man3dir}/Data::Validate::IP.%{perl_man3ext}%{ext_man}
|
|
|
|
%changelog
|