From 21feeb258f66a9ceaba5c79ff5d3ea28b4634ea3 Mon Sep 17 00:00:00 2001 From: Shokara Kou Date: Sat, 2 Mar 2024 22:26:55 -0500 Subject: try getting www/webkitgtk4 to build --- www/webkitgtk4/Makefile | 127 +++++++++----------- .../patches/patch-Source_JavaScriptCore_jsc_cpp | 11 -- ...-Source_JavaScriptCore_runtime_MachineContext_h | 56 ++++++--- ...ce_JavaScriptCore_runtime_MachineContext_h.orig | 128 +++++++++++++++++++++ .../patches/patch-Source_WTF_wtf_PlatformHave_h | 2 +- .../patch-Source_WTF_wtf_PlatformHave_h.orig | 18 +++ .../patches/patch-Source_WTF_wtf_PlatformUse_h | 12 ++ ...tch-Source_WebKit_Platform_IPC_ArgumentCoders_h | 115 ------------------ ...ource_WebKit_gtk_webkit2gtk-web-extension_pc_in | 10 -- .../patch-Source_WebKit_gtk_webkit2gtk_pc_in | 10 -- 10 files changed, 252 insertions(+), 237 deletions(-) delete mode 100644 www/webkitgtk4/patches/patch-Source_JavaScriptCore_jsc_cpp create mode 100644 www/webkitgtk4/patches/patch-Source_JavaScriptCore_runtime_MachineContext_h.orig create mode 100644 www/webkitgtk4/patches/patch-Source_WTF_wtf_PlatformHave_h.orig create mode 100644 www/webkitgtk4/patches/patch-Source_WTF_wtf_PlatformUse_h delete mode 100644 www/webkitgtk4/patches/patch-Source_WebKit_Platform_IPC_ArgumentCoders_h delete mode 100644 www/webkitgtk4/patches/patch-Source_WebKit_gtk_webkit2gtk-web-extension_pc_in delete mode 100644 www/webkitgtk4/patches/patch-Source_WebKit_gtk_webkit2gtk_pc_in diff --git a/www/webkitgtk4/Makefile b/www/webkitgtk4/Makefile index cb3a020..ae22d49 100644 --- a/www/webkitgtk4/Makefile +++ b/www/webkitgtk4/Makefile @@ -10,7 +10,7 @@ BROKEN-arm = JavaScriptCore/runtime/MachineContext.h, various sigcontext-relate PORTROACH = limitw:1,even -COMMENT = GTK+ port of the WebKit (${API}) rendering engine +COMMENT = GTK+ port of the WebKit (4.0) rendering engine V = 2.42.5 DISTNAME = webkitgtk-${V} @@ -33,20 +33,20 @@ HOMEPAGE = https://webkitgtk.org/ MAINTAINER = Antoine Jacoutot + # LGPLv2 and BSD PERMIT_PACKAGE = Yes -WANTLIB += ${COMPILER_LIBCXX} WPEBackend-fdo-1.0 X11 Xcomposite -WANTLIB += Xdamage Xrender Xt avif c cairo cairo-gobject drm enchant-2 -WANTLIB += epoll-shim epoxy fontconfig freetype gbm gcrypt gdk_pixbuf-2.0 +WANTLIB += ${COMPILER_LIBCXX} X11 Xcomposite +WANTLIB += Xdamage Xrender Xt c cairo cairo-gobject drm +WANTLIB += epoll-shim epoxy fontconfig freetype gcrypt gdk_pixbuf-2.0 WANTLIB += gio-2.0 glib-2.0 gmodule-2.0 gobject-2.0 gpg-error WANTLIB += gstallocators-1.0 gstapp-1.0 gstaudio-1.0 gstbase-1.0 WANTLIB += gstfft-1.0 gstgl-1.0 gstpbutils-1.0 gstreamer-1.0 gsttag-1.0 WANTLIB += gsttranscoder-1.0 gstvideo-1.0 harfbuzz harfbuzz-icu -WANTLIB += hyphen icudata icui18n icuuc intl jpeg jxl lcms2 m -WANTLIB += openjp2 pango-1.0 pangocairo-1.0 png secret-1 sqlite3 -WANTLIB += tasn1 wayland-client wayland-egl wayland-server webp -WANTLIB += webpdemux woff2dec wpe-1.0 xml2 xslt z +WANTLIB += icudata icui18n icuuc intl jpeg m +WANTLIB += openjp2 pango-1.0 pangocairo-1.0 png sqlite3 +WANTLIB += tasn1 xml2 z gdk-3 gtk-3 soup-2.4 SITES = https://webkitgtk.org/releases/ @@ -57,7 +57,6 @@ MODULES = devel/cmake \ lang/ruby \ x11/gnome -MODGNOME_TOOLS = gi-docgen gobject-introspection MODPY_RUNDEP = No MODRUBY_RUNDEP = No @@ -67,52 +66,64 @@ NO_TEST = Yes BUILD_DEPENDS = devel/bison \ devel/gettext,-tools \ - devel/gperf \ - geo/geoclue2 \ - wayland/wayland-protocols - -RUN_DEPENDS = geo/geoclue2 \ - multimedia/gstreamer1/plugins-good - -LIB_DEPENDS = archivers/woff2 \ - devel/harfbuzz,-icu \ - graphics/libavif \ - graphics/libjxl \ - graphics/libwebp \ + devel/gperf + +RUN_DEPENDS = multimedia/gstreamer1/plugins-good + +LIB_DEPENDS = devel/harfbuzz,-icu \ + devel/libsoup \ graphics/openjp2 \ multimedia/gstreamer1/plugins-base \ multimedia/gstreamer1/plugins-bad \ - textproc/enchant2 \ - textproc/hyphen \ - textproc/libxslt \ - www/wpebackend-fdo \ - x11/gnome/libsecret + x11/gtk+3 CONFIGURE_ENV = WK_USE_CCACHE=NO CONFIGURE_ARGS = -DPORT=GTK \ - -DENABLE_MINIBROWSER=ON \ - -DENABLE_JOURNALD_LOG=OFF - -# until proven useful -# see defaults in Source/WTF/wtf/PlatformEnable.h -#CONFIGURE_ARGS += -DENABLE_WEBASSEMBLY=ON -#CONFIGURE_ARGS += -DENABLE_WEBASSEMBLY_B3JIT=ON + -DENABLE_3D_TRANSFORMS=OFF \ + -DENABLE_ACCESSIBILITY=OFF \ + -DENABLE_DARK_MODE_CSS=ON \ + -DENABLE_DOCUMENTATION=OFF \ + -DENABLE_GAMEPAD=OFF \ + -DENABLE_GEOLOCATION=OFF \ + -DENABLE_INTROSPECTION=OFF \ + -DENABLE_JOURNALD_LOG=OFF \ + -DENABLE_MANAGED_MEDIA_SOURCE=ON \ + -DENABLE_MATHML=ON \ + -DENABLE_MINIBROWSER=OFF \ + -DENABLE_MODERN_MEDIA_CONTROLS=OFF \ + -DENABLE_JOURNALD_LOG=OFF \ + -DENABLE_PDFJS=OFF \ + -DENABLE_QUARTZ_TARGET=OFF \ + -DENABLE_REMOTE_INSPECTOR=OFF \ + -DENABLE_SMOOTH_SCROLLING=OFF \ + -DENABLE_SPELLCHECK=OFF \ + -DENABLE_WAYLAND_TARGET=OFF \ + -DENABLE_WEBASSEMBLY=OFF \ + -DENABLE_WEBDRIVER=OFF \ + -DENABLE_WEBP=OFF \ + -DENABLE_WEBGL=OFF \ + -DENABLE_WEBINSPECTORUI=ON \ + -DENABLE_XSLT=OFF \ + -DUSE_ATSPI=OFF \ + -DUSE_AVIF=OFF \ + -DUSE_GBM=OFF \ + -DUSE_GSTREAMER_TRANSCODER=OFF \ + -DUSE_GTK4=OFF \ + -DUSE_LCMS=OFF \ + -DUSE_JPEGXL=OFF \ + -DUSE_LIBEPOXY=ON \ + -DUSE_LIBHYPHEN=OFF \ + -DUSE_LIBSECRET=OFF \ + -DUSE_LIBWEBRTC=OFF \ + -DUSE_SOUP2=ON \ + -DUSE_THEME_ADWAITA=OFF \ + -DUSE_WPE_RENDERER=OFF \ + -DUSE_WOFF2=OFF \ + -DUSER_AGENT_BRANDING="" # XXX broken at runtime #CONFIGURE_ARGS += -DUSE_SYSTEM_MALLOC=ON -# required for faking a better user-agent -.if ${MACHINE_ARCH} == "amd64" -CPUARCH = x86_64 -.else -CPUARCH = ${ARCH} -.endif -#XXXTODO CONFIGURE_ARGS += -DUSER_AGENT_BRANDING="Linux ${CPUARCH}; OpenBSD ${ARCH}" -CONFIGURE_ARGS += -DUSER_AGENT_BRANDING="Linux ${CPUARCH}" - -# Needs GUdev -CONFIGURE_ARGS += -DENABLE_GAMEPAD=OFF - # sync with Source/JavaScriptCore/assembler/MacroAssembler.h .if ${MACHINE_ARCH} != "aarch64" && ${MACHINE_ARCH} != "amd64" && \ ${MACHINE_ARCH} != "arm" && ${MACHINE_ARCH} != "i386" && \ @@ -157,32 +168,6 @@ LDFLAGS += -Wl,--no-keep-memory DPB_PROPERTIES = parallel parallel2 lonesome .endif -FLAVORS = webkitgtk41 webkitgtk60 -FLAVOR ?= - -.if ${FLAVOR:Mwebkitgtk41} -API = 4.1 -WANTLIB += atk-1.0 gdk-3 gtk-3 soup-3.0 -LIB_DEPENDS += devel/libsoup3 \ - x11/gtk+3 -CONFIGURE_ARGS += -DUSE_SOUP2=OFF \ - -DENABLE_WEBDRIVER=OFF -.elif ${FLAVOR:Mwebkitgtk60} -API = 6.0 -WANTLIB += graphene-1.0 gtk-4 soup-3.0 -LIB_DEPENDS += devel/libsoup3 \ - x11/gtk+4 -CONFIGURE_ARGS += -DUSE_SOUP2=OFF \ - -DUSE_GTK4=ON -.else -API = 4.0 -WANTLIB += atk-1.0 gdk-3 gtk-3 soup-2.4 -LIB_DEPENDS += devel/libsoup \ - x11/gtk+3 -CONFIGURE_ARGS += -DUSE_SOUP2=ON \ - -DENABLE_WEBDRIVER=OFF -.endif - post-extract: ln -sf ${RUBY} ${WRKDIR}/bin/ruby diff --git a/www/webkitgtk4/patches/patch-Source_JavaScriptCore_jsc_cpp b/www/webkitgtk4/patches/patch-Source_JavaScriptCore_jsc_cpp deleted file mode 100644 index 679d2bb..0000000 --- a/www/webkitgtk4/patches/patch-Source_JavaScriptCore_jsc_cpp +++ /dev/null @@ -1,11 +0,0 @@ -Index: Source/JavaScriptCore/jsc.cpp ---- Source/JavaScriptCore/jsc.cpp.orig -+++ Source/JavaScriptCore/jsc.cpp -@@ -78,6 +78,7 @@ - #include "WasmCapabilities.h" - #include "WasmFaultSignalHandler.h" - #include "WasmMemory.h" -+#include /* LC_ALL */ - #include - #include - #include diff --git a/www/webkitgtk4/patches/patch-Source_JavaScriptCore_runtime_MachineContext_h b/www/webkitgtk4/patches/patch-Source_JavaScriptCore_runtime_MachineContext_h index a08d371..695ab2e 100644 --- a/www/webkitgtk4/patches/patch-Source_JavaScriptCore_runtime_MachineContext_h +++ b/www/webkitgtk4/patches/patch-Source_JavaScriptCore_runtime_MachineContext_h @@ -76,35 +76,53 @@ Index: Source/JavaScriptCore/runtime/MachineContext.h #elif OS(FUCHSIA) || OS(LINUX) // The following sequence depends on glibc's sys/ucontext.h. -@@ -652,6 +706,24 @@ inline void*& argumentPointer<1>(mcontext_t& machineCo +@@ -771,6 +825,42 @@ inline void*& llintInstructionPointer(mcontext_t& mach #error Unknown Architecture #endif +#elif OS(OPENBSD) + +#if CPU(X86) -+ return reinterpret_cast((uintptr_t&) machineContext.sc_edx); ++ return reinterpret_cast((uintptr_t&) machineContext.sc_esi); +#elif CPU(X86_64) -+ return reinterpret_cast((uintptr_t&) machineContext.sc_rsi); -+#elif CPU(ARM) -+ return reinterpret_cast((uintptr_t&) machineContext.__gregs[_REG_R1]); ++ return reinterpret_cast((uintptr_t&) machineContext.sc_r8); ++#elif CPU(ARM) ++ return reinterpret_cast((uintptr_t&) machineContext.__gregs[_REG_R8]); +#elif CPU(ARM64) -+ return reinterpret_cast((uintptr_t&) machineContext.sc_x[1]); ++ return reinterpret_cast((uintptr_t&) machineContext.sc_x[4]); +#elif CPU(MIPS) -+ return reinterpret_cast((uintptr_t&) machineContext.mc_regs[5]); ++ return reinterpret_cast((uintptr_t&) machineContext.mc_regs[12]); +#elif CPU(RISCV64) -+ return reinterpret_cast((uintptr_t&) machineContext.sc_a[1]); ++ return reinterpret_cast((uintptr_t&) machineContext.sc_a[3]); +#else +#error Unknown Architecture +#endif + - #elif OS(FUCHSIA) || OS(LINUX) ++#elif OS(OPENBSD) ++ ++#if CPU(X86) ++ return reinterpret_cast((uintptr_t&) machineContext.sc_esi); ++#elif CPU(X86_64) ++ return reinterpret_cast((uintptr_t&) machineContext.sc_r8); ++#elif CPU(ARM) ++ return reinterpret_cast((uintptr_t&) machineContext.__gregs[_REG_R8]); ++#elif CPU(ARM64) ++ return reinterpret_cast((uintptr_t&) machineContext.sc_x[4]); ++#elif CPU(MIPS) ++ return reinterpret_cast((uintptr_t&) machineContext.mc_regs[12]); ++#elif CPU(RISCV64) ++ return reinterpret_cast((uintptr_t&) machineContext.sc_a[3]); ++#else ++#error Unknown Architecture ++#endif ++ + #elif OS(NETBSD) - // The following sequence depends on glibc's sys/ucontext.h. -@@ -767,6 +839,24 @@ inline void*& llintInstructionPointer(mcontext_t& mach - return reinterpret_cast((uintptr_t&) machineContext.mc_gpregs.gp_x[4]); + #if CPU(X86) +@@ -783,6 +873,24 @@ inline void*& llintInstructionPointer(mcontext_t& mach + return reinterpret_cast((uintptr_t&) machineContext.__gregs[_REG_X4]); #elif CPU(MIPS) - return reinterpret_cast((uintptr_t&) machineContext.mc_regs[12]); + return reinterpret_cast((uintptr_t&) machineContext.__gregs[_REG_T4]); +#else +#error Unknown Architecture +#endif @@ -112,17 +130,17 @@ Index: Source/JavaScriptCore/runtime/MachineContext.h +#elif OS(OPENBSD) + +#if CPU(X86) -+ return reinterpret_cast((uintptr_t&) machineContext.sc_esi); ++ return reinterpret_cast((uintptr_t&) machineContext.sc_edx); +#elif CPU(X86_64) -+ return reinterpret_cast((uintptr_t&) machineContext.sc_r8); ++ return reinterpret_cast((uintptr_t&) machineContext.sc_rsi); +#elif CPU(ARM) -+ return reinterpret_cast((uintptr_t&) machineContext.__gregs[_REG_R8]); ++ return reinterpret_cast((uintptr_t&) machineContext.__gregs[_REG_R1]); +#elif CPU(ARM64) -+ return reinterpret_cast((uintptr_t&) machineContext.sc_x[4]); ++ return reinterpret_cast((uintptr_t&) machineContext.sc_x[1]); +#elif CPU(MIPS) -+ return reinterpret_cast((uintptr_t&) machineContext.mc_regs[12]); ++ return reinterpret_cast((uintptr_t&) machineContext.mc_regs[5]); +#elif CPU(RISCV64) -+ return reinterpret_cast((uintptr_t&) machineContext.sc_a[3]); ++ return reinterpret_cast((uintptr_t&) machineContext.sc_a[1]); #else #error Unknown Architecture #endif diff --git a/www/webkitgtk4/patches/patch-Source_JavaScriptCore_runtime_MachineContext_h.orig b/www/webkitgtk4/patches/patch-Source_JavaScriptCore_runtime_MachineContext_h.orig new file mode 100644 index 0000000..a08d371 --- /dev/null +++ b/www/webkitgtk4/patches/patch-Source_JavaScriptCore_runtime_MachineContext_h.orig @@ -0,0 +1,128 @@ +Index: Source/JavaScriptCore/runtime/MachineContext.h +--- Source/JavaScriptCore/runtime/MachineContext.h.orig ++++ Source/JavaScriptCore/runtime/MachineContext.h +@@ -193,6 +193,24 @@ static inline void*& stackPointerImpl(mcontext_t& mach + #error Unknown Architecture + #endif + ++#elif OS(OPENBSD) ++ ++#if CPU(X86) ++ return reinterpret_cast((uintptr_t&) machineContext.sc_esp); ++#elif CPU(X86_64) ++ return reinterpret_cast((uintptr_t&) machineContext.sc_rsp); ++#elif CPU(ARM) ++ return reinterpret_cast((uintptr_t&) machineContext.__gregs[_REG_SP]); ++#elif CPU(ARM64) ++ return reinterpret_cast((uintptr_t&) machineContext.sc_sp); ++#elif CPU(MIPS) ++ return reinterpret_cast((uintptr_t&) machineContext.mc_regs[29]); ++#elif CPU(RISCV64) ++ return reinterpret_cast((uintptr_t&) machineContext.sc_sp); ++#else ++#error Unknown Architecture ++#endif ++ + #elif OS(FUCHSIA) || OS(LINUX) + + #if CPU(X86) +@@ -338,6 +356,24 @@ static inline void*& framePointerImpl(mcontext_t& mach + #error Unknown Architecture + #endif + ++#elif OS(OPENBSD) ++ ++#if CPU(X86) ++ return reinterpret_cast((uintptr_t&) machineContext.sc_ebp); ++#elif CPU(X86_64) ++ return reinterpret_cast((uintptr_t&) machineContext.sc_rbp); ++#elif CPU(ARM) ++ return reinterpret_cast((uintptr_t&) machineContext.__gregs[_REG_FP]); ++#elif CPU(ARM64) ++ return reinterpret_cast((uintptr_t&) machineContext.sc_x[29]); ++#elif CPU(MIPS) ++ return reinterpret_cast((uintptr_t&) machineContext.mc_regs[30]); ++#elif CPU(RISCV64) ++ return reinterpret_cast((uintptr_t&) machineContext.sc_s[0]); ++#else ++#error Unknown Architecture ++#endif ++ + #elif OS(FUCHSIA) || OS(LINUX) + + // The following sequence depends on glibc's sys/ucontext.h. +@@ -496,6 +532,24 @@ static inline void*& instructionPointerImpl(mcontext_t + #error Unknown Architecture + #endif + ++#elif OS(OPENBSD) ++ ++#if CPU(X86) ++ return reinterpret_cast((uintptr_t&) machineContext.sc_eip); ++#elif CPU(X86_64) ++ return reinterpret_cast((uintptr_t&) machineContext.sc_rip); ++#elif CPU(ARM) ++ return reinterpret_cast((uintptr_t&) machineContext.__gregs[_REG_PC]); ++#elif CPU(ARM64) ++ return reinterpret_cast((uintptr_t&) machineContext.sc_elr); ++#elif CPU(MIPS) ++ return reinterpret_cast((uintptr_t&) machineContext.mc_pc); ++#elif CPU(RISCV64) ++ return reinterpret_cast((uintptr_t&) machineContext.sc_sepc); ++#else ++#error Unknown Architecture ++#endif ++ + #elif OS(FUCHSIA) || OS(LINUX) + + // The following sequence depends on glibc's sys/ucontext.h. +@@ -652,6 +706,24 @@ inline void*& argumentPointer<1>(mcontext_t& machineCo + #error Unknown Architecture + #endif + ++#elif OS(OPENBSD) ++ ++#if CPU(X86) ++ return reinterpret_cast((uintptr_t&) machineContext.sc_edx); ++#elif CPU(X86_64) ++ return reinterpret_cast((uintptr_t&) machineContext.sc_rsi); ++#elif CPU(ARM) ++ return reinterpret_cast((uintptr_t&) machineContext.__gregs[_REG_R1]); ++#elif CPU(ARM64) ++ return reinterpret_cast((uintptr_t&) machineContext.sc_x[1]); ++#elif CPU(MIPS) ++ return reinterpret_cast((uintptr_t&) machineContext.mc_regs[5]); ++#elif CPU(RISCV64) ++ return reinterpret_cast((uintptr_t&) machineContext.sc_a[1]); ++#else ++#error Unknown Architecture ++#endif ++ + #elif OS(FUCHSIA) || OS(LINUX) + + // The following sequence depends on glibc's sys/ucontext.h. +@@ -767,6 +839,24 @@ inline void*& llintInstructionPointer(mcontext_t& mach + return reinterpret_cast((uintptr_t&) machineContext.mc_gpregs.gp_x[4]); + #elif CPU(MIPS) + return reinterpret_cast((uintptr_t&) machineContext.mc_regs[12]); ++#else ++#error Unknown Architecture ++#endif ++ ++#elif OS(OPENBSD) ++ ++#if CPU(X86) ++ return reinterpret_cast((uintptr_t&) machineContext.sc_esi); ++#elif CPU(X86_64) ++ return reinterpret_cast((uintptr_t&) machineContext.sc_r8); ++#elif CPU(ARM) ++ return reinterpret_cast((uintptr_t&) machineContext.__gregs[_REG_R8]); ++#elif CPU(ARM64) ++ return reinterpret_cast((uintptr_t&) machineContext.sc_x[4]); ++#elif CPU(MIPS) ++ return reinterpret_cast((uintptr_t&) machineContext.mc_regs[12]); ++#elif CPU(RISCV64) ++ return reinterpret_cast((uintptr_t&) machineContext.sc_a[3]); + #else + #error Unknown Architecture + #endif diff --git a/www/webkitgtk4/patches/patch-Source_WTF_wtf_PlatformHave_h b/www/webkitgtk4/patches/patch-Source_WTF_wtf_PlatformHave_h index 4be2495..a068735 100644 --- a/www/webkitgtk4/patches/patch-Source_WTF_wtf_PlatformHave_h +++ b/www/webkitgtk4/patches/patch-Source_WTF_wtf_PlatformHave_h @@ -15,4 +15,4 @@ Index: Source/WTF/wtf/PlatformHave.h + #if OS(DARWIN) || (OS(LINUX) && defined(__GLIBC__) && !defined(__UCLIBC__) && !CPU(MIPS)) #define HAVE_BACKTRACE 1 - #endif + #define HAVE_BACKTRACE_SYMBOLS 1 diff --git a/www/webkitgtk4/patches/patch-Source_WTF_wtf_PlatformHave_h.orig b/www/webkitgtk4/patches/patch-Source_WTF_wtf_PlatformHave_h.orig new file mode 100644 index 0000000..4e7d746 --- /dev/null +++ b/www/webkitgtk4/patches/patch-Source_WTF_wtf_PlatformHave_h.orig @@ -0,0 +1,18 @@ +Undo parts of upstream commit 6c2615dd66a12e9a10d7867241cc3bedfb2b2473 [0] +Machine context definitions were only added for Linux. +[0] https://github.com/WebKit/WebKit/commit/6c2615dd66a12e9a10d7867241cc3bedfb2b2473 + +Index: Source/WTF/wtf/PlatformHave.h +--- Source/WTF/wtf/PlatformHave.h.orig ++++ Source/WTF/wtf/PlatformHave.h +@@ -241,6 +241,10 @@ + #undef HAVE_MACHINE_CONTEXT + #endif + ++#if OS(OPENBSD) && CPU(RISCV64) ++#undef HAVE_MACHINE_CONTEXT ++#endif ++ + #if OS(DARWIN) || (OS(LINUX) && defined(__GLIBC__) && !defined(__UCLIBC__) && !CPU(MIPS)) + #define HAVE_BACKTRACE 1 + #define HAVE_BACKTRACE_SYMBOLS 1 diff --git a/www/webkitgtk4/patches/patch-Source_WTF_wtf_PlatformUse_h b/www/webkitgtk4/patches/patch-Source_WTF_wtf_PlatformUse_h new file mode 100644 index 0000000..cade9db --- /dev/null +++ b/www/webkitgtk4/patches/patch-Source_WTF_wtf_PlatformUse_h @@ -0,0 +1,12 @@ +Index: Source/WTF/wtf/PlatformUse.h +--- Source/WTF/wtf/PlatformUse.h.orig ++++ Source/WTF/wtf/PlatformUse.h +@@ -83,7 +83,7 @@ + #endif + + #if PLATFORM(GTK) || PLATFORM(WPE) +-#define USE_WEBP 1 ++#define USE_WEBP 0 + #endif + + #if PLATFORM(COCOA) diff --git a/www/webkitgtk4/patches/patch-Source_WebKit_Platform_IPC_ArgumentCoders_h b/www/webkitgtk4/patches/patch-Source_WebKit_Platform_IPC_ArgumentCoders_h deleted file mode 100644 index c564b39..0000000 --- a/www/webkitgtk4/patches/patch-Source_WebKit_Platform_IPC_ArgumentCoders_h +++ /dev/null @@ -1,115 +0,0 @@ -https://bugs.webkit.org/show_bug.cgi?id=245044 -REVERT: -From: "zan@falconsigh.net" -Date: Tue, 12 Apr 2022 06:30:51 +0000 -Subject: [PATCH] [WK2] Simplify IPC encoding, decoding of tuples https://bugs.webkit.org/show_bug.cgi?id=239062 - -Index: Source/WebKit/Platform/IPC/ArgumentCoders.h ---- Source/WebKit/Platform/IPC/ArgumentCoders.h.orig -+++ Source/WebKit/Platform/IPC/ArgumentCoders.h -@@ -495,26 +495,38 @@ template struct ArgumentCoder> { - } - }; - --template -+template - struct TupleEncoder { - template - static void encode(Encoder& encoder, const std::tuple& tuple) - { -- encode(encoder, tuple, std::index_sequence_for { }); -+ encoder << std::get(tuple); -+ TupleEncoder::encode(encoder, tuple); - } -+}; - -- template -- static void encode(Encoder& encoder, const std::tuple& tuple, std::index_sequence) -+template -+struct TupleEncoder<0, Elements...> { -+ template -+ static void encode(Encoder&, const std::tuple&) - { -- if constexpr (sizeof...(Indices) > 0) -- (encoder << ... << std::get(tuple)); - } - }; - --template struct TupleDecoder; -+template -+auto tupleFromTupleAndObject(T&& object, std::tuple&& tuple, std::index_sequence) -+{ -+ return std::make_tuple(WTFMove(object), WTFMove(std::get(tuple))...); -+} - -+template -+auto tupleFromTupleAndObject(T&& object, std::tuple&& tuple) -+{ -+ return tupleFromTupleAndObject(WTFMove(object), WTFMove(tuple), std::index_sequence_for()); -+} -+ - template --struct TupleDecoder { -+struct TupleDecoderImpl { - template - static std::optional> decode(Decoder& decoder) - { -@@ -523,16 +535,38 @@ struct TupleDecoder { - if (!optional) - return std::nullopt; - -- std::optional> remainder = TupleDecoder::decode(decoder); -- if (!remainder) -+ std::optional> subTuple = TupleDecoderImpl::decode(decoder); -+ if (!subTuple) - return std::nullopt; - -- return std::tuple_cat(std::make_tuple(WTFMove(*optional)), WTFMove(*remainder)); -+ return tupleFromTupleAndObject(WTFMove(*optional), WTFMove(*subTuple)); - } - }; - -+template -+struct TupleDecoderImpl { -+ template -+ static std::optional> decode(Decoder& decoder) -+ { -+ std::optional optional; -+ decoder >> optional; -+ if (!optional) -+ return std::nullopt; -+ return std::make_tuple(WTFMove(*optional)); -+ } -+}; -+ -+template -+struct TupleDecoder { -+ template -+ static std::optional> decode(Decoder& decoder) -+ { -+ return TupleDecoderImpl::decode(decoder); -+ } -+}; -+ - template<> --struct TupleDecoder<> { -+struct TupleDecoder<0> { - template - static std::optional> decode(Decoder&) - { -@@ -544,13 +578,13 @@ template struct ArgumentCoder - static void encode(Encoder& encoder, const std::tuple& tuple) - { -- TupleEncoder::encode(encoder, tuple); -+ TupleEncoder::encode(encoder, tuple); - } - - template - static std::optional> decode(Decoder& decoder) - { -- return TupleDecoder::decode(decoder); -+ return TupleDecoder::decode(decoder); - } - }; - diff --git a/www/webkitgtk4/patches/patch-Source_WebKit_gtk_webkit2gtk-web-extension_pc_in b/www/webkitgtk4/patches/patch-Source_WebKit_gtk_webkit2gtk-web-extension_pc_in deleted file mode 100644 index f3426ac..0000000 --- a/www/webkitgtk4/patches/patch-Source_WebKit_gtk_webkit2gtk-web-extension_pc_in +++ /dev/null @@ -1,10 +0,0 @@ -Index: Source/WebKit/gtk/webkit2gtk-web-extension.pc.in ---- Source/WebKit/gtk/webkit2gtk-web-extension.pc.in.orig -+++ Source/WebKit/gtk/webkit2gtk-web-extension.pc.in -@@ -9,5 +9,5 @@ Description: Web content engine for GTK - web process - URL: https://webkitgtk.org - Version: @PROJECT_VERSION@ - Requires: glib-2.0 @GTK_PC_NAME@ libsoup-@SOUP_API_VERSION@ javascriptcoregtk-@WEBKITGTK_API_VERSION@ --Libs: -L${libdir} -lwebkit2gtk-@WEBKITGTK_API_VERSION@ -+Libs: -L${libdir} -lwebkit2gtk-@WEBKITGTK_API_VERSION@ -Wl,-z,wxneeded - Cflags: -I${includedir}/webkitgtk-@WEBKITGTK_API_VERSION@ diff --git a/www/webkitgtk4/patches/patch-Source_WebKit_gtk_webkit2gtk_pc_in b/www/webkitgtk4/patches/patch-Source_WebKit_gtk_webkit2gtk_pc_in deleted file mode 100644 index 563d209..0000000 --- a/www/webkitgtk4/patches/patch-Source_WebKit_gtk_webkit2gtk_pc_in +++ /dev/null @@ -1,10 +0,0 @@ -Index: Source/WebKit/gtk/webkit2gtk.pc.in ---- Source/WebKit/gtk/webkit2gtk.pc.in.orig -+++ Source/WebKit/gtk/webkit2gtk.pc.in -@@ -9,5 +9,5 @@ Description: Web content engine for GTK - URL: https://webkitgtk.org - Version: @PROJECT_VERSION@ - Requires: glib-2.0 @GTK_PC_NAME@ libsoup-@SOUP_API_VERSION@ javascriptcoregtk-@WEBKITGTK_API_VERSION@ --Libs: -L${libdir} -lwebkit2gtk-@WEBKITGTK_API_VERSION@ -+Libs: -L${libdir} -lwebkit2gtk-@WEBKITGTK_API_VERSION@ -Wl,-z,wxneeded - Cflags: -I${includedir}/webkitgtk-@WEBKITGTK_API_VERSION@ -- cgit v1.2.3