- Ruby 2.0 strictly enforces encoding

Add ruby-2.0-encoding-utf8.patch

OBS-URL: https://build.opensuse.org/package/show/devel:tools:building/swig?expand=0&rev=51
This commit is contained in:
Klaus Kämpf 2013-05-28 13:04:53 +00:00 committed by Git OBS Bridge
parent 004052a460
commit 5c89de63fc
3 changed files with 21 additions and 0 deletions

View File

@ -0,0 +1,12 @@
diff -wruN -x '*~' -x '*.o' -x '*.a' -x '*.so' -x '*.so.[0-9]' -x autom4te.cache -x .deps -x .libs -x Makefile -x Makefile ../orig-swig-2.0.10/Examples/test-suite/ruby/char_constant_runme.rb ./Examples/test-suite/ruby/char_constant_runme.rb
--- ../orig-swig-2.0.10/Examples/test-suite/ruby/char_constant_runme.rb 2013-05-27 20:24:04.000000000 +0200
+++ ./Examples/test-suite/ruby/char_constant_runme.rb 2013-05-28 14:48:44.924421929 +0200
@@ -28,7 +28,7 @@
raise RuntimeError, "Invalid value for NULL_CONST."
end
-if Char_constant::SPECIALCHAR != "\341" #'á'
+if Char_constant::SPECIALCHAR.ord != 225 # "\341" #'á'
raise RuntimeError, "Invalid value for SPECIALCHAR."
end

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Tue May 28 13:04:21 UTC 2013 - kkaempf@suse.com
- Ruby 2.0 strictly enforces encoding
Add ruby-2.0-encoding-utf8.patch
-------------------------------------------------------------------
Tue May 28 06:43:48 UTC 2013 - kkaempf@suse.com

View File

@ -33,6 +33,8 @@ Patch6: 0008-Ruby-Disable-broken-tests.patch
Patch8: skip-python-li_std_containers_int.patch
# Fix the return type in declaration of caml_array_length
Patch9: swig-fix_ocaml_type.patch
# Ruby 2.0 encodes to UTF-8, SWIG to US-ASCII-8BIT
Patch10: ruby-2.0-encoding-utf8.patch
BuildRequires: autoconf
BuildRequires: automake
BuildRequires: boost-devel
@ -134,6 +136,7 @@ understandig SWIG usage.
%patch8 -p1
%endif
%patch9
%patch10 -p1
%build
%configure --disable-ccache