8
0
Files
perl-XML-LibXML-PrettyPrint/perl-XML-LibXML-PrettyPrint.spec

92 lines
3.1 KiB
RPMSpec
Raw Normal View History

#
# spec file for package perl-XML-LibXML-PrettyPrint
#
# Copyright (c) 2011 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-LibXML-PrettyPrint
Version: 0.002
Release: 0
Summary: Add pleasant whitespace to a DOM tree
Source: http://search.cpan.org/CPAN/authors/id/T/TO/TOBYINK/XML-LibXML-PrettyPrint-%{version}.tar.gz
Url: http://search.cpan.org/dist/XML-LibXML-PrettyPrint
Group: Development/Libraries/Perl
License: GNU General Public License version 2 or later or Artistic (GPLv2+ or Artistic)
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%{perl_requires}
BuildRequires: perl-macros
BuildRequires: make
BuildRequires: perl(Test::More) >= 0.61
BuildRequires: perl(Test::Warn) >= 0.20
BuildRequires: perl(ExtUtils::MakeMaker) >= 6.42
BuildRequires: perl(Scalar::Util)
BuildRequires: perl(IO::Handle)
BuildRequires: perl(XML::LibXML) >= 1.62
BuildRequires: perl(common::sense)
BuildRequires: perl(Pragmatic)
BuildRequires: perl(Carp)
Requires: perl(Scalar::Util)
Requires: perl(IO::Handle)
Requires: perl(XML::LibXML) >= 1.62
Requires: perl(common::sense)
Requires: perl(Pragmatic)
Requires: perl(Carp)
%if 0%{?suse_version} >= 1120
BuildArch: noarch
%endif
%description
Long XML files can be daunting for humans to read. Of course, XML is
really designed for computers to read - not people - but there are times
when mere mortals do need to read and edit XML by hand. For example, if
your application stores its configuration in XML, or you need to dump some
XML to STDOUT for debugging purposes.
Syntax highlighting helps, but to really make sense of some XML, proper
indentation can be vital. Hence "XML::LibXML::PrettyPrint" - it can be
applied to an XML::LibXML DOM tree to reformat it into a more readable
result.
Pretty-printing XML is not as CPU-efficient as dumping it out sloppily, so
unless you're pretty sure that a human is going to need to make sense of
your XML, you should probably not use this module.
%prep
%setup -q -n "XML-LibXML-PrettyPrint-%{version}"
%__sed -i '/^auto_install/d' Makefile.PL
%build
%__perl Makefile.PL PREFIX="%{_prefix}"
%__make %{?_smp_flags}
%install
%perl_make_install
%perl_process_packlist
%check
%__make test
%clean
%{?buildroot:%__rm -rf "%{buildroot}"}
%files
%defattr(-,root,root)
%doc README LICENSE Changes
%dir %{perl_vendorlib}/XML
%dir %{perl_vendorlib}/XML/LibXML
%{perl_vendorlib}/XML/LibXML/PrettyPrint.pm
%doc %{perl_man3dir}/XML::LibXML::PrettyPrint.%{perl_man3ext}%{ext_man}
%changelog