perl-XML-SAX-vl.spec 8.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261
  1. Summary: XML-SAX Perl module
  2. Name: perl-XML-SAX
  3. Version: 0.99
  4. Release: 3%{?_dist_release}
  5. Group: Development/Libraries
  6. License: GPL+ or Artistic
  7. URL: http://search.cpan.org/dist/XML-SAX/
  8. Source0: http://www.cpan.org/authors/id/G/GR/GRANTM/XML-SAX-%{version}.tar.gz
  9. BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
  10. BuildArch: noarch
  11. BuildRequires: perl(ExtUtils::MakeMaker)
  12. BuildRequires: perl(XML::NamespaceSupport) >= 0.03
  13. # The following creates circular dependency, but they are not needed for build.
  14. #BuildRequires: perl(XML::LibXML) perl(XML::LibXML::Common)
  15. # XML::SAX::Base became independent package, BR just for test
  16. BuildRequires: perl(XML::SAX::Base)
  17. Requires: perl(:MODULE_COMPAT_%(perl -MConfig -e 'print $Config{version}'))
  18. Requires: perl(XML::LibXML) perl(XML::LibXML::Common)
  19. %description
  20. XML::SAX consists of several framework classes for using and building
  21. Perl SAX2 XML parsers, filters, and drivers. It is designed around the
  22. need to be able to "plug in" different SAX parsers to an application
  23. without requiring programmer intervention. Those of you familiar with
  24. the DBI will be right at home. Some of the designs come from the Java
  25. JAXP specification (SAX part), only without the javaness.
  26. %prep
  27. %setup -q -n XML-SAX-%{version}
  28. %if %{_dist_release} > "vl6"
  29. %{?perl_default_filter:
  30. %filter_from_provides /^perl(XML::SAX::PurePerl)$/d
  31. %filter_from_requires /^perl(XML::SAX::PurePerl::\(DTDDecls\|DocType\|EncodingDetect\|XMLDecl\|NoUnicodeExt\|UnicodeExt\|Reader::NoUnicodeExt\))/d
  32. %perl_default_filter}
  33. %global __provides_exclude %{?__requires_exclude:%__requires_exclude|}perl\\(XML::SAX::PurePerl\\)
  34. %global __requires_exclude %{?__provides_exclude:%__provides_exclude|}perl\\(XML::SAX::PurePerl::(DTDDecls|DocType|EncodingDetect|XMLDecl|NoUnicodeExt|UnicodeExt|Reader::NoUnicodeExt)\\)
  35. %{?perl_default_subpackage_tests}
  36. %else
  37. cat << \EOF > %{name}-prov
  38. #!/bin/sh
  39. %{__perl_provides} $* |\
  40. sed -e '/perl(XML::SAX::PurePerl)/d'
  41. EOF
  42. %global __perl_provides %{_builddir}/XML-SAX-%{version}/%{name}-prov
  43. chmod +x %{__perl_provides}
  44. cat << \EOF > %{name}-req
  45. #!/bin/sh
  46. %{__perl_requires} $* |\
  47. sed -e '/perl(XML::SAX::PurePerl::\(DTDDecls\|DocType\|EncodingDetect\|XMLDecl\|NoUnicodeExt\|UnicodeExt\|Reader::NoUnicodeExt\))/d'
  48. EOF
  49. %global __perl_requires %{_builddir}/XML-SAX-%{version}/%{name}-req
  50. chmod +x %{__perl_requires}
  51. %endif
  52. %build
  53. echo N | %{__perl} Makefile.PL INSTALLDIRS=vendor
  54. make %{?_smp_mflags}
  55. %install
  56. rm -rf %{buildroot}
  57. make pure_install PERL_INSTALL_ROOT=%{buildroot}
  58. find %{buildroot} -type f -name .packlist -exec rm -f {} ';'
  59. find %{buildroot} -depth -type d -exec rmdir {} 2>/dev/null ';'
  60. chmod -R u+w %{buildroot}/*
  61. touch %{buildroot}%{perl_vendorlib}/XML/SAX/ParserDetails.ini
  62. %check
  63. make test
  64. %clean
  65. rm -rf %{buildroot}
  66. %post
  67. if [ ! -f "%{perl_vendorlib}/XML/SAX/ParserDetails.ini" ] ; then
  68. perl -MXML::SAX -e \
  69. 'XML::SAX->add_parser(q(XML::SAX::PurePerl))->save_parsers()' 2>/dev/null || :
  70. else
  71. cp -p "%{perl_vendorlib}/XML/SAX/ParserDetails.ini" "%{perl_vendorlib}/XML/SAX/ParserDetails.ini.backup"
  72. fi
  73. %triggerun -- perl-XML-LibXML < 1.58-8
  74. if [ -f "%{perl_vendorlib}/XML/SAX/ParserDetails.ini.backup" ] ; then
  75. mv "%{perl_vendorlib}/XML/SAX/ParserDetails.ini.backup" "%{perl_vendorlib}/XML/SAX/ParserDetails.ini"
  76. fi
  77. %preun
  78. # create backup of ParserDetails.ini, therefore user's configuration is used
  79. if [ $1 -eq 0 ] ; then
  80. perl -MXML::SAX -e \
  81. 'XML::SAX->remove_parser(q(XML::SAX::PurePerl))->save_parsers()' || :
  82. fi
  83. [ -f "%{perl_vendorlib}/XML/SAX/ParserDetails.ini.backup" ] && \
  84. rm -rf "%{perl_vendorlib}/XML/SAX/ParserDetails.ini.backup" || :
  85. %files
  86. %doc Changes LICENSE README
  87. %dir %{perl_vendorlib}/XML
  88. %{perl_vendorlib}/XML/SAX.pm
  89. %dir %{perl_vendorlib}/XML/SAX
  90. %{perl_vendorlib}/XML/SAX/*.pm
  91. %{perl_vendorlib}/XML/SAX/*.pod
  92. %{perl_vendorlib}/XML/SAX/PurePerl
  93. %{_mandir}/man3/XML::*.3pm*
  94. %ghost %{perl_vendorlib}/XML/SAX/ParserDetails.ini
  95. %changelog
  96. * Mon Jun 30 2014 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 0.99-3
  97. - rebuilt with perl-5.16.0.
  98. * Thu Mar 01 2012 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 0.99-2
  99. - rebuild
  100. * Thu Mar 01 2012 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 0.99-1
  101. - updated to 0.99
  102. - revamped spec in accordance with Fedora's 0.99-2
  103. - previous Vine changelogs as follows:
  104. - Sun Mar 27 2011 Yoji TOYODA <bsyamato@sea.plala.or.jp> 0.16-3
  105. - drebuild with perl-5.12.3
  106. - using __perl_requires macro for VineSeed (vl6)
  107. - Sun Jun 1 2008 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 0.16-2
  108. - added Requires(post,preun): perl-XML-LibXML
  109. - Sat May 31 2008 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 0.16-1
  110. - new upstream release
  111. - built with perl-5.10.0-2
  112. - added SOURCE1, 2 for avoiding unwanted dependancies
  113. - Sun Jan 2 2005 IWAI, Masaharu <iwai@alib.jp> 0.12-0vl2
  114. - build on perl-5.8.6-0vl1
  115. - Sun Oct 17 2004 Satoshi MACHINO <machino@vinelinux.org> 0.12-0vl1
  116. - new upstream version
  117. - updated patch0 to perl-XML-SAX-0.12-makefile.patch
  118. - Mon Apr 15 2002 IWAI Masaharu <iwaim@cc.mbn.or.jp> 0.10-0vl1
  119. - first build for Vine Linux
  120. * Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.99-2
  121. - Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
  122. * Fri Oct 07 2011 Marcela Mašláňová <mmaslano@redhat.com> 0.99-1
  123. - update to 0.99
  124. * Wed Jul 20 2011 Petr Sabata <contyk@redhat.com> - 0.96-15
  125. - Perl mass rebuild
  126. * Fri Jun 24 2011 Marcela Mašláňová <mmaslano@redhat.com> - 0.96-14
  127. - fix macros to work with new macros
  128. - clean spec
  129. * Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.96-13
  130. - Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
  131. * Mon Jan 24 2011 Adrian Reber <adrian@lisas.de> - 0.96-12
  132. - rebuild for ppc
  133. * Thu Dec 23 2010 Marcela Maslanova <mmaslano@redhat.com> - 0.96-11
  134. - 661697 rebuild for fixing problems with vendorach/lib
  135. * Fri May 07 2010 Marcela Maslanova <mmaslano@redhat.com> - 0.96-10
  136. - Mass rebuild with perl-5.12.0
  137. * Fri Feb 5 2010 Stepan Kasal <skasal@redhat.com> - 0.96-9
  138. - anchor the filtering regexps
  139. * Fri Feb 5 2010 Marcela Mašláňová <mmaslano@redhat.com> - 0.96-8
  140. - XML-LibXML use triggers for XML::SAX update. Deleting of settings in
  141. ParserDetails.ini is solved by post and preun part, which create backup.
  142. * Thu Nov 12 2009 Marcela Mašláňová <mmaslano@redhat.com> - 0.96-7
  143. - instead of path into post used perl_vendorlib macro
  144. - rebuilt will be needed for perl-5.10.1
  145. * Thu Nov 12 2009 Marcela Mašláňová <mmaslano@redhat.com> - 0.96-6
  146. - post scriptlet needs to check whether the file is installed. When it isn't,
  147. then it's needed call for adding PurePerl parser
  148. http://perl-xml.sourceforge.net/faq/#parserdetails.ini
  149. * Mon Oct 19 2009 Stepan Kasal <skasal@redhat.com> - 0.96-5
  150. - use the filtering macros
  151. * Sun Jul 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.96-4
  152. - Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
  153. * Tue Apr 28 2009 Marcela Mašláňová <mmaslano@redhat.com> - 0.96-3
  154. - 478905 fix scriptlets
  155. * Thu Feb 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.96-2
  156. - Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
  157. * Thu Dec 11 2008 Marcela Mašláňová <mmaslano@redhat.com> - 0.96-1
  158. - update to 0.96, big leap in versioning
  159. * Sun Mar 2 2008 Tom "spot" Callaway <tcallawa@redhat.com> - 0.16-5
  160. - Re-enable XML::LibXML BuildRequires
  161. * Wed Feb 27 2008 Tom "spot" Callaway <tcallawa@redhat.com> - 0.16-4
  162. - Rebuild for perl 5.10 (again)
  163. * Mon Jan 28 2008 Tom "spot" Callaway <tcallawa@redhat.com> - 0.16-3.1
  164. - temporarily disable BR against perl-XML-LibXML
  165. * Thu Jan 24 2008 Tom "spot" Callaway <tcallawa@redhat.com> - 0.16-3
  166. - rebuild for new perl
  167. * Sat Jul 07 2007 Robin Norwood <rnorwood@redhat.com> - 0.16-2
  168. - Resolves: rhbz#247213
  169. - Fix provides and requires scripts.
  170. * Mon Jul 02 2007 Jose Pedro Oliveira <jpo at di.uminho.pt> - 0.16-1
  171. - Update to 0.16.
  172. - Brings specfile closer to Fedora Perl template.
  173. - Corrects Source0 URL (upstream maintainer has changed).
  174. - Move Requires filter into spec, and add Provides filter.
  175. * Tue Feb 13 2007 Robin Norwood <rnorwood@redhat.com> - 0.15-1
  176. - New version: 0.15
  177. * Fri Jun 09 2006 Jason Vas Dias <jvdias@redhat.com> - 0.14-2
  178. - fix bug 194706: fails to build under (new!) mock
  179. * Mon Jun 05 2006 Jason Vas Dias <jvdias@redhat.com> - 0.14-1
  180. - upgrade to 0.14
  181. * Fri Feb 03 2006 Jason Vas Dias <jvdias@redhat.com> - 0.13-1.1
  182. - rebuild for new perl-5.8.8
  183. * Mon Dec 19 2005 Jason Vas Dias <jvdias@redhat.com> - 0.13-1
  184. - upgrade to 0.13
  185. * Fri Dec 16 2005 Jesse Keating <jkeating@redhat.com>
  186. - rebuilt for new gcc
  187. * Fri Dec 16 2005 Jesse Keating <jkeating@redhat.com>
  188. - rebuilt for new gcj
  189. * Sun Apr 18 2004 Ville Skyttä <ville.skytta at iki.fi> - 0.12-7
  190. - #121167
  191. - Handle ParserDetails.ini parser registration.
  192. - Require perl(:MODULE_COMPAT_*).
  193. - Own installed directories.
  194. * Wed Oct 22 2003 Chip Turner <cturner@redhat.com> - 0.12-1
  195. - Specfile autogenerated.