2009-06-20 17:21:06 +00:00
|
|
|
#
|
2011-08-13 19:51:21 +00:00
|
|
|
# spec file for package perl-JSON-XS
|
2010-09-08 23:29:34 +00:00
|
|
|
#
|
2011-08-13 19:51:21 +00:00
|
|
|
# Copyright (c) 2011 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
2009-06-20 17:21:06 +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.
|
2008-12-11 13:03:40 +00:00
|
|
|
|
2009-06-20 17:21:06 +00:00
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
|
|
|
#
|
|
|
|
|
|
|
|
|
|
# norootforbuild
|
|
|
|
|
|
2010-11-10 20:43:13 +00:00
|
|
|
|
2009-06-20 17:21:06 +00:00
|
|
|
Name: perl-JSON-XS
|
2010-09-08 23:29:34 +00:00
|
|
|
%define cpan_name JSON-XS
|
2009-06-20 17:21:06 +00:00
|
|
|
Summary: JSON serialising/deserialising, done correctly and fast
|
2011-08-13 19:51:21 +00:00
|
|
|
Version: 2.32
|
2011-01-17 20:10:11 +00:00
|
|
|
Release: 1
|
2010-09-08 23:29:34 +00:00
|
|
|
License: GPL+ or Artistic
|
2009-06-20 17:21:06 +00:00
|
|
|
Group: Development/Libraries/Perl
|
2010-09-08 23:29:34 +00:00
|
|
|
Url: http://search.cpan.org/dist/JSON-XS/
|
2011-08-13 19:51:21 +00:00
|
|
|
# http://search.cpan.org/CPAN/authors/id/M/ML/MLEHMANN/JSON-XS-%{version}.tar.gz
|
2011-11-17 15:37:02 +00:00
|
|
|
Source: %{cpan_name}-%{version}.tar.gz
|
2009-06-20 17:21:06 +00:00
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
2010-12-03 14:39:31 +00:00
|
|
|
%{perl_requires}
|
2009-06-20 17:21:06 +00:00
|
|
|
BuildRequires: perl
|
2010-09-08 23:29:34 +00:00
|
|
|
BuildRequires: perl-macros
|
|
|
|
|
BuildRequires: perl(common::sense)
|
|
|
|
|
Requires: perl(common::sense)
|
2009-06-20 17:21:06 +00:00
|
|
|
|
2008-12-11 13:03:40 +00:00
|
|
|
%description
|
2009-06-20 17:21:06 +00:00
|
|
|
This module converts Perl data structures to JSON and vice versa. Its
|
|
|
|
|
primary goal is to be *correct* and its secondary goal is to be *fast*.
|
2008-12-11 13:03:40 +00:00
|
|
|
To reach the latter goal it was written in C.
|
|
|
|
|
|
2009-06-20 17:21:06 +00:00
|
|
|
Beginning with version 2.0 of the JSON module, when both JSON and
|
|
|
|
|
JSON::XS are installed, then JSON will fall back on JSON::XS (this can
|
|
|
|
|
be overridden) with no overhead due to emulation (by inheriting
|
|
|
|
|
constructor and methods). If JSON::XS is not available, it will fall
|
|
|
|
|
back to the compatible JSON::PP module as backend, so using JSON instead
|
|
|
|
|
of JSON::XS gives you a portable JSON API that can be fast when you need
|
|
|
|
|
and doesn`t require a C compiler when that is a problem.
|
|
|
|
|
|
|
|
|
|
As this is the n-th-something JSON module on CPAN, what was the reason
|
|
|
|
|
to write yet another JSON module? While it seems there are many JSON
|
|
|
|
|
modules, none of them correctly handle all corner cases, and in most
|
|
|
|
|
cases their maintainers are unresponsive, gone missing, or not listening
|
|
|
|
|
to bug reports for other reasons.
|
|
|
|
|
|
2010-09-08 23:29:34 +00:00
|
|
|
Author:
|
|
|
|
|
-------
|
|
|
|
|
Marc Lehmann <schmorp@schmorp.de>
|
2009-06-20 17:21:06 +00:00
|
|
|
|
2008-12-11 13:03:40 +00:00
|
|
|
%prep
|
2011-08-13 19:51:21 +00:00
|
|
|
%setup -q -n %{cpan_name}-%{version}
|
2008-12-11 13:03:40 +00:00
|
|
|
|
|
|
|
|
%build
|
2010-09-08 23:29:34 +00:00
|
|
|
%{__perl} Makefile.PL INSTALLDIRS=vendor OPTIMIZE="$RPM_OPT_FLAGS"
|
|
|
|
|
%{__make} %{?_smp_mflags}
|
2008-12-11 13:03:40 +00:00
|
|
|
|
2009-06-20 17:21:06 +00:00
|
|
|
%check
|
|
|
|
|
%{__make} test
|
|
|
|
|
|
2008-12-11 13:03:40 +00:00
|
|
|
%install
|
2009-06-20 17:21:06 +00:00
|
|
|
%perl_make_install
|
2008-12-11 13:03:40 +00:00
|
|
|
%perl_process_packlist
|
2009-06-20 17:21:06 +00:00
|
|
|
%perl_gen_filelist
|
2008-12-11 13:03:40 +00:00
|
|
|
|
2010-09-08 23:29:34 +00:00
|
|
|
%clean
|
2009-06-20 17:21:06 +00:00
|
|
|
%{__rm} -rf $RPM_BUILD_ROOT
|
2008-12-11 13:03:40 +00:00
|
|
|
|
2009-06-20 17:21:06 +00:00
|
|
|
%files -f %{name}.files
|
2010-09-08 23:29:34 +00:00
|
|
|
%defattr(-,root,root,-)
|
|
|
|
|
%doc Changes COPYING README
|
2009-06-20 17:21:06 +00:00
|
|
|
|
|
|
|
|
%changelog
|