]> git.pld-linux.org Git - packages/perl-Data-Validate-Domain.git/blob - perl-Data-Validate-Domain.spec
new, version 0.10
[packages/perl-Data-Validate-Domain.git] / perl-Data-Validate-Domain.spec
1 #
2 # Conditional build:
3 %bcond_without  tests   # do not perform "make test"
4
5 %define         pdir    Data
6 %define         pnam    Validate-Domain
7 %include        /usr/lib/rpm/macros.perl
8 Summary:        Domain validation methods Perl module
9 Name:           perl-Data-Validate-Domain
10 Version:        0.10
11 Release:        1
12 License:        GPL+ or Artistic
13 Group:          Development/Libraries
14 Source0:        http://search.cpan.org/CPAN/authors/id/N/NE/NEELY/Data-Validate-Domain-%{version}.tar.gz
15 # Source0-md5:  1331c0f47c024a83c610f8598490423a
16 URL:            http://search.cpan.org/dist/Data-Validate-Domain
17 BuildRequires:  rpm-perlprov >= 4.1-13
18 %if %{with autodeps} || %{with tests}
19 BuildRequires:  perl(Exporter)
20 BuildRequires:  perl(ExtUtils::MakeMaker)
21 BuildRequires:  perl(Net::Domain::TLD) >= 1.62
22 BuildRequires:  perl(Test::More)
23 %endif
24 BuildArch:      noarch
25 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
26
27 %description
28 This module collects domain validation routines to make input
29 validation, and untainting easier and more readable.
30
31 All functions return an untainted value if the test passes, and undef
32 if it fails. This means that you should always check for a defined
33 status explicitly. Don't assume the return will be true. (e.g.
34 is_username('0'))
35
36 The value to test is always the first (and often only) argument.
37
38 %prep
39 %setup -q -n Data-Validate-Domain-%{version}
40
41 find lib -name "*.pm" -exec chmod -c a-x {} +
42
43 %build
44 %{__perl} Makefile.PL \
45         INSTALLDIRS=vendor
46 %{__make}
47
48 %{?with_tests:%{__make} test}
49
50 %install
51 rm -rf $RPM_BUILD_ROOT
52 %{__make} pure_install \
53         DESTDIR=$RPM_BUILD_ROOT
54
55 %clean
56 rm -rf $RPM_BUILD_ROOT
57
58 %files
59 %defattr(644,root,root,755)
60 %doc Changes README
61 %{perl_vendorlib}/Data/Validate/Domain.pm
62 %{_mandir}/man3/Data::Validate::Domain.3pm*
This page took 0.075242 seconds and 4 git commands to generate.