]> git.pld-linux.org Git - packages/perl-Params-Validate.git/blame - perl-Params-Validate.spec
- rel 2
[packages/perl-Params-Validate.git] / perl-Params-Validate.spec
CommitLineData
1c1e3fe4 1#
048bb18a 2# Conditional build:
cc75d535 3%bcond_without tests # do not perform "make test"
1c1e3fe4 4#
dbcec85a 5%include /usr/lib/rpm/macros.perl
6a589881 6%define pdir Params
7%define pnam Validate
f6017dc7 8Summary: Params::Validate - validate method/function parameters
803f6e9a 9Summary(pl.UTF-8): Params::Validate - sprawdzanie poprawności parametrów funkcji/metody
dbcec85a 10Name: perl-Params-Validate
08d6ea20 11Version: 0.89
d0653200 12Release: 2
1c1e3fe4 13# same as perl
3ebda061 14License: GPL v1+ or Artistic
dbcec85a 15Group: Development/Languages/Perl
1af521e1 16Source0: http://www.cpan.org/modules/by-authors/id/D/DR/DROLSKY/%{pdir}-%{pnam}-%{version}.tar.gz
08d6ea20 17# Source0-md5: b53ff2b9595623aaa4f98d8b31a5a1c2
9ef563d2 18URL: http://search.cpan.org/dist/Params-Validate/
1c1e3fe4
JB
19%if %{with tests}
20BuildRequires: perl-Attribute-Handlers
21BuildRequires: perl-Test-Simple
b37f9241 22BuildRequires: perl-Test-Taint
1c1e3fe4 23%endif
cfca4987 24BuildRequires: perl-devel >= 1:5.8.0
5b7bcdca 25BuildRequires: rpm-perlprov >= 4.1-13
dbcec85a
JR
26BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
27
28%description
048bb18a 29The Params::Validate module allows you to validate method or function
30call parameters to an arbitrary level of specificity. At the simplest
31level, it is capable of validating the required parameters were given
32and that no unspecified additional parameters were passed in.
33
f6017dc7
JB
34It is also capable of determining that a parameter is of a specific
35type, that it is an object of a certain class hierarchy, that it
36possesses certain methods, or applying validation callbacks to
37arguments.
d2255876 38
4ed71d70
JR
39%description -l pl.UTF-8
40Moduł Params::Validate pozwala na sprawdzanie poprawności parametrów,
41z jakimi wywołana została funkcja lub metoda, na dowolnym poziomie
42szczegółowości. W najprostszym przypadku możliwe jest sprawdzenie,
43czy podane zostały parametry wymagane i czy nie podano dodatkowych,
048bb18a 44nie rozpoznawanych.
45
4ed71d70
JR
46Potrafi także określić czy parametr jest konkretnego typu, czy jest
47obiektem danej hierarchii, czy posiada zadane metody, lub przypisać
48argumentom callbacki (a, i tak wszyscy wiedzą, o co chodzi... ;-> )
49sprawdzające.
dbcec85a
JR
50
51%prep
048bb18a 52%setup -q -n %{pdir}-%{pnam}-%{version}
dbcec85a
JR
53
54%build
71967ba6 55%{__perl} Makefile.PL \
83cb4de0 56 INSTALLDIRS=vendor
cc75d535 57%{__make} \
bf730eea 58 CC="%{__cc}" \
cc75d535 59 OPTIMIZE="%{rpmcflags}"
dbcec85a 60
cc75d535 61%{?with_tests:%{__make} test}
048bb18a 62
dbcec85a
JR
63%install
64rm -rf $RPM_BUILD_ROOT
65
cc75d535 66%{__make} install \
67 DESTDIR=$RPM_BUILD_ROOT
dbcec85a 68
dbcec85a
JR
69%clean
70rm -rf $RPM_BUILD_ROOT
71
72%files
73%defattr(644,root,root,755)
ad72dd39 74%doc Changes README
9ef563d2
JB
75%dir %{perl_vendorarch}/auto/Params
76%dir %{perl_vendorarch}/auto/Params/Validate
77%{perl_vendorarch}/auto/Params/Validate/*.bs
78%attr(755,root,root) %{perl_vendorarch}/auto/Params/Validate/*.so
aa140d82 79%dir %{perl_vendorarch}/Attribute
9ef563d2
JB
80%dir %{perl_vendorarch}/Attribute/Params
81%{perl_vendorarch}/Attribute/Params/*.pm
82%dir %{perl_vendorarch}/Params
83%{perl_vendorarch}/Params/*.pm
dbcec85a 84%{_mandir}/man3/*
This page took 0.085213 seconds and 4 git commands to generate.