xref: /OK3568_Linux_fs/yocto/meta-qt5/recipes-qt/qt5/qtwebkit/0008-Fix-build-with-icu-68.patch (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593SmuzhiyunFrom 0e94085f74b562bf8edf5418142323785a069454 Mon Sep 17 00:00:00 2001
2*4882a593SmuzhiyunFrom: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@gmail.com>
3*4882a593SmuzhiyunDate: Wed, 2 Dec 2020 22:34:54 +0100
4*4882a593SmuzhiyunSubject: [PATCH] Fix build with icu >= 68
5*4882a593SmuzhiyunMIME-Version: 1.0
6*4882a593SmuzhiyunContent-Type: text/plain; charset=UTF-8
7*4882a593SmuzhiyunContent-Transfer-Encoding: 8bit
8*4882a593Smuzhiyun
9*4882a593SmuzhiyunUpstream-Status: Pending
10*4882a593Smuzhiyun
11*4882a593SmuzhiyunSigned-off-by: Andreas Müller <schnitzeltony@gmail.com>
12*4882a593Smuzhiyun---
13*4882a593Smuzhiyun Source/WebCore/platform/text/TextCodecICU.cpp     | 15 +++++++++++++++
14*4882a593Smuzhiyun Source/WebCore/platform/text/icu/UTextProvider.h  | 15 +++++++++++++++
15*4882a593Smuzhiyun .../platform/text/icu/UTextProviderLatin1.cpp     | 15 +++++++++++++++
16*4882a593Smuzhiyun .../platform/text/icu/UTextProviderUTF16.cpp      | 15 +++++++++++++++
17*4882a593Smuzhiyun 4 files changed, 60 insertions(+)
18*4882a593Smuzhiyun
19*4882a593Smuzhiyundiff --git a/Source/WebCore/platform/text/TextCodecICU.cpp b/Source/WebCore/platform/text/TextCodecICU.cpp
20*4882a593Smuzhiyunindex dd6ff0675..7ce8a70ef 100644
21*4882a593Smuzhiyun--- a/Source/WebCore/platform/text/TextCodecICU.cpp
22*4882a593Smuzhiyun+++ b/Source/WebCore/platform/text/TextCodecICU.cpp
23*4882a593Smuzhiyun@@ -39,6 +39,21 @@
24*4882a593Smuzhiyun #include <wtf/text/StringBuilder.h>
25*4882a593Smuzhiyun #include <wtf/unicode/CharacterNames.h>
26*4882a593Smuzhiyun
27*4882a593Smuzhiyun+// Since icu 68.1 icu we have to:
28*4882a593Smuzhiyun+#ifndef TRUE
29*4882a593Smuzhiyun+// Taken from umachibe.h:
30*4882a593Smuzhiyun+/**
31*4882a593Smuzhiyun+ * The TRUE value of a UBool.
32*4882a593Smuzhiyun+ *
33*4882a593Smuzhiyun+ * @deprecated ICU 68 Use standard "true" instead.
34*4882a593Smuzhiyun+ */
35*4882a593Smuzhiyun+#   define TRUE  true
36*4882a593Smuzhiyun+#endif
37*4882a593Smuzhiyun+
38*4882a593Smuzhiyun+#ifndef FALSE
39*4882a593Smuzhiyun+#   define FALSE  false
40*4882a593Smuzhiyun+#endif
41*4882a593Smuzhiyun+
42*4882a593Smuzhiyun namespace WebCore {
43*4882a593Smuzhiyun
44*4882a593Smuzhiyun const size_t ConversionBufferSize = 16384;
45*4882a593Smuzhiyundiff --git a/Source/WebCore/platform/text/icu/UTextProvider.h b/Source/WebCore/platform/text/icu/UTextProvider.h
46*4882a593Smuzhiyunindex c254fc4c7..9d2ad8b8c 100644
47*4882a593Smuzhiyun--- a/Source/WebCore/platform/text/icu/UTextProvider.h
48*4882a593Smuzhiyun+++ b/Source/WebCore/platform/text/icu/UTextProvider.h
49*4882a593Smuzhiyun@@ -28,6 +28,21 @@
50*4882a593Smuzhiyun
51*4882a593Smuzhiyun #include <unicode/utext.h>
52*4882a593Smuzhiyun
53*4882a593Smuzhiyun+// Since icu 68.1 icu we have to:
54*4882a593Smuzhiyun+#ifndef TRUE
55*4882a593Smuzhiyun+// Taken from umachibe.h:
56*4882a593Smuzhiyun+/**
57*4882a593Smuzhiyun+ * The TRUE value of a UBool.
58*4882a593Smuzhiyun+ *
59*4882a593Smuzhiyun+ * @deprecated ICU 68 Use standard "true" instead.
60*4882a593Smuzhiyun+ */
61*4882a593Smuzhiyun+#   define TRUE  true
62*4882a593Smuzhiyun+#endif
63*4882a593Smuzhiyun+
64*4882a593Smuzhiyun+#ifndef FALSE
65*4882a593Smuzhiyun+#   define FALSE  false
66*4882a593Smuzhiyun+#endif
67*4882a593Smuzhiyun+
68*4882a593Smuzhiyun namespace WebCore {
69*4882a593Smuzhiyun
70*4882a593Smuzhiyun enum class UTextProviderContext {
71*4882a593Smuzhiyundiff --git a/Source/WebCore/platform/text/icu/UTextProviderLatin1.cpp b/Source/WebCore/platform/text/icu/UTextProviderLatin1.cpp
72*4882a593Smuzhiyunindex cd6852c71..0c95ea529 100644
73*4882a593Smuzhiyun--- a/Source/WebCore/platform/text/icu/UTextProviderLatin1.cpp
74*4882a593Smuzhiyun+++ b/Source/WebCore/platform/text/icu/UTextProviderLatin1.cpp
75*4882a593Smuzhiyun@@ -29,6 +29,21 @@
76*4882a593Smuzhiyun #include "UTextProvider.h"
77*4882a593Smuzhiyun #include <wtf/text/StringImpl.h>
78*4882a593Smuzhiyun
79*4882a593Smuzhiyun+// Since icu 68.1 icu we have to:
80*4882a593Smuzhiyun+#ifndef TRUE
81*4882a593Smuzhiyun+// Taken from umachibe.h:
82*4882a593Smuzhiyun+/**
83*4882a593Smuzhiyun+ * The TRUE value of a UBool.
84*4882a593Smuzhiyun+ *
85*4882a593Smuzhiyun+ * @deprecated ICU 68 Use standard "true" instead.
86*4882a593Smuzhiyun+ */
87*4882a593Smuzhiyun+#   define TRUE  true
88*4882a593Smuzhiyun+#endif
89*4882a593Smuzhiyun+
90*4882a593Smuzhiyun+#ifndef FALSE
91*4882a593Smuzhiyun+#   define FALSE  false
92*4882a593Smuzhiyun+#endif
93*4882a593Smuzhiyun+
94*4882a593Smuzhiyun namespace WebCore {
95*4882a593Smuzhiyun
96*4882a593Smuzhiyun // Latin1 provider
97*4882a593Smuzhiyundiff --git a/Source/WebCore/platform/text/icu/UTextProviderUTF16.cpp b/Source/WebCore/platform/text/icu/UTextProviderUTF16.cpp
98*4882a593Smuzhiyunindex 7aaac48c8..6ac693602 100644
99*4882a593Smuzhiyun--- a/Source/WebCore/platform/text/icu/UTextProviderUTF16.cpp
100*4882a593Smuzhiyun+++ b/Source/WebCore/platform/text/icu/UTextProviderUTF16.cpp
101*4882a593Smuzhiyun@@ -28,6 +28,21 @@
102*4882a593Smuzhiyun
103*4882a593Smuzhiyun #include "UTextProvider.h"
104*4882a593Smuzhiyun
105*4882a593Smuzhiyun+// Since icu 68.1 icu we have to:
106*4882a593Smuzhiyun+#ifndef TRUE
107*4882a593Smuzhiyun+// Taken from umachibe.h:
108*4882a593Smuzhiyun+/**
109*4882a593Smuzhiyun+ * The TRUE value of a UBool.
110*4882a593Smuzhiyun+ *
111*4882a593Smuzhiyun+ * @deprecated ICU 68 Use standard "true" instead.
112*4882a593Smuzhiyun+ */
113*4882a593Smuzhiyun+#   define TRUE  true
114*4882a593Smuzhiyun+#endif
115*4882a593Smuzhiyun+
116*4882a593Smuzhiyun+#ifndef FALSE
117*4882a593Smuzhiyun+#   define FALSE  false
118*4882a593Smuzhiyun+#endif
119*4882a593Smuzhiyun+
120*4882a593Smuzhiyun namespace WebCore {
121*4882a593Smuzhiyun
122*4882a593Smuzhiyun // UTF16ContextAware provider
123*4882a593Smuzhiyun--
124*4882a593Smuzhiyun2.26.2
125*4882a593Smuzhiyun
126