File perl-XML-Structured.spec of Package perl-XML-Structured

# spec file for package perl-XML-Structured
# Copyright (c) 2012 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

Name:           perl-XML-Structured
Version:        1.2
Release:        0
Requires:       perl = %{perl_version}
%define         cpan_name XML-Structured
%if %suse_version < 1120  
BuildRequires:  perl-macros
Summary:        Simple conversion API from XML to perl structures and back 
License:        Artistic-1.0
Group:          Development/Libraries/Perl
Source:         %{cpan_name}-%{version}.tar.bz2
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

Provides a way to convert xml data into a predefined perl data structure and back to xml. Unlike with modules like XML::Simple it is an error if the xml data does not match the provided skeleton (the "dtd"). Another advantage is that the order of the attributes and elements is taken from the dtd when converting back to xml.

%setup -q -n %{cpan_name}-%{version}

perl Makefile.PL OPTIMIZE="$RPM_OPT_FLAGS -Wall"
make %{?jobs:-j%jobs}

make test


# clean up the hard disc after build

%files -f %{name}.files
%doc MANIFEST README speed test

openSUSE Build Service is sponsored by