Accepting request 808351 from home:Andreas_Schwab:Factory
- Revert last change - ruby-std-wstring-byte-order.patch: fix wstring encoding OBS-URL: https://build.opensuse.org/request/show/808351 OBS-URL: https://build.opensuse.org/package/show/devel:tools:building/swig?expand=0&rev=120
This commit is contained in:
parent
9cfa3c7a7d
commit
b6398419fa
@ -1,25 +0,0 @@
|
||||
From: Michel Normand <normand@linux.vnet.ibm.com>
|
||||
Subject: 0005 disable li_std_wstring
|
||||
Date: Mon, 18 May 2020 17:05:27 +0200
|
||||
|
||||
disable li_std_wstring to avoid test failure
|
||||
for BE (ppc64 & s390x) as per bug
|
||||
https://bugzilla.opensuse.org/show_bug.cgi?id=1171368
|
||||
|
||||
Signed-off-by: Michel Normand <normand@linux.vnet.ibm.com>
|
||||
---
|
||||
Examples/test-suite/common.mk | 1 -
|
||||
1 file changed, 1 deletion(-)
|
||||
|
||||
Index: swig-rel-4.0.1/Examples/test-suite/common.mk
|
||||
===================================================================
|
||||
--- swig-rel-4.0.1.orig/Examples/test-suite/common.mk
|
||||
+++ swig-rel-4.0.1/Examples/test-suite/common.mk
|
||||
@@ -657,7 +657,6 @@ CPP_STD_TEST_CASES += \
|
||||
li_std_vector_enum \
|
||||
li_std_vector_member_var\
|
||||
li_std_vector_ptr \
|
||||
- li_std_wstring \
|
||||
smart_pointer_inherit \
|
||||
template_typedef_fnc \
|
||||
template_type_namespace \
|
29
ruby-std-wstring-byte-order.patch
Normal file
29
ruby-std-wstring-byte-order.patch
Normal file
@ -0,0 +1,29 @@
|
||||
Index: swig-rel-4.0.1/Lib/ruby/std_wstring.i
|
||||
===================================================================
|
||||
--- swig-rel-4.0.1.orig/Lib/ruby/std_wstring.i
|
||||
+++ swig-rel-4.0.1/Lib/ruby/std_wstring.i
|
||||
@@ -1,4 +1,6 @@
|
||||
%{
|
||||
+#include <endian.h>
|
||||
+
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
@@ -15,9 +17,17 @@ extern "C" {
|
||||
#ifndef SWIG_RUBY_WSTRING_ENCODING
|
||||
|
||||
#if WCHAR_MAX == 0x7fff || WCHAR_MAX == 0xffff
|
||||
+#if BYTE_ORDER == LITTLE_ENDIAN
|
||||
#define SWIG_RUBY_WSTRING_ENCODING "UTF-16LE"
|
||||
+#elif BYTE_ORDER == BIG_ENDIAN
|
||||
+#define SWIG_RUBY_WSTRING_ENCODING "UTF-16BE"
|
||||
+#endif
|
||||
#elif WCHAR_MAX == 0x7fffffff || WCHAR_MAX == 0xffffffff
|
||||
+#if BYTE_ORDER == LITTLE_ENDIAN
|
||||
#define SWIG_RUBY_WSTRING_ENCODING "UTF-32LE"
|
||||
+#elif BYTE_ORDER == BIG_ENDIAN
|
||||
+#define SWIG_RUBY_WSTRING_ENCODING "UTF-32BE"
|
||||
+#endif
|
||||
#else
|
||||
#error unsupported wchar_t size. SWIG_RUBY_WSTRING_ENCODING must be given.
|
||||
#endif
|
@ -1,3 +1,9 @@
|
||||
-------------------------------------------------------------------
|
||||
Sat May 23 07:04:09 UTC 2020 - Andreas Schwab <schwab@suse.de>
|
||||
|
||||
- Revert last change
|
||||
- ruby-std-wstring-byte-order.patch: fix wstring encoding
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon May 18 15:46:46 UTC 2020 - Michel Normand <normand@linux.vnet.ibm.com>
|
||||
|
||||
|
13
swig.spec
13
swig.spec
@ -42,8 +42,8 @@ Patch1: 0001-Fix-code-generated-for-Ruby-global-variables.patch
|
||||
Patch2: 0002-Add-support-for-Ruby-2.7.patch
|
||||
Patch3: 0003-Move-new-macros-for-Ruby-to-their-dedicated-namespac.patch
|
||||
Patch4: 0004-Improve-description-of-cast-macros-for-Ruby.patch
|
||||
Patch5: 0005-disable_li_std_wstring.patch
|
||||
|
||||
Patch300: ruby-std-wstring-byte-order.patch
|
||||
Patch308: swig308-isfinite.diff
|
||||
|
||||
BuildRequires: autoconf
|
||||
@ -120,18 +120,7 @@ understandig SWIG usage.
|
||||
|
||||
%prep
|
||||
%setup -q -n %{name}-rel-%{version}
|
||||
# for BE (Big Endian) do all patch (with 0005-disable_li_std_wstring.patch)
|
||||
# bypass https://bugzilla.opensuse.org/show_bug.cgi?id=1171368
|
||||
# for all other arches do all BUT that specific one
|
||||
%ifarch ppc64 s390 s390x
|
||||
%autopatch -p1
|
||||
%else
|
||||
%patch1 -p1
|
||||
%patch2 -p1
|
||||
%patch3 -p1
|
||||
%patch4 -p1
|
||||
%patch308 -p1
|
||||
%endif
|
||||
|
||||
%build
|
||||
%ifarch s390 s390x
|
||||
|
Loading…
Reference in New Issue
Block a user