%define _use_internal_dependency_generator 0 %{!?perl_vendorlib: %define perl_vendorlib %(eval "`perl -V:installvendorlib`"; echo $installvendorlib)} Summary: XML-SAX Perl module Name: perl-XML-SAX Version: 0.12 Release: 7.1.1 License: GPL or Artistic Group: Development/Libraries URL: http://search.cpan.org/dist/XML-SAX/ BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root BuildRequires: perl >= 2:5.8.0 Requires: %(perl -MConfig -le 'if (defined $Config{useithreads}) { print "perl(:WITH_ITHREADS)" } else { print "perl(:WITHOUT_ITHREADS)" }') Requires: %(perl -MConfig -le 'if (defined $Config{usethreads}) { print "perl(:WITH_THREADS)" } else { print "perl(:WITHOUT_THREADS)" }') Requires: %(perl -MConfig -le 'if (defined $Config{uselargefiles}) { print "perl(:WITH_LARGEFILES)" } else { print "perl(:WITHOUT_LARGEFILES)" }') Requires: perl(:MODULE_COMPAT_%(perl -MConfig -e 'print $Config{version}')) Source0: XML-SAX-0.12.tar.gz Source1: filter-requires-xmlsax.sh BuildArch: noarch BuildRequires: perl-XML-NamespaceSupport # Provide perl-specific find-{provides,requires}. %define __find_provides /usr/lib/rpm/find-provides.perl # %%define __find_requires /usr/lib/rpm/find-requires.perl %define __find_requires %{SOURCE1} %description %{summary}. %prep %setup -q -n XML-SAX-%{version} %build echo N | CFLAGS="$RPM_OPT_FLAGS" perl Makefile.PL INSTALLDIRS=vendor make OPTIMIZE="$RPM_OPT_FLAGS" %install rm -rf $RPM_BUILD_ROOT make install \ PERL_INSTALL_ROOT=$RPM_BUILD_ROOT \ INSTALLARCHLIB=$RPM_BUILD_ROOT%{perl_archlib} find $RPM_BUILD_ROOT -type f -a \( -name perllocal.pod -o -name .packlist \ -o \( -name '*.bs' -a -empty \) \) -exec rm -f {} ';' find $RPM_BUILD_ROOT -type d -depth -exec rmdir {} 2>/dev/null ';' chmod -R u+w $RPM_BUILD_ROOT/* touch $RPM_BUILD_ROOT%{perl_vendorlib}/XML/SAX/ParserDetails.ini %check || : make test %clean rm -rf $RPM_BUILD_ROOT %post perl -MXML::SAX -e \ 'XML::SAX->add_parser(q(XML::SAX::PurePerl))->save_parsers()' 2>/dev/null %preun if [ $1 -eq 0 ]; then perl -MXML::SAX -e \ 'XML::SAX->remove_parser(q(XML::SAX::PurePerl))->save_parsers()' fi %files %defattr(-,root,root,-) %doc Changes LICENSE README %dir %{perl_vendorlib}/XML %{perl_vendorlib}/XML/SAX.pm %dir %{perl_vendorlib}/XML/SAX %{perl_vendorlib}/XML/SAX/*.pm %{perl_vendorlib}/XML/SAX/*.pod %{perl_vendorlib}/XML/SAX/PurePerl %{_mandir}/man3/XML::*.3* %ghost %{perl_vendorlib}/XML/SAX/ParserDetails.ini %exclude %{perl_vendorlib}/XML/SAX/placeholder.pl %changelog * Fri Dec 16 2005 Jesse Keating - rebuilt for new gcc * Fri Dec 16 2005 Jesse Keating - rebuilt for new gcj * Sun Apr 18 2004 Ville Skyttä - 0.12-7 - #121167 - Handle ParserDetails.ini parser registration. - Require perl(:MODULE_COMPAT_*). - Own installed directories. * Wed Oct 22 2003 Chip Turner - 0.12-1 - Specfile autogenerated.