2009-06-20 17:21:29 +00:00
|
|
|
#
|
2010-09-28 12:38:30 +00:00
|
|
|
# spec file for package perl-JSON (Version 2.26)
|
2010-09-06 08:23:40 +00:00
|
|
|
#
|
|
|
|
# Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
2009-06-20 17:21:29 +00:00
|
|
|
#
|
|
|
|
# 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/
|
2010-09-06 08:23:40 +00:00
|
|
|
#
|
|
|
|
|
|
|
|
# norootforbuild
|
|
|
|
|
|
|
|
%bcond_with pod
|
2009-06-20 17:21:29 +00:00
|
|
|
|
|
|
|
Name: perl-JSON
|
2010-09-06 08:23:40 +00:00
|
|
|
%define cpan_name JSON
|
2009-06-20 17:21:29 +00:00
|
|
|
Summary: JSON (JavaScript Object Notation) encoder/decoder
|
2011-03-08 11:49:18 +00:00
|
|
|
Version: 2.51
|
2010-12-10 11:06:51 +00:00
|
|
|
Release: 2
|
2010-09-06 08:23:40 +00:00
|
|
|
License: GPL+ or Artistic
|
2010-08-25 07:14:07 +00:00
|
|
|
Group: Development/Libraries/Perl
|
2010-09-06 08:23:40 +00:00
|
|
|
Url: http://search.cpan.org/dist/JSON/
|
2010-09-28 12:38:30 +00:00
|
|
|
# http://search.cpan.org/CPAN/authors/id/M/MA/MAKAMAKA/JSON-%{version}.tar.gz
|
2010-09-06 08:23:40 +00:00
|
|
|
Source: %{cpan_name}-%{version}.tar.bz2
|
|
|
|
BuildArch: noarch
|
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
2010-12-03 14:39:21 +00:00
|
|
|
%{perl_requires}
|
2010-09-06 08:23:40 +00:00
|
|
|
BuildRequires: perl
|
|
|
|
BuildRequires: perl-macros
|
|
|
|
%if %{with pod}
|
2009-06-20 17:21:29 +00:00
|
|
|
BuildRequires: perl(Test::Pod) >= 1.00
|
2010-09-06 08:23:40 +00:00
|
|
|
%endif
|
2010-08-25 07:14:07 +00:00
|
|
|
BuildRequires: perl(JSON::XS) >= 2.27
|
2010-09-06 08:23:40 +00:00
|
|
|
BuildRequires: perl(Test::More)
|
2010-08-25 07:14:07 +00:00
|
|
|
Recommends: perl(JSON::XS) >= 2.27
|
2007-09-18 14:41:53 +00:00
|
|
|
|
|
|
|
%description
|
2010-08-25 07:14:07 +00:00
|
|
|
JSON (JavaScript Object Notation) is a simple data format. See to
|
|
|
|
http://www.json.org/ and RFC4627(http://www.ietf.org/rfc/rfc4627.txt).
|
2009-06-20 17:21:29 +00:00
|
|
|
|
2010-08-25 07:14:07 +00:00
|
|
|
This module converts Perl data structures to JSON and vice versa using either
|
|
|
|
JSON::XS or JSON::PP.
|
2007-09-18 14:41:53 +00:00
|
|
|
|
2010-08-25 07:14:07 +00:00
|
|
|
JSON::XS is the fastest and most proper JSON module on CPAN which must be
|
|
|
|
compiled and installed in your environment. JSON::PP is a pure-Perl module
|
|
|
|
which is bundled in this distribution and has a strong compatibility to
|
|
|
|
JSON::XS.
|
2009-06-20 17:21:29 +00:00
|
|
|
|
2010-08-25 07:14:07 +00:00
|
|
|
This module try to use JSON::XS by default and fail to it, use JSON::PP
|
|
|
|
instead. So its features completely depend on JSON::XS or JSON::PP.
|
2009-06-20 17:21:29 +00:00
|
|
|
|
2010-09-06 08:23:40 +00:00
|
|
|
Authors:
|
|
|
|
--------
|
|
|
|
Makamaka Hannyaharamitu, <makamaka[at]cpan.org>
|
|
|
|
|
2007-09-18 14:41:53 +00:00
|
|
|
%prep
|
2010-09-06 08:23:40 +00:00
|
|
|
%setup -q -n %{cpan_name}-%{version}
|
2007-09-18 14:41:53 +00:00
|
|
|
|
|
|
|
%build
|
2010-09-06 08:23:40 +00:00
|
|
|
%{__perl} Makefile.PL INSTALLDIRS=vendor
|
|
|
|
%{__make} %{?_smp_mflags}
|
|
|
|
|
|
|
|
%check
|
|
|
|
%{__make} test
|
2007-09-18 14:41:53 +00:00
|
|
|
|
|
|
|
%install
|
2009-06-20 17:21:29 +00:00
|
|
|
%perl_make_install
|
2010-09-06 08:23:40 +00:00
|
|
|
# do not perl_process_packlist (noarch)
|
|
|
|
# remove .packlist file
|
|
|
|
%{__rm} -rf $RPM_BUILD_ROOT%perl_vendorarch
|
|
|
|
# remove perllocal.pod file
|
|
|
|
%{__rm} -rf $RPM_BUILD_ROOT%perl_archlib
|
|
|
|
%perl_gen_filelist
|
2010-08-25 07:14:07 +00:00
|
|
|
|
|
|
|
%clean
|
2010-09-06 08:23:40 +00:00
|
|
|
%{__rm} -rf $RPM_BUILD_ROOT
|
2007-09-18 14:41:53 +00:00
|
|
|
|
2010-09-06 08:23:40 +00:00
|
|
|
%files -f %{name}.files
|
|
|
|
%defattr(-,root,root,-)
|
2007-09-18 14:41:53 +00:00
|
|
|
%doc Changes README
|
|
|
|
|
2010-09-06 08:23:40 +00:00
|
|
|
%changelog
|