Update to 1.29
- New upstream release 1.29 - Upstreamed fix for test failures on PPC and ARM (CPAN RT#83825) - Fix crash in syck_emit on platforms with long long pointers - Use %license
This commit is contained in:
parent
03bfee15f9
commit
e8dc7939a8
@ -1,94 +0,0 @@
|
|||||||
From f646fa6ce15984b4a7d3c7b633be4129ad00c407 Mon Sep 17 00:00:00 2001
|
|
||||||
From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= <ppisar@redhat.com>
|
|
||||||
Date: Fri, 8 Mar 2013 13:00:52 +0100
|
|
||||||
Subject: [PATCH] Recognize all wide unicode characters
|
|
||||||
|
|
||||||
Type cast explicitly to (signed char) because sizof(char) can differ
|
|
||||||
from sizof(int). Also do not quote bytes above 0x7F because we assume
|
|
||||||
UTF-8 encoding.
|
|
||||||
|
|
||||||
This should be fixed properly by UTF-8 to Unicode decoding but we
|
|
||||||
need to recognize which encoding is in use before. How?
|
|
||||||
---
|
|
||||||
emitter.c | 22 +++++++++++-----------
|
|
||||||
syck.h | 2 +-
|
|
||||||
2 files changed, 12 insertions(+), 12 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/emitter.c b/emitter.c
|
|
||||||
index 48141b3..1d1a609 100644
|
|
||||||
--- a/emitter.c
|
|
||||||
+++ b/emitter.c
|
|
||||||
@@ -16,9 +16,9 @@
|
|
||||||
|
|
||||||
#define DEFAULT_ANCHOR_FORMAT "id%03d"
|
|
||||||
|
|
||||||
-const char hex_table[] =
|
|
||||||
+const unsigned char hex_table[] =
|
|
||||||
"0123456789ABCDEF";
|
|
||||||
-static char b64_table[] =
|
|
||||||
+static unsigned char b64_table[] =
|
|
||||||
"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
|
|
||||||
|
|
||||||
/*
|
|
||||||
@@ -598,12 +598,12 @@ syck_scan_scalar( int req_width, char *cursor, long len )
|
|
||||||
/* scan string */
|
|
||||||
for ( i = 0; i < len; i++ ) {
|
|
||||||
|
|
||||||
- if ( ! ( (unsigned)cursor[i] == 0x9 ||
|
|
||||||
- (unsigned)cursor[i] == 0xA ||
|
|
||||||
- (unsigned)cursor[i] == 0xD ||
|
|
||||||
- ( (unsigned)cursor[i] >= 0x20 && (unsigned)cursor[i] <= 0x7E ) ||
|
|
||||||
- (unsigned)cursor[i] == 0x85 ||
|
|
||||||
- (unsigned)cursor[i] >= 0xa0 )
|
|
||||||
+ if ( ! ( (unsigned char)cursor[i] == 0x9 ||
|
|
||||||
+ (unsigned char)cursor[i] == 0xA ||
|
|
||||||
+ (unsigned char)cursor[i] == 0xD ||
|
|
||||||
+ ( (unsigned char)cursor[i] >= 0x20 &&
|
|
||||||
+ (unsigned char)cursor[i] <= 0x7E ) ||
|
|
||||||
+ (unsigned char)cursor[i] >= 0x80 )
|
|
||||||
) {
|
|
||||||
flags |= SCAN_NONPRINT;
|
|
||||||
}
|
|
||||||
@@ -812,7 +812,7 @@ void syck_emit_scalar( SyckEmitter *e, char *tag, enum scalar_style force_style,
|
|
||||||
}
|
|
||||||
|
|
||||||
void
|
|
||||||
-syck_emitter_escape( SyckEmitter *e, char *src, long len )
|
|
||||||
+syck_emitter_escape( SyckEmitter *e, unsigned char *src, long len )
|
|
||||||
{
|
|
||||||
int i;
|
|
||||||
for( i = 0; i < len; i++ )
|
|
||||||
@@ -927,7 +927,7 @@ void syck_emit_2quoted_1( SyckEmitter *e, int width, char *str, long len )
|
|
||||||
break;
|
|
||||||
|
|
||||||
default:
|
|
||||||
- syck_emitter_escape( e, mark, 1 );
|
|
||||||
+ syck_emitter_escape( e, (unsigned char *)mark, 1 );
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
mark++;
|
|
||||||
@@ -990,7 +990,7 @@ void syck_emit_2quoted( SyckEmitter *e, int width, char *str, long len )
|
|
||||||
break;
|
|
||||||
|
|
||||||
default:
|
|
||||||
- syck_emitter_escape( e, mark, 1 );
|
|
||||||
+ syck_emitter_escape( e, (unsigned char*)mark, 1 );
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
mark++;
|
|
||||||
diff --git a/syck.h b/syck.h
|
|
||||||
index 2886561..f5118cd 100644
|
|
||||||
--- a/syck.h
|
|
||||||
+++ b/syck.h
|
|
||||||
@@ -411,7 +411,7 @@ void syck_emitter_handler( SyckEmitter *, SyckEmitterHandler );
|
|
||||||
void syck_free_emitter( SyckEmitter * );
|
|
||||||
void syck_emitter_clear( SyckEmitter * );
|
|
||||||
void syck_emitter_write( SyckEmitter *, const char *, long );
|
|
||||||
-void syck_emitter_escape( SyckEmitter *, char *, long );
|
|
||||||
+void syck_emitter_escape( SyckEmitter *, unsigned char *, long );
|
|
||||||
void syck_emitter_flush( SyckEmitter *, long );
|
|
||||||
void syck_emit( SyckEmitter *, st_data_t );
|
|
||||||
void syck_emit_scalar( SyckEmitter *, char *, enum scalar_style, int, int, char, char *, long );
|
|
||||||
--
|
|
||||||
1.8.1.4
|
|
||||||
|
|
@ -1,12 +1,11 @@
|
|||||||
Name: perl-YAML-Syck
|
Name: perl-YAML-Syck
|
||||||
Version: 1.28
|
Version: 1.29
|
||||||
Release: 1%{?dist}
|
Release: 1%{?dist}
|
||||||
Summary: Fast, lightweight YAML loader and dumper
|
Summary: Fast, lightweight YAML loader and dumper
|
||||||
License: BSD and MIT
|
License: BSD and MIT
|
||||||
Group: Development/Libraries
|
Group: Development/Libraries
|
||||||
URL: http://search.cpan.org/dist/YAML-Syck/
|
URL: http://search.cpan.org/dist/YAML-Syck/
|
||||||
Source0: http://www.cpan.org/authors/id/T/TO/TODDR/YAML-Syck-%{version}.tar.gz
|
Source0: http://www.cpan.org/authors/id/T/TO/TODDR/YAML-Syck-%{version}.tar.gz
|
||||||
Patch0: 0001-Recognize-all-wide-unicode-characters.patch
|
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(id -nu)
|
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(id -nu)
|
||||||
BuildRequires: perl
|
BuildRequires: perl
|
||||||
# Keep bundled inc::Module::Install to break cycle
|
# Keep bundled inc::Module::Install to break cycle
|
||||||
@ -46,9 +45,6 @@ structures to YAML strings, and the other way around.
|
|||||||
%setup -q -n YAML-Syck-%{version}
|
%setup -q -n YAML-Syck-%{version}
|
||||||
rm -rf inc/parent.pm inc/PerlIO.pm inc/Scalar/Util.pm
|
rm -rf inc/parent.pm inc/PerlIO.pm inc/Scalar/Util.pm
|
||||||
|
|
||||||
# Work around test failures on PPC and ARM (#919806, CPAN RT#83825)
|
|
||||||
%patch0 -p1
|
|
||||||
|
|
||||||
%build
|
%build
|
||||||
perl Makefile.PL INSTALLDIRS=vendor OPTIMIZE="$RPM_OPT_FLAGS"
|
perl Makefile.PL INSTALLDIRS=vendor OPTIMIZE="$RPM_OPT_FLAGS"
|
||||||
make %{?_smp_mflags}
|
make %{?_smp_mflags}
|
||||||
@ -67,14 +63,21 @@ make test
|
|||||||
rm -rf $RPM_BUILD_ROOT
|
rm -rf $RPM_BUILD_ROOT
|
||||||
|
|
||||||
%files
|
%files
|
||||||
%doc Changes COMPATIBILITY COPYING README
|
%license COPYING
|
||||||
|
%doc Changes COMPATIBILITY README
|
||||||
%{perl_vendorarch}/auto/YAML/
|
%{perl_vendorarch}/auto/YAML/
|
||||||
%{perl_vendorarch}/YAML/
|
%{perl_vendorarch}/YAML/
|
||||||
%{perl_vendorarch}/JSON/
|
%{perl_vendorarch}/JSON/
|
||||||
%{_mandir}/man3/JSON::Syck.3pm*
|
%{_mandir}/man3/JSON::Syck.3*
|
||||||
%{_mandir}/man3/YAML::Syck.3pm*
|
%{_mandir}/man3/YAML::Syck.3*
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Tue Dec 16 2014 Paul Howarth <paul@city-fan.org> - 1.29-1
|
||||||
|
- Update to 1.29
|
||||||
|
- Upstreamed fix for test failures on PPC and ARM (CPAN RT#83825)
|
||||||
|
- Fix crash in syck_emit on platforms with long long pointers
|
||||||
|
- Use %%license
|
||||||
|
|
||||||
* Thu Dec 11 2014 Petr Pisar <ppisar@redhat.com> - 1.28-1
|
* Thu Dec 11 2014 Petr Pisar <ppisar@redhat.com> - 1.28-1
|
||||||
- 1.28 bump
|
- 1.28 bump
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user