#
# spec file for package perl-XML-SAX
#
# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via http://bugs.opensuse.org/
#


Name:           perl-XML-SAX
Version:        0.99
Release:        41.18
Summary:        XML::SAX Perl Module
License:        GPL-1.0+ or Artistic-1.0
Group:          Development/Libraries/Perl
Url:            http://www.cpan.org/modules/by-module/XML/
Source:         http://www.cpan.org/modules/by-module/XML/XML-SAX-%{version}.tar.gz
Patch0:         perl-XML-SAX-0.96-utf8.diff
BuildRequires:  perl-XML-NamespaceSupport
BuildRequires:  perl-macros
BuildRequires:  perl(XML::SAX::Base)
BuildRequires:  pkgconfig(libxml-2.0)
Requires:       perl-XML-NamespaceSupport
Requires:       perl(XML::SAX::Base)
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
%{perl_requires}

%description
XML::SAX consists of several framework classes for using and building
Perl SAX2 XML parsers, filters, and drivers. It is designed around the
need to be able to "plug in" different SAX parsers to an application
without requiring programmer intervention. Those of you familiar with
the DBI will be right at home. Some of the designs come from the Java
JAXP specification (SAX part), only without the javaness.

%prep
%setup -q -n XML-SAX-%{version}
%patch0

%build
perl Makefile.PL
make %{?_smp_mflags}

%check
make test

%install
make DESTDIR=%{buildroot} install_vendor
cat << EOF > %{buildroot}/%{perl_vendorlib}/XML/SAX/ParserDetails.ini
[XML::SAX::PurePerl]
http://xml.org/sax/features/namespaces = 1
EOF
%perl_process_packlist

%clean
rm -rf %{buildroot}

%files
%defattr(-,root,root)
%doc Changes LICENSE README
%doc %{_mandir}/man3/*
%{perl_vendorlib}/XML
%config(noreplace) %{perl_vendorlib}/XML/SAX/ParserDetails.ini
%{perl_vendorarch}/auto/XML

%changelog
* Mon Apr 15 2013 idonmez@suse.com
- Add Source URL, see https://en.opensuse.org/SourceUrls
* Mon Sep 12 2011 vcizek@suse.com
- licence correction to same as Perl
- update to 0.99
  - functionally identical to 0.96
  - requires XML::SAX::Base (not bundled within since 0.99)
* Wed Dec  1 2010 coolo@novell.com
- switch to perl_requires macro
* Mon Nov 29 2010 coolo@novell.com
- remove /var/adm/perl-modules
* Sun Jan 10 2010 jengelh@medozas.de
- enable parallel build
* Thu Jan 15 2009 anicka@suse.cz
- add patch fixing utf8 parsing (bnc#459794)
* Thu Jan 15 2009 anicka@suse.cz
- enable testsuite (bnc#466010)
* Wed Sep 10 2008 anicka@suse.cz
- update to 0.96
  * Fix handling of numeric character entities in attribute
  values
  * Fix for numeric character entities spanning end of buffer
  * Performance fix for parsing from large strings
  * Fix for UTF8 bytes in first 4096 bytes of document not being
  decoded to Perl-UTF8-characters
  * incorrect operator precedence breaks single quotes around
  DTD entity declarations
  * Fix test in ParserFactory.pm for parser module loaded
  * Fix XML::SAX::PurePerl versioning
* Fri Dec 14 2007 anicka@suse.cz
- update to 0.16
  * Applied patch for PI handling from RT#19173
  * Fixed handling of entities in attribute values
  * Cleaned up some benign warnings
  * Fixed CDATA section parsing
  * Fix Makefile.PL for VMS
  * Support calling set_handler() mid-parse
  * Fix for when random modules overload UNIVERSAL::AUTOLOAD()
  * Fix case when ParserDetails.ini isn't being updated but
  we are doing an upgrade.
  * Complete re-write of XML::SAX::PurePerl for performance
  * Support Encoding & XMLVersion in DocumentLocator interface
  * A few conformance tweaks to match perl SAX 2.1.
* Fri Jun  1 2007 coolo@suse.de
- remove libxml2-test from buildrequires
* Wed Jan 25 2006 mls@suse.de
- converted neededforbuild to BuildRequires
* Mon Nov 15 2004 ro@suse.de
- added perl-XML-NamespaceSupport to nfb and requires
* Thu Jul 29 2004 ro@suse.de
- initial version 0.12