[perl-Cpanel-JSON-XS] Initial import (perl-Cpanel-JSON-XS-2.3404-2)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



commit f40360d1204c6f1c4a42374f407c7e99915dbf03
Author: Paul Howarth <paul@xxxxxxxxxxxx>
Date:   Thu Apr 10 15:20:44 2014 +0100

    Initial import (perl-Cpanel-JSON-XS-2.3404-2)
    
    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. To
    reach the latter goal it was written in C.

 .gitignore                          |    1 +
 Cpanel-JSON-XS-2.3404-no-clzf.patch |   37 ++++++++++++
 perl-Cpanel-JSON-XS.spec            |  105 +++++++++++++++++++++++++++++++++++
 sources                             |    1 +
 4 files changed, 144 insertions(+), 0 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index e69de29..db3f510 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/Cpanel-JSON-XS-[0-9.]*.tar.gz
diff --git a/Cpanel-JSON-XS-2.3404-no-clzf.patch b/Cpanel-JSON-XS-2.3404-no-clzf.patch
new file mode 100644
index 0000000..61a8971
--- /dev/null
+++ b/Cpanel-JSON-XS-2.3404-no-clzf.patch
@@ -0,0 +1,37 @@
+diff -Naur old/bin/cpanel_json_xs new/bin/cpanel_json_xs
+--- old/bin/cpanel_json_xs	2013-11-12 08:26:09.000000000 +1100
++++ new/bin/cpanel_json_xs	2014-04-10 18:02:15.694903565 +1000
+@@ -40,8 +40,6 @@
+ 
+ =item bencode - use Convert::Bencode, if available (used by torrent files, among others)
+ 
+-=item clzf - Compress::LZF format (requires that module to be installed)
+-
+ =item eval - evaluate the given code as (non-utf-8) Perl, basically the reverse of "-t dump"
+ 
+ =item yaml - YAML (avoid at all costs, requires the YAML module :)
+@@ -74,8 +72,6 @@
+ 
+ =item bencode - use Convert::Bencode, if available (used by torrent files, among others)
+ 
+-=item clzf - Compress::LZF format
+-
+ =item yaml - YAML
+ 
+ =item dump - Data::Dump
+@@ -176,7 +172,6 @@
+    "storable"      => sub { Storable::thaw $_ },
+    "storable-file" => sub { open my $fh, "<", \$_; Storable::fd_retrieve $fh },
+    "bencode"       => sub { require Convert::Bencode; Convert::Bencode::bdecode ($_) },
+-   "clzf"          => sub { require Compress::LZF; Compress::LZF::sthaw ($_) },
+    "yaml"          => sub { require YAML; YAML::Load ($_) },
+    "eval"          => sub { my $v = eval "no strict; no warnings; no utf8;\n#line 1 \"input\"\n$_"; die "$@" if $@; $v },
+ );
+@@ -196,7 +191,6 @@
+    "storable-file" => sub { open my $fh, ">", \my $buf; Storable::nstore_fd $_, $fh; $buf },
+ 
+    "bencode"       => sub { require Convert::Bencode; Convert::Bencode::bencode ($_) },
+-   "clzf"          => sub { require Compress::LZF; Compress::LZF::sfreeze_cr ($_) },
+    "yaml"          => sub { require YAML; YAML::Dump ($_) },
+    "dumper"        => sub {
+       require Data::Dumper;
diff --git a/perl-Cpanel-JSON-XS.spec b/perl-Cpanel-JSON-XS.spec
new file mode 100644
index 0000000..7a63993
--- /dev/null
+++ b/perl-Cpanel-JSON-XS.spec
@@ -0,0 +1,105 @@
+# Note: Compress::LZF format support has been disabled until such
+# time as the Compress::LZF module becomes available in Fedora (#1074129)
+
+Name:		perl-Cpanel-JSON-XS
+Summary:	JSON::XS for Cpanel, fast and correct serializing
+Version:	2.3404
+Release:	2%{?dist}
+License:	GPL+ or Artistic
+URL:		http://search.cpan.org/dist/Cpanel-JSON-XS/
+Source0:	http://search.cpan.org/CPAN/authors/id/R/RU/RURBAN/Cpanel-JSON-XS-%{version}.tar.gz
+Patch0:		Cpanel-JSON-XS-2.3404-no-clzf.patch
+# Module Build
+BuildRequires:	perl
+BuildRequires:	perl(ExtUtils::MakeMaker)
+# Module Runtime
+BuildRequires:	perl(Carp)
+BuildRequires:	perl(Exporter)
+BuildRequires:	perl(overload)
+BuildRequires:	perl(XSLoader)
+# Script Runtime
+#BuildRequires:	perl(Compress::LZF)
+BuildRequires:	perl(Convert::Bencode)
+BuildRequires:	perl(Data::Dump)
+BuildRequires:	perl(YAML)
+# Test Suite
+BuildRequires:	perl(common::sense) >= 3.5
+BuildRequires:	perl(Config)
+BuildRequires:	perl(Data::Dumper)
+BuildRequires:	perl(Encode) >= 1.9081
+BuildRequires:	perl(Hash::Util)
+BuildRequires:	perl(strict)
+BuildRequires:	perl(Test)
+BuildRequires:	perl(Test::More)
+BuildRequires:	perl(Tie::Array)
+BuildRequires:	perl(Tie::Hash)
+BuildRequires:	perl(utf8)
+BuildRequires:	perl(warnings)
+# Maintainer Tests
+BuildRequires:	perl(File::Copy)
+BuildRequires:	perl(Perl::MinimumVersion) >= 1.20
+BuildRequires:	perl(Test::CPAN::Meta) >= 0.12
+BuildRequires:	perl(Test::Kwalitee)
+BuildRequires:	perl(Test::MinimumVersion) >= 0.008
+BuildRequires:	perl(Test::Pod) >= 1.00
+BuildRequires:	perl(Test::Pod::Coverage) >= 1.04
+# Runtime
+Requires:	perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version))
+Requires:	perl(Carp)
+#Requires:	perl(Compress::LZF)
+Requires:	perl(Convert::Bencode)
+Requires:	perl(Data::Dump)
+Requires:	perl(YAML)
+
+# Avoid unwanted provides and dependencies
+%{?perl_default_filter}
+
+%description
+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. To
+reach the latter goal it was written in C.
+
+%prep
+%setup -q -n Cpanel-JSON-XS-%{version}
+
+# Drop CLZF support for now
+%patch0 -p1
+
+# Fix shellbangs
+perl -pi -e 's|^#!/opt/bin/perl|#!/usr/bin/perl|' eg/*
+
+# Make sure we don't try to do a signature check
+rm SIGNATURE
+perl -ni -e 'print unless /SIGNATURE/;' MANIFEST
+
+%build
+perl Makefile.PL INSTALLDIRS=vendor OPTIMIZE="%{optflags}"
+make %{?_smp_mflags}
+
+%install
+make pure_install DESTDIR=%{buildroot}
+find %{buildroot} -type f -name .packlist -exec rm -f {} ';'
+find %{buildroot} -type f -name '*.bs' -a -size 0 -exec rm -f {} ';'
+%{_fixperms} %{buildroot}
+
+%check
+make test IS_MAINTAINER=1 RELEASE_TESTING=1
+
+%files
+%doc Changes COPYING README eg/
+%{_bindir}/cpanel_json_xs
+%{perl_vendorarch}/auto/Cpanel/
+%{perl_vendorarch}/Cpanel/
+%{_mandir}/man1/cpanel_json_xs.1*
+%{_mandir}/man3/Cpanel::JSON::XS.3pm*
+%{_mandir}/man3/Cpanel::JSON::XS::Boolean.3pm*
+
+%changelog
+* Thu Apr 10 2014 Paul Howarth <paul@xxxxxxxxxxxx> - 2.3404-2
+- Incorporate feedback from package review (#1085975)
+  - Simplify %%summary
+  - Temporarily drop Compress::LZF format support from cpanel_json_xs client
+  - Add optional dependencies for module, tests and cpanel_json_xs client
+
+* Wed Apr  9 2014 Paul Howarth <paul@xxxxxxxxxxxx> - 2.3404-1
+- Initial RPM version
diff --git a/sources b/sources
index e69de29..389ae68 100644
--- a/sources
+++ b/sources
@@ -0,0 +1 @@
+6fa33e4f6d5b16bcec62e3340c198437  Cpanel-JSON-XS-2.3404.tar.gz
--
Fedora Extras Perl SIG
http://www.fedoraproject.org/wiki/Extras/SIGs/Perl
perl-devel mailing list
perl-devel@xxxxxxxxxxxxxxxxxxxxxxx
https://admin.fedoraproject.org/mailman/listinfo/perl-devel





[Index of Archives]     [Fedora Announce]     [Fedora Kernel]     [Fedora Testing]     [Fedora Legacy Announce]     [Fedora PHP Devel]     [Kernel Devel]     [Fedora Legacy]     [Fedora Maintainers]     [Fedora Desktop]     [PAM]     [Red Hat Development]     [Big List of Linux Books]     [Gimp]     [Yosemite Information]
  Powered by Linux