3 # This spec file was automatically generated by cpan2rpm [ver: 2.027]
4 # The following arguments were used:
5 # --spec-only --version=0.86 '--author=Dave Rolsky' Params-Validate-0.86.tar.gz
6 # For more information on cpan2rpm please visit: http://perl.arix.com/
9 %define pkgname Params
-Validate
10 %define filelist
%{pkgname}-%{version}-filelist
11 %define NVR
%{pkgname}-%{version}-%{release}
14 name
: perl
-Params
-Validate
15 summary
: Params
-Validate
- Validate method
/function parameters
19 packager
: Arix International
<cpan2rpm@arix.com
>
21 group
: Applications
/CPAN
22 url
: http
://www.cpan.org
23 buildroot
: %{_tmppath}/%{name}-%{version}-%
(id
-u
-n
)
24 prefix
: %
(echo %{_prefix})
25 source: Params
-Validate
-0.86.tar.gz
28 The Params
::Validate module allows you to validate method or
function
29 call parameters to an arbitrary level of specificity. At the simplest
30 level
, it is capable of validating the required parameters were given
31 and that no unspecified additional parameters were passed
in.
33 It is also capable of determining that a parameter is of a specific
34 type, that it is an object of a certain class hierarchy
, that it
35 possesses certain methods
, or applying validation callbacks to
39 # This package was generated automatically with the cpan2rpm
40 # utility. To get this software or for more information
41 # please visit: http://perl.arix.com/
45 %setup -q
-n
%{pkgname}-%{version}
46 chmod
-R u
+w
%{_builddir}/%{pkgname}-%{version}
49 grep
-rsl '^
#!.*perl' . |
50 grep
-v '.bak$' |xargs
--no
-run
-if-empty \
51 %__perl -MExtUtils
::MakeMaker
-e 'MY
->fixin
(@ARGV
)'
52 CFLAGS
="$RPM_OPT_FLAGS"
53 %{__perl} Makefile.PL `%{__perl} -MExtUtils::MakeMaker -e ' print qq|PREFIX=%{buildroot}%{_prefix}|
if \$ExtUtils
::MakeMaker
::VERSION
=~
/5\
.9[1-6]|
6\
.0[0-5]/ '`
60 [ "
%{buildroot}" != "/" ] && rm -rf %{buildroot}
62 %{makeinstall} `%{__perl} -MExtUtils::MakeMaker -e ' print \$ExtUtils::MakeMaker::VERSION <= 6.05 ? qq|PREFIX=%{buildroot}%{_prefix}| : qq|DESTDIR=%{buildroot}| '`
64 cmd
=/usr
/share
/spec
-helper
/compress_files
65 [ -x $cmd
] || cmd
=/usr
/lib
/rpm
/brp
-compress
69 if [ -e
/etc
/SuSE
-release
-o
-e
/etc
/UnitedLinux
-release
]
71 %{__mkdir_p} %{buildroot}/var
/adm
/perl
-modules
72 %{__cat} `find %{buildroot} -name "perllocal.pod"` \
73 |
%{__sed} -e s+%{buildroot}++g \
74 > %{buildroot}/var/adm/perl-modules/%{name}
77 # remove special files
78 find
%{buildroot} -name "perllocal.pod" \
79 -o
-name ".packlist" \
83 # no empty directories
84 find
%{buildroot}%{_prefix} \
86 -exec rmdir {} \
; 2>/dev
/null
88 %{__perl} -MFile
::Find
-le '
89 find
({ wanted
=> \
&wanted
, no_chdir
=> 1}, "
%{buildroot}"
);
90 print "
%doc TODO Changes README LICENSE"
;
91 for my $x
(sort @
dirs, @files
) {
92 push @ret
, $x unless indirs
($x
);
94 print join "\n"
, sort @ret
;
99 local $_
= $File
::Find
::name
;
100 my $f
= $_
; s|^\Q
%{buildroot}\E||
;
101 return unless length
;
102 return $files
[@files
] = $_
if -f $f
;
105 /\Q$d\E
/ && return for reverse sort @INC
;
106 $d
=~
/\Q$_\E
/ && return
107 for qw|
/etc
%_prefix/man
%_prefix/bin
%_prefix/share|
;
114 $x
=~
/^\Q$_\E\
// && $x ne $_
&& return 1 for @
dirs;
118 [ -z
%filelist ] && {
119 echo "ERROR
: empty
%files listing"
124 [ "
%{buildroot}" != "/" ] && rm -rf %{buildroot}
127 %defattr(-,root
,root
)
130 * Thu Nov
23 2006 root@dca02