From 2c2403e2135b28bed4c3abc62983f753e7502d0c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andreas=20M=C3=BCller?= Date: Wed, 2 Dec 2020 22:51:59 +0100 Subject: qtwebkit: fix build with icu >= 68 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Andreas Müller --- .../0001-Do-not-skip-build-for-cross-compile.patch | 28 +++++ .../0002-Do-not-skip-build-for-cross-compile.patch | 28 ----- ...002-Fix-build-with-non-glibc-libc-on-musl.patch | 69 ++++++++++++ .../0003-Fix-build-bug-for-armv32-BE.patch | 25 +++++ ...003-Fix-build-with-non-glibc-libc-on-musl.patch | 69 ------------ .../0004-Fix-build-bug-for-armv32-BE.patch | 25 ----- ...cmake-Do-not-generate-hardcoded-include-p.patch | 37 ++++++ .../qt5/qtwebkit/0005-Fix-build-with-bison37.patch | 52 +++++++++ ...cmake-Do-not-generate-hardcoded-include-p.patch | 37 ------ ...e-related-to-HTTP-2-when-Qt-is-configured.patch | 34 ++++++ .../qt5/qtwebkit/0006-Fix-build-with-bison37.patch | 52 --------- ...e-related-to-HTTP-2-when-Qt-is-configured.patch | 34 ------ ...tion-with-Python-3.9-avoid-passing-encodi.patch | 32 ++++++ .../qt5/qtwebkit/0008-Fix-build-with-icu-68.patch | 125 +++++++++++++++++++++ ...tion-with-Python-3.9-avoid-passing-encodi.patch | 32 ------ recipes-qt/qt5/qtwebkit_git.bb | 15 +-- 16 files changed, 410 insertions(+), 284 deletions(-) create mode 100644 recipes-qt/qt5/qtwebkit/0001-Do-not-skip-build-for-cross-compile.patch delete mode 100644 recipes-qt/qt5/qtwebkit/0002-Do-not-skip-build-for-cross-compile.patch create mode 100644 recipes-qt/qt5/qtwebkit/0002-Fix-build-with-non-glibc-libc-on-musl.patch create mode 100644 recipes-qt/qt5/qtwebkit/0003-Fix-build-bug-for-armv32-BE.patch delete mode 100644 recipes-qt/qt5/qtwebkit/0003-Fix-build-with-non-glibc-libc-on-musl.patch delete mode 100644 recipes-qt/qt5/qtwebkit/0004-Fix-build-bug-for-armv32-BE.patch create mode 100644 recipes-qt/qt5/qtwebkit/0004-PlatformQt.cmake-Do-not-generate-hardcoded-include-p.patch create mode 100644 recipes-qt/qt5/qtwebkit/0005-Fix-build-with-bison37.patch delete mode 100644 recipes-qt/qt5/qtwebkit/0005-PlatformQt.cmake-Do-not-generate-hardcoded-include-p.patch create mode 100644 recipes-qt/qt5/qtwebkit/0006-Disable-code-related-to-HTTP-2-when-Qt-is-configured.patch delete mode 100644 recipes-qt/qt5/qtwebkit/0006-Fix-build-with-bison37.patch delete mode 100644 recipes-qt/qt5/qtwebkit/0007-Disable-code-related-to-HTTP-2-when-Qt-is-configured.patch create mode 100644 recipes-qt/qt5/qtwebkit/0007-Fix-compilation-with-Python-3.9-avoid-passing-encodi.patch create mode 100644 recipes-qt/qt5/qtwebkit/0008-Fix-build-with-icu-68.patch delete mode 100644 recipes-qt/qt5/qtwebkit/0008-Fix-compilation-with-Python-3.9-avoid-passing-encodi.patch diff --git a/recipes-qt/qt5/qtwebkit/0001-Do-not-skip-build-for-cross-compile.patch b/recipes-qt/qt5/qtwebkit/0001-Do-not-skip-build-for-cross-compile.patch new file mode 100644 index 00000000..a237d03d --- /dev/null +++ b/recipes-qt/qt5/qtwebkit/0001-Do-not-skip-build-for-cross-compile.patch @@ -0,0 +1,28 @@ +From 34018c2a61045c58f88e09a12ecd62533aa2c2f1 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Andreas=20M=C3=BCller?= +Date: Mon, 4 Jun 2018 10:35:46 +0200 +Subject: [PATCH] Do not skip build for cross-compile +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Upstream-Status: Inappropriate [OE specific] + +Signed-off-by: Andreas Müller +--- + Tools/qmake/mkspecs/features/functions.prf | 2 -- + 1 file changed, 2 deletions(-) + +diff --git a/Tools/qmake/mkspecs/features/functions.prf b/Tools/qmake/mkspecs/features/functions.prf +index e3f42cec4..797b7085f 100644 +--- a/Tools/qmake/mkspecs/features/functions.prf ++++ b/Tools/qmake/mkspecs/features/functions.prf +@@ -53,8 +53,6 @@ defineReplace(appleSdkVersion) { + defineTest(isPlatformSupported) { + !qtHaveModule(widgets): skipBuild("QtWidgets module is required to build QtWebKit.") + +- cross_compile: skipBuild("cross-compilation of QtWebKit with qmake is not supported yet") +- + requiredPrograms = cmake gperf python perl bison ruby flex + for(program, requiredPrograms): \ + !programExistsInPath($$program): \ diff --git a/recipes-qt/qt5/qtwebkit/0002-Do-not-skip-build-for-cross-compile.patch b/recipes-qt/qt5/qtwebkit/0002-Do-not-skip-build-for-cross-compile.patch deleted file mode 100644 index a237d03d..00000000 --- a/recipes-qt/qt5/qtwebkit/0002-Do-not-skip-build-for-cross-compile.patch +++ /dev/null @@ -1,28 +0,0 @@ -From 34018c2a61045c58f88e09a12ecd62533aa2c2f1 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Andreas=20M=C3=BCller?= -Date: Mon, 4 Jun 2018 10:35:46 +0200 -Subject: [PATCH] Do not skip build for cross-compile -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - -Upstream-Status: Inappropriate [OE specific] - -Signed-off-by: Andreas Müller ---- - Tools/qmake/mkspecs/features/functions.prf | 2 -- - 1 file changed, 2 deletions(-) - -diff --git a/Tools/qmake/mkspecs/features/functions.prf b/Tools/qmake/mkspecs/features/functions.prf -index e3f42cec4..797b7085f 100644 ---- a/Tools/qmake/mkspecs/features/functions.prf -+++ b/Tools/qmake/mkspecs/features/functions.prf -@@ -53,8 +53,6 @@ defineReplace(appleSdkVersion) { - defineTest(isPlatformSupported) { - !qtHaveModule(widgets): skipBuild("QtWidgets module is required to build QtWebKit.") - -- cross_compile: skipBuild("cross-compilation of QtWebKit with qmake is not supported yet") -- - requiredPrograms = cmake gperf python perl bison ruby flex - for(program, requiredPrograms): \ - !programExistsInPath($$program): \ diff --git a/recipes-qt/qt5/qtwebkit/0002-Fix-build-with-non-glibc-libc-on-musl.patch b/recipes-qt/qt5/qtwebkit/0002-Fix-build-with-non-glibc-libc-on-musl.patch new file mode 100644 index 00000000..bf79b363 --- /dev/null +++ b/recipes-qt/qt5/qtwebkit/0002-Fix-build-with-non-glibc-libc-on-musl.patch @@ -0,0 +1,69 @@ +From c4ceb318aa1064bfa677cdd800c52155eb1bed3a Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Thu, 23 Aug 2018 04:06:17 +0000 +Subject: [PATCH] Fix build with non-glibc libc on musl + +Need to ensure glibc features are not assumed to be linux-wide + +Upstream-Status: Pending +Signed-off-by: Khem Raj +--- + Source/JavaScriptCore/heap/MachineStackMarker.cpp | 8 ++++---- + .../inspector/JSGlobalObjectInspectorController.cpp | 2 ++ + 2 files changed, 6 insertions(+), 4 deletions(-) + +diff --git a/Source/JavaScriptCore/heap/MachineStackMarker.cpp b/Source/JavaScriptCore/heap/MachineStackMarker.cpp +index 883914fd3..ce4e8d331 100644 +--- a/Source/JavaScriptCore/heap/MachineStackMarker.cpp ++++ b/Source/JavaScriptCore/heap/MachineStackMarker.cpp +@@ -566,7 +566,7 @@ void* MachineThreads::Thread::Registers::stackPointer() const + #error Unknown Architecture + #endif + +-#elif defined(__GLIBC__) && ENABLE(JIT) ++#elif defined(__linux__) && ENABLE(JIT) + + #if CPU(X86) + return reinterpret_cast((uintptr_t) regs.machineContext.gregs[REG_ESP]); +@@ -665,7 +665,7 @@ void* MachineThreads::Thread::Registers::framePointer() const + #error Unknown Architecture + #endif + +-#elif defined(__GLIBC__) ++#elif defined(__linux__) + + // The following sequence depends on glibc's sys/ucontext.h. + #if CPU(X86) +@@ -747,7 +747,7 @@ void* MachineThreads::Thread::Registers::instructionPointer() const + #error Unknown Architecture + #endif + +-#elif defined(__GLIBC__) ++#elif defined(__linux__) + + // The following sequence depends on glibc's sys/ucontext.h. + #if CPU(X86) +@@ -838,7 +838,7 @@ void* MachineThreads::Thread::Registers::llintPC() const + #error Unknown Architecture + #endif + +-#elif defined(__GLIBC__) ++#elif defined(__linux__) + + // The following sequence depends on glibc's sys/ucontext.h. + #if CPU(X86) +diff --git a/Source/JavaScriptCore/inspector/JSGlobalObjectInspectorController.cpp b/Source/JavaScriptCore/inspector/JSGlobalObjectInspectorController.cpp +index fd7f869d4..e95391b32 100644 +--- a/Source/JavaScriptCore/inspector/JSGlobalObjectInspectorController.cpp ++++ b/Source/JavaScriptCore/inspector/JSGlobalObjectInspectorController.cpp +@@ -51,8 +51,10 @@ + #include + #if OS(DARWIN) || (OS(LINUX) && !PLATFORM(GTK)) + #include ++#if defined(__GLIBC__) + #include + #endif ++#endif + + #if ENABLE(REMOTE_INSPECTOR) + #include "JSGlobalObjectDebuggable.h" diff --git a/recipes-qt/qt5/qtwebkit/0003-Fix-build-bug-for-armv32-BE.patch b/recipes-qt/qt5/qtwebkit/0003-Fix-build-bug-for-armv32-BE.patch new file mode 100644 index 00000000..ffd8da0f --- /dev/null +++ b/recipes-qt/qt5/qtwebkit/0003-Fix-build-bug-for-armv32-BE.patch @@ -0,0 +1,25 @@ +From f6576377f8bf2c854d8079b7f309f570b3d2bde4 Mon Sep 17 00:00:00 2001 +From: Lei Maohui +Date: Fri, 31 Aug 2018 15:42:48 +0900 +Subject: [PATCH] Fix build bug for armv32 BE. + +Upstream-Status: Pending + +Signed-off-by: Lei Maohui +--- + Source/WTF/wtf/dtoa/utils.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/Source/WTF/wtf/dtoa/utils.h b/Source/WTF/wtf/dtoa/utils.h +index 889642cee..05302e6e6 100644 +--- a/Source/WTF/wtf/dtoa/utils.h ++++ b/Source/WTF/wtf/dtoa/utils.h +@@ -49,7 +49,7 @@ + defined(__ARMEL__) || \ + defined(_MIPS_ARCH_MIPS32R2) + #define DOUBLE_CONVERSION_CORRECT_DOUBLE_OPERATIONS 1 +-#elif CPU(MIPS) || CPU(MIPS64) || CPU(PPC) || CPU(PPC64) || CPU(PPC64LE) || CPU(SH4) || CPU(S390) || CPU(S390X) || CPU(IA64) || CPU(ALPHA) || CPU(ARM64) || CPU(HPPA) ++#elif CPU(MIPS) || CPU(MIPS64) || CPU(PPC) || CPU(PPC64) || CPU(PPC64LE) || CPU(SH4) || CPU(S390) || CPU(S390X) || CPU(IA64) || CPU(ALPHA) || CPU(ARM64) || CPU(HPPA) || CPU(ARM) + #define DOUBLE_CONVERSION_CORRECT_DOUBLE_OPERATIONS 1 + #elif defined(_M_IX86) || defined(__i386__) + #if defined(_WIN32) diff --git a/recipes-qt/qt5/qtwebkit/0003-Fix-build-with-non-glibc-libc-on-musl.patch b/recipes-qt/qt5/qtwebkit/0003-Fix-build-with-non-glibc-libc-on-musl.patch deleted file mode 100644 index bf79b363..00000000 --- a/recipes-qt/qt5/qtwebkit/0003-Fix-build-with-non-glibc-libc-on-musl.patch +++ /dev/null @@ -1,69 +0,0 @@ -From c4ceb318aa1064bfa677cdd800c52155eb1bed3a Mon Sep 17 00:00:00 2001 -From: Khem Raj -Date: Thu, 23 Aug 2018 04:06:17 +0000 -Subject: [PATCH] Fix build with non-glibc libc on musl - -Need to ensure glibc features are not assumed to be linux-wide - -Upstream-Status: Pending -Signed-off-by: Khem Raj ---- - Source/JavaScriptCore/heap/MachineStackMarker.cpp | 8 ++++---- - .../inspector/JSGlobalObjectInspectorController.cpp | 2 ++ - 2 files changed, 6 insertions(+), 4 deletions(-) - -diff --git a/Source/JavaScriptCore/heap/MachineStackMarker.cpp b/Source/JavaScriptCore/heap/MachineStackMarker.cpp -index 883914fd3..ce4e8d331 100644 ---- a/Source/JavaScriptCore/heap/MachineStackMarker.cpp -+++ b/Source/JavaScriptCore/heap/MachineStackMarker.cpp -@@ -566,7 +566,7 @@ void* MachineThreads::Thread::Registers::stackPointer() const - #error Unknown Architecture - #endif - --#elif defined(__GLIBC__) && ENABLE(JIT) -+#elif defined(__linux__) && ENABLE(JIT) - - #if CPU(X86) - return reinterpret_cast((uintptr_t) regs.machineContext.gregs[REG_ESP]); -@@ -665,7 +665,7 @@ void* MachineThreads::Thread::Registers::framePointer() const - #error Unknown Architecture - #endif - --#elif defined(__GLIBC__) -+#elif defined(__linux__) - - // The following sequence depends on glibc's sys/ucontext.h. - #if CPU(X86) -@@ -747,7 +747,7 @@ void* MachineThreads::Thread::Registers::instructionPointer() const - #error Unknown Architecture - #endif - --#elif defined(__GLIBC__) -+#elif defined(__linux__) - - // The following sequence depends on glibc's sys/ucontext.h. - #if CPU(X86) -@@ -838,7 +838,7 @@ void* MachineThreads::Thread::Registers::llintPC() const - #error Unknown Architecture - #endif - --#elif defined(__GLIBC__) -+#elif defined(__linux__) - - // The following sequence depends on glibc's sys/ucontext.h. - #if CPU(X86) -diff --git a/Source/JavaScriptCore/inspector/JSGlobalObjectInspectorController.cpp b/Source/JavaScriptCore/inspector/JSGlobalObjectInspectorController.cpp -index fd7f869d4..e95391b32 100644 ---- a/Source/JavaScriptCore/inspector/JSGlobalObjectInspectorController.cpp -+++ b/Source/JavaScriptCore/inspector/JSGlobalObjectInspectorController.cpp -@@ -51,8 +51,10 @@ - #include - #if OS(DARWIN) || (OS(LINUX) && !PLATFORM(GTK)) - #include -+#if defined(__GLIBC__) - #include - #endif -+#endif - - #if ENABLE(REMOTE_INSPECTOR) - #include "JSGlobalObjectDebuggable.h" diff --git a/recipes-qt/qt5/qtwebkit/0004-Fix-build-bug-for-armv32-BE.patch b/recipes-qt/qt5/qtwebkit/0004-Fix-build-bug-for-armv32-BE.patch deleted file mode 100644 index ffd8da0f..00000000 --- a/recipes-qt/qt5/qtwebkit/0004-Fix-build-bug-for-armv32-BE.patch +++ /dev/null @@ -1,25 +0,0 @@ -From f6576377f8bf2c854d8079b7f309f570b3d2bde4 Mon Sep 17 00:00:00 2001 -From: Lei Maohui -Date: Fri, 31 Aug 2018 15:42:48 +0900 -Subject: [PATCH] Fix build bug for armv32 BE. - -Upstream-Status: Pending - -Signed-off-by: Lei Maohui ---- - Source/WTF/wtf/dtoa/utils.h | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/Source/WTF/wtf/dtoa/utils.h b/Source/WTF/wtf/dtoa/utils.h -index 889642cee..05302e6e6 100644 ---- a/Source/WTF/wtf/dtoa/utils.h -+++ b/Source/WTF/wtf/dtoa/utils.h -@@ -49,7 +49,7 @@ - defined(__ARMEL__) || \ - defined(_MIPS_ARCH_MIPS32R2) - #define DOUBLE_CONVERSION_CORRECT_DOUBLE_OPERATIONS 1 --#elif CPU(MIPS) || CPU(MIPS64) || CPU(PPC) || CPU(PPC64) || CPU(PPC64LE) || CPU(SH4) || CPU(S390) || CPU(S390X) || CPU(IA64) || CPU(ALPHA) || CPU(ARM64) || CPU(HPPA) -+#elif CPU(MIPS) || CPU(MIPS64) || CPU(PPC) || CPU(PPC64) || CPU(PPC64LE) || CPU(SH4) || CPU(S390) || CPU(S390X) || CPU(IA64) || CPU(ALPHA) || CPU(ARM64) || CPU(HPPA) || CPU(ARM) - #define DOUBLE_CONVERSION_CORRECT_DOUBLE_OPERATIONS 1 - #elif defined(_M_IX86) || defined(__i386__) - #if defined(_WIN32) diff --git a/recipes-qt/qt5/qtwebkit/0004-PlatformQt.cmake-Do-not-generate-hardcoded-include-p.patch b/recipes-qt/qt5/qtwebkit/0004-PlatformQt.cmake-Do-not-generate-hardcoded-include-p.patch new file mode 100644 index 00000000..14cb8aa4 --- /dev/null +++ b/recipes-qt/qt5/qtwebkit/0004-PlatformQt.cmake-Do-not-generate-hardcoded-include-p.patch @@ -0,0 +1,37 @@ +From 83aa5b3265d7c9f64e754cb890988cf8a5669ce7 Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Mon, 24 Sep 2018 02:11:10 -0700 +Subject: [PATCH] PlatformQt.cmake: Do not generate hardcoded include paths + +If we do not use this define,then it falls into else case which +generated .pri files with /usr/include and so on for includes and +compiler does not like specifying absolute include paths pointing to +build host includes + +Signed-off-by: Khem Raj +--- + Source/WebKit/PlatformQt.cmake | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/Source/WebKit/PlatformQt.cmake b/Source/WebKit/PlatformQt.cmake +index 9aed9906e..48638aef4 100644 +--- a/Source/WebKit/PlatformQt.cmake ++++ b/Source/WebKit/PlatformQt.cmake +@@ -512,7 +512,7 @@ if (NOT MACOS_BUILD_FRAMEWORKS) + install(FILES ${WebKit_PKGCONFIG_FILENAME} DESTINATION ${ECM_PKGCONFIG_INSTALL_DIR} COMPONENT Data) + endif () + +-if (KDE_INSTALL_USE_QT_SYS_PATHS) ++if (KDE_INSTALL_USE_QT_SYS_PATHS OR CROSS_COMPILE) + set(WebKit_PRI_ARGUMENTS + BIN_INSTALL_DIR "$$QT_MODULE_BIN_BASE" + LIB_INSTALL_DIR "$$QT_MODULE_LIB_BASE" +@@ -737,7 +737,7 @@ if (NOT MACOS_BUILD_FRAMEWORKS) + install(FILES ${WebKitWidgets_PKGCONFIG_FILENAME} DESTINATION ${ECM_PKGCONFIG_INSTALL_DIR} COMPONENT Data) + endif () + +-if (KDE_INSTALL_USE_QT_SYS_PATHS) ++if (KDE_INSTALL_USE_QT_SYS_PATHS OR CROSS_COMPILE) + set(WebKitWidgets_PRI_ARGUMENTS + BIN_INSTALL_DIR "$$QT_MODULE_BIN_BASE" + LIB_INSTALL_DIR "$$QT_MODULE_LIB_BASE" diff --git a/recipes-qt/qt5/qtwebkit/0005-Fix-build-with-bison37.patch b/recipes-qt/qt5/qtwebkit/0005-Fix-build-with-bison37.patch new file mode 100644 index 00000000..9262f5fe --- /dev/null +++ b/recipes-qt/qt5/qtwebkit/0005-Fix-build-with-bison37.patch @@ -0,0 +1,52 @@ +From d92b11fea65364fefa700249bd3340e0cd4c5b31 Mon Sep 17 00:00:00 2001 +From: Dmitry Shachnev +Date: Tue, 4 Aug 2020 21:04:06 +0300 +Subject: [PATCH] Let Bison generate the header directly, to fix build with + Bison 3.7 + +Starting with Bison 3.7, the generated C++ file #include's the header +by default, instead of duplicating it. So we should not delete it. + +Remove the code to add #ifdef guards to the header, since Bison adds +them itself since version 2.6.3. + +Found at [1] + +[1] https://github.com/qtwebkit/qtwebkit/commit/d92b11fea65364fefa700249bd3340e0cd4c5b31 + +Upstream-Status: Pending +--- + Source/WebCore/css/makegrammar.pl | 21 +-------------------- + 1 file changed, 1 insertion(+), 20 deletions(-) + +diff --git a/Source/WebCore/css/makegrammar.pl b/Source/WebCore/css/makegrammar.pl +index 5d63b08102eb..9435701c7061 100644 +--- a/Source/WebCore/css/makegrammar.pl ++++ b/Source/WebCore/css/makegrammar.pl +@@ -73,25 +73,6 @@ + } + + my $fileBase = File::Spec->join($outputDir, $filename); +-my @bisonCommand = ($bison, "-d", "-p", $symbolsPrefix, $grammarFilePath, "-o", "$fileBase.cpp"); ++my @bisonCommand = ($bison, "--defines=$fileBase.h", "-p", $symbolsPrefix, $grammarFilePath, "-o", "$fileBase.cpp"); + push @bisonCommand, "--no-lines" if $^O eq "MSWin32"; # Work around bug in bison >= 3.0 on Windows where it puts backslashes into #line directives. + system(@bisonCommand) == 0 or die; +- +-open HEADER, ">$fileBase.h" or die; +-print HEADER << "EOF"; +-#ifndef CSSGRAMMAR_H +-#define CSSGRAMMAR_H +-EOF +- +-open HPP, "<$fileBase.cpp.h" or open HPP, "<$fileBase.hpp" or die; +-while () { +- print HEADER; +-} +-close HPP; +- +-print HEADER "#endif\n"; +-close HEADER; +- +-unlink("$fileBase.cpp.h"); +-unlink("$fileBase.hpp"); +- diff --git a/recipes-qt/qt5/qtwebkit/0005-PlatformQt.cmake-Do-not-generate-hardcoded-include-p.patch b/recipes-qt/qt5/qtwebkit/0005-PlatformQt.cmake-Do-not-generate-hardcoded-include-p.patch deleted file mode 100644 index 14cb8aa4..00000000 --- a/recipes-qt/qt5/qtwebkit/0005-PlatformQt.cmake-Do-not-generate-hardcoded-include-p.patch +++ /dev/null @@ -1,37 +0,0 @@ -From 83aa5b3265d7c9f64e754cb890988cf8a5669ce7 Mon Sep 17 00:00:00 2001 -From: Khem Raj -Date: Mon, 24 Sep 2018 02:11:10 -0700 -Subject: [PATCH] PlatformQt.cmake: Do not generate hardcoded include paths - -If we do not use this define,then it falls into else case which -generated .pri files with /usr/include and so on for includes and -compiler does not like specifying absolute include paths pointing to -build host includes - -Signed-off-by: Khem Raj ---- - Source/WebKit/PlatformQt.cmake | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/Source/WebKit/PlatformQt.cmake b/Source/WebKit/PlatformQt.cmake -index 9aed9906e..48638aef4 100644 ---- a/Source/WebKit/PlatformQt.cmake -+++ b/Source/WebKit/PlatformQt.cmake -@@ -512,7 +512,7 @@ if (NOT MACOS_BUILD_FRAMEWORKS) - install(FILES ${WebKit_PKGCONFIG_FILENAME} DESTINATION ${ECM_PKGCONFIG_INSTALL_DIR} COMPONENT Data) - endif () - --if (KDE_INSTALL_USE_QT_SYS_PATHS) -+if (KDE_INSTALL_USE_QT_SYS_PATHS OR CROSS_COMPILE) - set(WebKit_PRI_ARGUMENTS - BIN_INSTALL_DIR "$$QT_MODULE_BIN_BASE" - LIB_INSTALL_DIR "$$QT_MODULE_LIB_BASE" -@@ -737,7 +737,7 @@ if (NOT MACOS_BUILD_FRAMEWORKS) - install(FILES ${WebKitWidgets_PKGCONFIG_FILENAME} DESTINATION ${ECM_PKGCONFIG_INSTALL_DIR} COMPONENT Data) - endif () - --if (KDE_INSTALL_USE_QT_SYS_PATHS) -+if (KDE_INSTALL_USE_QT_SYS_PATHS OR CROSS_COMPILE) - set(WebKitWidgets_PRI_ARGUMENTS - BIN_INSTALL_DIR "$$QT_MODULE_BIN_BASE" - LIB_INSTALL_DIR "$$QT_MODULE_LIB_BASE" diff --git a/recipes-qt/qt5/qtwebkit/0006-Disable-code-related-to-HTTP-2-when-Qt-is-configured.patch b/recipes-qt/qt5/qtwebkit/0006-Disable-code-related-to-HTTP-2-when-Qt-is-configured.patch new file mode 100644 index 00000000..15607c0d --- /dev/null +++ b/recipes-qt/qt5/qtwebkit/0006-Disable-code-related-to-HTTP-2-when-Qt-is-configured.patch @@ -0,0 +1,34 @@ +From 32eb0352d98fcf325b0a94a4f7e141d746938a4b Mon Sep 17 00:00:00 2001 +From: Konstantin Tokarev +Date: Sun, 3 May 2020 18:50:24 +0300 +Subject: [PATCH] Disable code related to HTTP/2 when Qt is configured without SSL support + +For enabling HTTP/2 by default we check if Qt uses OpenSSL and its version +is 1.0.2 or higher via QSslSocket API. While it would be sufficient to +add guards just there, we are not going to enable HTTP/2 for QT_NO_SSL +case by default anyway (note that it still can be done in application code). + +Change-Id: I77b4a423ff1028725ac2c0953c757dce2db23e05 +--- +Upstream-Status: Backport [https://github.com/qtwebkit/qtwebkit/commit/e7ec14144ce58418d94568c41ac94d4d87969363] +Signed-off-by: Khem Raj + + Source/WebCore/platform/network/qt/ResourceRequest.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/Source/WebCore/platform/network/qt/ResourceRequest.h b/Source/WebCore/platform/network/qt/ResourceRequest.h +index 1154d56a0..87e21ec3f 100644 +--- a/Source/WebCore/platform/network/qt/ResourceRequest.h ++++ b/Source/WebCore/platform/network/qt/ResourceRequest.h +@@ -32,7 +32,7 @@ + // HTTP/2 is implemented since Qt 5.8, but various QtNetwork bugs make it unusable in browser with Qt < 5.10.1 + // We also don't enable HTTP/2 for unencrypted connections because of possible compatibility issues; it can be + // enabled manually by user application via custom QNAM subclass +-#if QT_VERSION >= QT_VERSION_CHECK(5, 10, 1) ++#if QT_VERSION >= QT_VERSION_CHECK(5, 10, 1) && !defined(QT_NO_SSL) + #define USE_HTTP2 1 + #endif + +-- +2.29.2 + diff --git a/recipes-qt/qt5/qtwebkit/0006-Fix-build-with-bison37.patch b/recipes-qt/qt5/qtwebkit/0006-Fix-build-with-bison37.patch deleted file mode 100644 index 9262f5fe..00000000 --- a/recipes-qt/qt5/qtwebkit/0006-Fix-build-with-bison37.patch +++ /dev/null @@ -1,52 +0,0 @@ -From d92b11fea65364fefa700249bd3340e0cd4c5b31 Mon Sep 17 00:00:00 2001 -From: Dmitry Shachnev -Date: Tue, 4 Aug 2020 21:04:06 +0300 -Subject: [PATCH] Let Bison generate the header directly, to fix build with - Bison 3.7 - -Starting with Bison 3.7, the generated C++ file #include's the header -by default, instead of duplicating it. So we should not delete it. - -Remove the code to add #ifdef guards to the header, since Bison adds -them itself since version 2.6.3. - -Found at [1] - -[1] https://github.com/qtwebkit/qtwebkit/commit/d92b11fea65364fefa700249bd3340e0cd4c5b31 - -Upstream-Status: Pending ---- - Source/WebCore/css/makegrammar.pl | 21 +-------------------- - 1 file changed, 1 insertion(+), 20 deletions(-) - -diff --git a/Source/WebCore/css/makegrammar.pl b/Source/WebCore/css/makegrammar.pl -index 5d63b08102eb..9435701c7061 100644 ---- a/Source/WebCore/css/makegrammar.pl -+++ b/Source/WebCore/css/makegrammar.pl -@@ -73,25 +73,6 @@ - } - - my $fileBase = File::Spec->join($outputDir, $filename); --my @bisonCommand = ($bison, "-d", "-p", $symbolsPrefix, $grammarFilePath, "-o", "$fileBase.cpp"); -+my @bisonCommand = ($bison, "--defines=$fileBase.h", "-p", $symbolsPrefix, $grammarFilePath, "-o", "$fileBase.cpp"); - push @bisonCommand, "--no-lines" if $^O eq "MSWin32"; # Work around bug in bison >= 3.0 on Windows where it puts backslashes into #line directives. - system(@bisonCommand) == 0 or die; -- --open HEADER, ">$fileBase.h" or die; --print HEADER << "EOF"; --#ifndef CSSGRAMMAR_H --#define CSSGRAMMAR_H --EOF -- --open HPP, "<$fileBase.cpp.h" or open HPP, "<$fileBase.hpp" or die; --while () { -- print HEADER; --} --close HPP; -- --print HEADER "#endif\n"; --close HEADER; -- --unlink("$fileBase.cpp.h"); --unlink("$fileBase.hpp"); -- diff --git a/recipes-qt/qt5/qtwebkit/0007-Disable-code-related-to-HTTP-2-when-Qt-is-configured.patch b/recipes-qt/qt5/qtwebkit/0007-Disable-code-related-to-HTTP-2-when-Qt-is-configured.patch deleted file mode 100644 index 15607c0d..00000000 --- a/recipes-qt/qt5/qtwebkit/0007-Disable-code-related-to-HTTP-2-when-Qt-is-configured.patch +++ /dev/null @@ -1,34 +0,0 @@ -From 32eb0352d98fcf325b0a94a4f7e141d746938a4b Mon Sep 17 00:00:00 2001 -From: Konstantin Tokarev -Date: Sun, 3 May 2020 18:50:24 +0300 -Subject: [PATCH] Disable code related to HTTP/2 when Qt is configured without SSL support - -For enabling HTTP/2 by default we check if Qt uses OpenSSL and its version -is 1.0.2 or higher via QSslSocket API. While it would be sufficient to -add guards just there, we are not going to enable HTTP/2 for QT_NO_SSL -case by default anyway (note that it still can be done in application code). - -Change-Id: I77b4a423ff1028725ac2c0953c757dce2db23e05 ---- -Upstream-Status: Backport [https://github.com/qtwebkit/qtwebkit/commit/e7ec14144ce58418d94568c41ac94d4d87969363] -Signed-off-by: Khem Raj - - Source/WebCore/platform/network/qt/ResourceRequest.h | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/Source/WebCore/platform/network/qt/ResourceRequest.h b/Source/WebCore/platform/network/qt/ResourceRequest.h -index 1154d56a0..87e21ec3f 100644 ---- a/Source/WebCore/platform/network/qt/ResourceRequest.h -+++ b/Source/WebCore/platform/network/qt/ResourceRequest.h -@@ -32,7 +32,7 @@ - // HTTP/2 is implemented since Qt 5.8, but various QtNetwork bugs make it unusable in browser with Qt < 5.10.1 - // We also don't enable HTTP/2 for unencrypted connections because of possible compatibility issues; it can be - // enabled manually by user application via custom QNAM subclass --#if QT_VERSION >= QT_VERSION_CHECK(5, 10, 1) -+#if QT_VERSION >= QT_VERSION_CHECK(5, 10, 1) && !defined(QT_NO_SSL) - #define USE_HTTP2 1 - #endif - --- -2.29.2 - diff --git a/recipes-qt/qt5/qtwebkit/0007-Fix-compilation-with-Python-3.9-avoid-passing-encodi.patch b/recipes-qt/qt5/qtwebkit/0007-Fix-compilation-with-Python-3.9-avoid-passing-encodi.patch new file mode 100644 index 00000000..4eef3451 --- /dev/null +++ b/recipes-qt/qt5/qtwebkit/0007-Fix-compilation-with-Python-3.9-avoid-passing-encodi.patch @@ -0,0 +1,32 @@ +From df9f6a8c9d59996b52bfdc5ea6f780de517905e5 Mon Sep 17 00:00:00 2001 +From: Konstantin Tokarev +Date: Wed, 3 Jun 2020 15:01:42 +0300 +Subject: [PATCH] Fix compilation with Python 3.9: avoid passing encoding to + json.load() + +In Python 2.7 UTF-8 is assumed by default, while in Python 3 this argument +is not supported. + +Upstream-Status: Backport [https://github.com/qtwebkit/qtwebkit/commit/78360c01c796b6260bf828bc9c8a0ef73c5132fd] +Change-Id: Ic459d60a6b20bc1838d8771bc36ac41614fe61a9 +Signed-off-by: Khem Raj +--- + Source/JavaScriptCore/generate-bytecode-files | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/Source/JavaScriptCore/generate-bytecode-files b/Source/JavaScriptCore/generate-bytecode-files +index c5dab429c..af3431275 100644 +--- a/Source/JavaScriptCore/generate-bytecode-files ++++ b/Source/JavaScriptCore/generate-bytecode-files +@@ -163,7 +163,7 @@ if __name__ == "__main__": + initBytecodesFile = openOrExit(initASMFileName, "w") + + try: +- bytecodeSections = json.load(bytecodeFile, encoding = "utf-8") ++ bytecodeSections = json.load(bytecodeFile) + except: + print("Unexpected error parsing {0}: {1}".format(bytecodeJSONFile, sys.exc_info())) + +-- +2.29.2 + diff --git a/recipes-qt/qt5/qtwebkit/0008-Fix-build-with-icu-68.patch b/recipes-qt/qt5/qtwebkit/0008-Fix-build-with-icu-68.patch new file mode 100644 index 00000000..1715c8f3 --- /dev/null +++ b/recipes-qt/qt5/qtwebkit/0008-Fix-build-with-icu-68.patch @@ -0,0 +1,125 @@ +From 0e94085f74b562bf8edf5418142323785a069454 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Andreas=20M=C3=BCller?= +Date: Wed, 2 Dec 2020 22:34:54 +0100 +Subject: [PATCH] Fix build with icu >= 68 +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Upstream-Status: Pending + +Signed-off-by: Andreas Müller +--- + Source/WebCore/platform/text/TextCodecICU.cpp | 15 +++++++++++++++ + Source/WebCore/platform/text/icu/UTextProvider.h | 15 +++++++++++++++ + .../platform/text/icu/UTextProviderLatin1.cpp | 15 +++++++++++++++ + .../platform/text/icu/UTextProviderUTF16.cpp | 15 +++++++++++++++ + 4 files changed, 60 insertions(+) + +diff --git a/Source/WebCore/platform/text/TextCodecICU.cpp b/Source/WebCore/platform/text/TextCodecICU.cpp +index dd6ff0675..7ce8a70ef 100644 +--- a/Source/WebCore/platform/text/TextCodecICU.cpp ++++ b/Source/WebCore/platform/text/TextCodecICU.cpp +@@ -39,6 +39,21 @@ + #include + #include + ++// Since icu 68.1 icu we have to: ++#ifndef TRUE ++// Taken from umachibe.h: ++/** ++ * The TRUE value of a UBool. ++ * ++ * @deprecated ICU 68 Use standard "true" instead. ++ */ ++# define TRUE true ++#endif ++ ++#ifndef FALSE ++# define FALSE false ++#endif ++ + namespace WebCore { + + const size_t ConversionBufferSize = 16384; +diff --git a/Source/WebCore/platform/text/icu/UTextProvider.h b/Source/WebCore/platform/text/icu/UTextProvider.h +index c254fc4c7..9d2ad8b8c 100644 +--- a/Source/WebCore/platform/text/icu/UTextProvider.h ++++ b/Source/WebCore/platform/text/icu/UTextProvider.h +@@ -28,6 +28,21 @@ + + #include + ++// Since icu 68.1 icu we have to: ++#ifndef TRUE ++// Taken from umachibe.h: ++/** ++ * The TRUE value of a UBool. ++ * ++ * @deprecated ICU 68 Use standard "true" instead. ++ */ ++# define TRUE true ++#endif ++ ++#ifndef FALSE ++# define FALSE false ++#endif ++ + namespace WebCore { + + enum class UTextProviderContext { +diff --git a/Source/WebCore/platform/text/icu/UTextProviderLatin1.cpp b/Source/WebCore/platform/text/icu/UTextProviderLatin1.cpp +index cd6852c71..0c95ea529 100644 +--- a/Source/WebCore/platform/text/icu/UTextProviderLatin1.cpp ++++ b/Source/WebCore/platform/text/icu/UTextProviderLatin1.cpp +@@ -29,6 +29,21 @@ + #include "UTextProvider.h" + #include + ++// Since icu 68.1 icu we have to: ++#ifndef TRUE ++// Taken from umachibe.h: ++/** ++ * The TRUE value of a UBool. ++ * ++ * @deprecated ICU 68 Use standard "true" instead. ++ */ ++# define TRUE true ++#endif ++ ++#ifndef FALSE ++# define FALSE false ++#endif ++ + namespace WebCore { + + // Latin1 provider +diff --git a/Source/WebCore/platform/text/icu/UTextProviderUTF16.cpp b/Source/WebCore/platform/text/icu/UTextProviderUTF16.cpp +index 7aaac48c8..6ac693602 100644 +--- a/Source/WebCore/platform/text/icu/UTextProviderUTF16.cpp ++++ b/Source/WebCore/platform/text/icu/UTextProviderUTF16.cpp +@@ -28,6 +28,21 @@ + + #include "UTextProvider.h" + ++// Since icu 68.1 icu we have to: ++#ifndef TRUE ++// Taken from umachibe.h: ++/** ++ * The TRUE value of a UBool. ++ * ++ * @deprecated ICU 68 Use standard "true" instead. ++ */ ++# define TRUE true ++#endif ++ ++#ifndef FALSE ++# define FALSE false ++#endif ++ + namespace WebCore { + + // UTF16ContextAware provider +-- +2.26.2 + diff --git a/recipes-qt/qt5/qtwebkit/0008-Fix-compilation-with-Python-3.9-avoid-passing-encodi.patch b/recipes-qt/qt5/qtwebkit/0008-Fix-compilation-with-Python-3.9-avoid-passing-encodi.patch deleted file mode 100644 index 4eef3451..00000000 --- a/recipes-qt/qt5/qtwebkit/0008-Fix-compilation-with-Python-3.9-avoid-passing-encodi.patch +++ /dev/null @@ -1,32 +0,0 @@ -From df9f6a8c9d59996b52bfdc5ea6f780de517905e5 Mon Sep 17 00:00:00 2001 -From: Konstantin Tokarev -Date: Wed, 3 Jun 2020 15:01:42 +0300 -Subject: [PATCH] Fix compilation with Python 3.9: avoid passing encoding to - json.load() - -In Python 2.7 UTF-8 is assumed by default, while in Python 3 this argument -is not supported. - -Upstream-Status: Backport [https://github.com/qtwebkit/qtwebkit/commit/78360c01c796b6260bf828bc9c8a0ef73c5132fd] -Change-Id: Ic459d60a6b20bc1838d8771bc36ac41614fe61a9 -Signed-off-by: Khem Raj ---- - Source/JavaScriptCore/generate-bytecode-files | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/Source/JavaScriptCore/generate-bytecode-files b/Source/JavaScriptCore/generate-bytecode-files -index c5dab429c..af3431275 100644 ---- a/Source/JavaScriptCore/generate-bytecode-files -+++ b/Source/JavaScriptCore/generate-bytecode-files -@@ -163,7 +163,7 @@ if __name__ == "__main__": - initBytecodesFile = openOrExit(initASMFileName, "w") - - try: -- bytecodeSections = json.load(bytecodeFile, encoding = "utf-8") -+ bytecodeSections = json.load(bytecodeFile) - except: - print("Unexpected error parsing {0}: {1}".format(bytecodeJSONFile, sys.exc_info())) - --- -2.29.2 - diff --git a/recipes-qt/qt5/qtwebkit_git.bb b/recipes-qt/qt5/qtwebkit_git.bb index 9ce948e0..e415dabc 100644 --- a/recipes-qt/qt5/qtwebkit_git.bb +++ b/recipes-qt/qt5/qtwebkit_git.bb @@ -12,13 +12,14 @@ DEPENDS += "qtbase qtdeclarative icu ruby-native sqlite3 glib-2.0 libxslt gperf- # Patches from https://github.com/meta-qt5/qtwebkit/commits/b5.13 # 5.13.meta-qt5.1 SRC_URI += "\ - file://0002-Do-not-skip-build-for-cross-compile.patch \ - file://0003-Fix-build-with-non-glibc-libc-on-musl.patch \ - file://0004-Fix-build-bug-for-armv32-BE.patch \ - file://0005-PlatformQt.cmake-Do-not-generate-hardcoded-include-p.patch \ - file://0006-Fix-build-with-bison37.patch \ - file://0007-Disable-code-related-to-HTTP-2-when-Qt-is-configured.patch \ - file://0008-Fix-compilation-with-Python-3.9-avoid-passing-encodi.patch \ + file://0001-Do-not-skip-build-for-cross-compile.patch \ + file://0002-Fix-build-with-non-glibc-libc-on-musl.patch \ + file://0003-Fix-build-bug-for-armv32-BE.patch \ + file://0004-PlatformQt.cmake-Do-not-generate-hardcoded-include-p.patch \ + file://0005-Fix-build-with-bison37.patch \ + file://0006-Disable-code-related-to-HTTP-2-when-Qt-is-configured.patch \ + file://0007-Fix-compilation-with-Python-3.9-avoid-passing-encodi.patch \ + file://0008-Fix-build-with-icu-68.patch \ " inherit cmake_qt5 perlnative -- cgit v1.2.3