diff --git a/net-libs/webkit-gtk/patches/webkit_gtk-2.38.2.patchset b/net-libs/webkit-gtk/patches/webkit_gtk-2.39.3.patchset similarity index 75% rename from net-libs/webkit-gtk/patches/webkit_gtk-2.38.2.patchset rename to net-libs/webkit-gtk/patches/webkit_gtk-2.39.3.patchset index 385dc55ba..5fcab928f 100644 --- a/net-libs/webkit-gtk/patches/webkit_gtk-2.38.2.patchset +++ b/net-libs/webkit-gtk/patches/webkit_gtk-2.39.3.patchset @@ -1,24 +1,33 @@ -From bf907dee59d3c74a4138a460e6921569ebda24ef Mon Sep 17 00:00:00 2001 +From 108cd7c7cf1411d4547672cb1e836a6c6e46732f Mon Sep 17 00:00:00 2001 From: Gerasim Troeglazov <3dEyes@gmail.com> -Date: Mon, 7 Nov 2022 16:36:35 +1000 -Subject: Fix for Haiku +Date: Sat, 17 Dec 2022 23:35:27 +1000 +Subject: Fixe build for Haiku -diff --git a/Source/JavaScriptCore/b3/B3WasmBoundsCheckValue.cpp b/Source/JavaScriptCore/b3/B3WasmBoundsCheckValue.cpp -index 597d086..7cf69d4 100644 ---- a/Source/JavaScriptCore/b3/B3WasmBoundsCheckValue.cpp -+++ b/Source/JavaScriptCore/b3/B3WasmBoundsCheckValue.cpp -@@ -50,7 +50,7 @@ WasmBoundsCheckValue::WasmBoundsCheckValue(Origin origin, Value* ptr, unsigned o - , m_offset(offset) - , m_boundsType(Type::Maximum) +diff --git a/Source/JavaScriptCore/API/glib/JSCOptions.cpp b/Source/JavaScriptCore/API/glib/JSCOptions.cpp +index dd46ff5..54f6dac 100644 +--- a/Source/JavaScriptCore/API/glib/JSCOptions.cpp ++++ b/Source/JavaScriptCore/API/glib/JSCOptions.cpp +@@ -73,7 +73,7 @@ static void valueToGValue(int32_t value, GValue* gValue) + g_value_set_int(gValue, value); + } + +-#if CPU(ADDRESS64) ++#if CPU(ADDRESS64) || OS(HAIKU) + static bool valueFromGValue(const GValue* gValue, unsigned& value) { --#if ENABLE(WEBASSEMBLY) -+#if ENABLE(WEBASSEMBLY_SIGNALING_MEMORY) - size_t redzoneLimit = static_cast(std::numeric_limits::max()) + Wasm::Memory::fastMappedRedzoneBytes(); - ASSERT_UNUSED(redzoneLimit, maximum <= redzoneLimit); - #endif + value = g_value_get_uint(gValue); +@@ -556,7 +556,7 @@ static JSCOptionType jscOptionsType(int) + return JSC_OPTION_INT; + } + +-#if CPU(ADDRESS64) ++#if CPU(ADDRESS64) || OS(HAIKU) + static JSCOptionType jscOptionsType(unsigned) + { + return JSC_OPTION_UINT; diff --git a/Source/JavaScriptCore/heap/BlockDirectory.cpp b/Source/JavaScriptCore/heap/BlockDirectory.cpp -index e2a3540..6c72cc5 100644 +index f9df6f0..b456f9a 100644 --- a/Source/JavaScriptCore/heap/BlockDirectory.cpp +++ b/Source/JavaScriptCore/heap/BlockDirectory.cpp @@ -60,7 +60,7 @@ void BlockDirectory::setSubspace(Subspace* subspace) @@ -44,28 +53,434 @@ index e52143c..4ac504c 100644 + network + ) +endif () -diff --git a/Source/ThirdParty/ANGLE/src/common/system_utils_posix.cpp b/Source/ThirdParty/ANGLE/src/common/system_utils_posix.cpp -index cc8c618..8b9d638 100644 ---- a/Source/ThirdParty/ANGLE/src/common/system_utils_posix.cpp -+++ b/Source/ThirdParty/ANGLE/src/common/system_utils_posix.cpp -@@ -199,10 +199,12 @@ void *OpenSystemLibraryWithExtensionAndGetError(const char *libraryName, - } +diff --git a/Source/JavaScriptCore/runtime/Options.cpp b/Source/JavaScriptCore/runtime/Options.cpp +index ddb01fc..efda985 100644 +--- a/Source/JavaScriptCore/runtime/Options.cpp ++++ b/Source/JavaScriptCore/runtime/Options.cpp +@@ -91,7 +91,7 @@ std::optional parse(const char* string) + return std::nullopt; + } - int extraFlags = 0; -+#ifndef __HAIKU__ - if (searchType == SearchType::AlreadyLoaded) - { - extraFlags = RTLD_NOLOAD; +-#if CPU(ADDRESS64) || OS(DARWIN) ++#if CPU(ADDRESS64) || OS(DARWIN) || OS(HAIKU) + template<> + std::optional parse(const char* string) + { +@@ -100,7 +100,7 @@ std::optional parse(const char* string) + return value; + return std::nullopt; + } +-#endif // CPU(ADDRESS64) || OS(DARWIN) ++#endif // CPU(ADDRESS64) || OS(DARWIN) || OS(HAIKU) + + template<> + std::optional parse(const char* string) +diff --git a/Source/WebCore/inspector/InspectorFrontendHost.cpp b/Source/WebCore/inspector/InspectorFrontendHost.cpp +index 5c4e75c..18e7db0 100644 +--- a/Source/WebCore/inspector/InspectorFrontendHost.cpp ++++ b/Source/WebCore/inspector/InspectorFrontendHost.cpp +@@ -395,6 +395,8 @@ String InspectorFrontendHost::platform() const + return "mac"_s; + #elif OS(WINDOWS) + return "windows"_s; ++#elif OS(HAIKU) ++ return "haiku"_s; + #elif OS(LINUX) + return "linux"_s; + #elif OS(FREEBSD) +diff --git a/Source/WebCore/page/NavigatorBase.cpp b/Source/WebCore/page/NavigatorBase.cpp +index 2bd1a7c..e8f592e 100644 +--- a/Source/WebCore/page/NavigatorBase.cpp ++++ b/Source/WebCore/page/NavigatorBase.cpp +@@ -100,6 +100,8 @@ String NavigatorBase::platform() const + return deviceName(); + #elif OS(MAC_OS_X) + return "MacIntel"_s; ++#elif OS(HAIKU) ++ return "Haiku"_s; + #elif OS(WINDOWS) + return "Win32"_s; + #else +diff --git a/Source/WebCore/platform/graphics/gbm/GraphicsContextGLANGLELinux.cpp b/Source/WebCore/platform/graphics/gbm/GraphicsContextGLANGLELinux.cpp +index f8627d2..1244edb 100644 +--- a/Source/WebCore/platform/graphics/gbm/GraphicsContextGLANGLELinux.cpp ++++ b/Source/WebCore/platform/graphics/gbm/GraphicsContextGLANGLELinux.cpp +@@ -108,7 +108,7 @@ RefPtr GraphicsContextGLANGLE::readCompositedResults() + + bool GraphicsContextGLANGLE::makeContextCurrent() + { +- static thread_local TLS_MODEL_INITIAL_EXEC GraphicsContextGLANGLE* s_currentContext { nullptr }; ++ static __thread GraphicsContextGLANGLE* s_currentContext { nullptr }; + + if (s_currentContext == this) + return true; +diff --git a/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp b/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp +index 8035d83..a47c675 100644 +--- a/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp ++++ b/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp +@@ -2220,6 +2220,8 @@ void MediaPlayerPrivateGStreamer::configureDownloadBuffer(GstElement* element) + GUniquePtr defaultValue(g_build_filename(G_DIR_SEPARATOR_S, "var", "tmp", nullptr)); + mediaDiskCachePath.swap(defaultValue); } ++#elif defined(__HAIKU__) ++ GUniquePtr mediaDiskCachePath(g_build_filename(G_DIR_SEPARATOR_S, "system", "cache", "tmp", nullptr)); + #else + GUniquePtr mediaDiskCachePath(g_build_filename(G_DIR_SEPARATOR_S, "var", "tmp", nullptr)); + #endif +diff --git a/Source/WebKit/CMakeLists.txt b/Source/WebKit/CMakeLists.txt +index b0a8dc6..f5100da 100644 +--- a/Source/WebKit/CMakeLists.txt ++++ b/Source/WebKit/CMakeLists.txt +@@ -415,6 +415,10 @@ if (UNIX) + endif () + endif () + ++if (HAIKU) ++ list(APPEND WebKit_PRIVATE_LIBRARIES network) ++endif () ++ + macro(ADD_WEBKIT_PREFIX_HEADER _target) + if (WebKit_USE_PREFIX_HEADER) + get_target_property(OLD_COMPILE_FLAGS ${_target} COMPILE_FLAGS) +diff --git a/Source/WebKit/Platform/IPC/Connection.cpp b/Source/WebKit/Platform/IPC/Connection.cpp +index ed497a2..ab5c32d 100644 +--- a/Source/WebKit/Platform/IPC/Connection.cpp ++++ b/Source/WebKit/Platform/IPC/Connection.cpp +@@ -1121,8 +1121,11 @@ void Connection::didFailToSendSyncMessage() + { + if (!m_shouldExitOnSyncMessageSendFailure) + return; +- ++#if OS(HAIKU) ++ kill(::getpid(), SIGKILL); ++#else + exit(0); ++#endif + } + + void Connection::enqueueIncomingMessage(std::unique_ptr incomingMessage) +diff --git a/Source/WebKit/Platform/IPC/unix/ConnectionUnix.cpp b/Source/WebKit/Platform/IPC/unix/ConnectionUnix.cpp +index e01364f..355a516 100644 +--- a/Source/WebKit/Platform/IPC/unix/ConnectionUnix.cpp ++++ b/Source/WebKit/Platform/IPC/unix/ConnectionUnix.cpp +@@ -230,7 +230,7 @@ bool Connection::processMessage() + return true; + } + +-static ssize_t readBytesFromSocket(int socketDescriptor, Vector& buffer, Vector& fileDescriptors) ++static ssize_t readBytesFromSocket(int socketDescriptor, Vector& buffer, Vector& fileDescriptors, size_t size) + { + struct msghdr message; + memset(&message, 0, sizeof(message)); +@@ -246,7 +246,7 @@ static ssize_t readBytesFromSocket(int socketDescriptor, Vector& buffer + size_t previousBufferSize = buffer.size(); + buffer.grow(buffer.capacity()); + iov[0].iov_base = buffer.data() + previousBufferSize; +- iov[0].iov_len = buffer.size() - previousBufferSize; ++ iov[0].iov_len = size; + + message.msg_iov = iov; + message.msg_iovlen = 1; +@@ -297,6 +297,20 @@ static ssize_t readBytesFromSocket(int socketDescriptor, Vector& buffer + return -1; + } + ++static ssize_t readBytesFromSocket(int socketDescriptor, Vector& buffer, Vector& fileDescriptors) ++{ ++ ssize_t bytesRead = readBytesFromSocket(socketDescriptor, buffer, fileDescriptors, sizeof(MessageInfo)); ++ if (bytesRead <= 0) return bytesRead; ++ uint8_t* messageData = buffer.data(); ++ MessageInfo messageInfo; ++ memcpy(static_cast(&messageInfo), messageData, sizeof(messageInfo)); ++ messageData += sizeof(messageInfo); ++ size_t messageLength = messageInfo.attachmentCount() * sizeof(AttachmentInfo) + (messageInfo.isBodyOutOfLine() ? 0 : messageInfo.bodySize()); ++ if (messageLength == 0) return bytesRead; ++ bytesRead = readBytesFromSocket(socketDescriptor, buffer, fileDescriptors, messageLength); ++ return bytesRead; ++} ++ + void Connection::readyReadHandler() + { + while (true) { +@@ -545,7 +559,11 @@ bool Connection::sendOutputMessage(UnixMessage& outputMessage) + SocketPair createPlatformConnection(unsigned options) + { + int sockets[2]; ++#ifdef __HAIKU__ ++ RELEASE_ASSERT(socketpair(AF_LOCAL, SOCK_STREAM, 0, sockets) != -1); ++#else + RELEASE_ASSERT(socketpair(AF_UNIX, SOCKET_TYPE, 0, sockets) != -1); +#endif - std::string fullPath = directory + libraryName; - #if ANGLE_PLATFORM_IOS + if (options & SetCloexecOnServer) { + // Don't expose the child socket to the parent process. +diff --git a/Source/WebKit/Shared/AuxiliaryProcess.cpp b/Source/WebKit/Shared/AuxiliaryProcess.cpp +index f5a986d..3b4eeb0 100644 +--- a/Source/WebKit/Shared/AuxiliaryProcess.cpp ++++ b/Source/WebKit/Shared/AuxiliaryProcess.cpp +@@ -187,10 +187,18 @@ void AuxiliaryProcess::stopRunLoop() + platformStopRunLoop(); + } + +-#if !PLATFORM(COCOA) ++#if !PLATFORM(COCOA) && !OS(HAIKU) ++void AuxiliaryProcess::platformStopRunLoop() ++{ ++ RunLoop::main().stop(); ++} ++#endif ++ ++#if OS(HAIKU) + void AuxiliaryProcess::platformStopRunLoop() + { + RunLoop::main().stop(); ++ _exit(EXIT_SUCCESS); + } + #endif + +diff --git a/Source/WebKit/UIProcess/API/glib/WebKitProtocolHandler.cpp b/Source/WebKit/UIProcess/API/glib/WebKitProtocolHandler.cpp +index 6d93a6d..8182dc4 100644 +--- a/Source/WebKit/UIProcess/API/glib/WebKitProtocolHandler.cpp ++++ b/Source/WebKit/UIProcess/API/glib/WebKitProtocolHandler.cpp +@@ -122,6 +122,8 @@ static const char* hardwareAccelerationPolicy(WebKitURISchemeRequest* request) + { + #if PLATFORM(WPE) + return "always"; ++#elif defined(__HAIKU__) ++ return "never"; + #elif PLATFORM(GTK) + auto* webView = webkit_uri_scheme_request_get_web_view(request); + ASSERT(webView); +@@ -151,6 +153,8 @@ static const char* openGLAPI(bool isEGL) + if (epoxy_is_desktop_gl()) + return "OpenGL (libepoxy)"; + return "OpenGL ES 2 (libepoxy)"; ++#elif defined(__HAIKU__) ++ return "OpenGL"; + #else + #if USE(EGL) + if (isEGL) { +diff --git a/Source/WebKit/WebProcess/WebCoreSupport/WebWorkerClient.cpp b/Source/WebKit/WebProcess/WebCoreSupport/WebWorkerClient.cpp +index 990e361..edf5296 100644 +--- a/Source/WebKit/WebProcess/WebCoreSupport/WebWorkerClient.cpp ++++ b/Source/WebKit/WebProcess/WebCoreSupport/WebWorkerClient.cpp +@@ -38,6 +38,8 @@ + #include + #endif + ++#include ++ + namespace WebKit { + using namespace WebCore; + +diff --git a/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/DrawingAreaCoordinatedGraphics.cpp b/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/DrawingAreaCoordinatedGraphics.cpp +index b672817..5b7ddb7 100644 +--- a/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/DrawingAreaCoordinatedGraphics.cpp ++++ b/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/DrawingAreaCoordinatedGraphics.cpp +@@ -487,7 +487,7 @@ void DrawingAreaCoordinatedGraphics::displayDidRefresh() + displayTimerFired(); + } + +-#if PLATFORM(GTK) ++#if PLATFORM(GTK) && !OS(HAIKU) + void DrawingAreaCoordinatedGraphics::adjustTransientZoom(double scale, FloatPoint origin) + { + if (!m_transientZoom) { +@@ -620,7 +620,7 @@ void DrawingAreaCoordinatedGraphics::resumePainting() + + void DrawingAreaCoordinatedGraphics::enterAcceleratedCompositingMode(GraphicsLayer* graphicsLayer) + { +-#if PLATFORM(GTK) ++#if PLATFORM(GTK) && !OS(HAIKU) + if (!m_alwaysUseCompositing) { + m_webPage.corePage()->settings().setForceCompositingMode(true); + m_alwaysUseCompositing = true; +diff --git a/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/DrawingAreaCoordinatedGraphics.h b/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/DrawingAreaCoordinatedGraphics.h +index 514d648..aee9d2b 100644 +--- a/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/DrawingAreaCoordinatedGraphics.h ++++ b/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/DrawingAreaCoordinatedGraphics.h +@@ -85,7 +85,7 @@ private: + void targetRefreshRateDidChange(unsigned rate) override; + void displayDidRefresh() override; + +-#if PLATFORM(GTK) ++#if PLATFORM(GTK) && !OS(HAIKU) + void adjustTransientZoom(double scale, WebCore::FloatPoint origin) override; + void commitTransientZoom(double scale, WebCore::FloatPoint origin) override; + #endif +@@ -157,7 +157,7 @@ private: + + RunLoop::Timer m_displayTimer; + +-#if PLATFORM(GTK) ++#if PLATFORM(GTK) && !OS(HAIKU) + bool m_transientZoom { false }; + WebCore::FloatPoint m_transientZoomInitialOrigin; + #endif +diff --git a/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/LayerTreeHost.cpp b/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/LayerTreeHost.cpp +index 6a21081..65ab6c3 100644 +--- a/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/LayerTreeHost.cpp ++++ b/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/LayerTreeHost.cpp +@@ -148,7 +148,7 @@ void LayerTreeHost::layerFlushTimerFired() + m_coordinator.forceFrameSync(); + + OptionSet flags; +-#if PLATFORM(GTK) ++#if PLATFORM(GTK) && !OS(HAIKU) + if (!m_transientZoom) + flags.add(FinalizeRenderingUpdateFlags::ApplyScrollingTreeLayerPositions); + #else +@@ -157,7 +157,7 @@ void LayerTreeHost::layerFlushTimerFired() + + bool didSync = m_coordinator.flushPendingLayerChanges(flags); + +-#if PLATFORM(GTK) ++#if PLATFORM(GTK) && !OS(HAIKU) + // If we have an active transient zoom, we want the zoom to win over any changes + // that WebCore makes to the relevant layers, so re-apply our changes after flushing. + if (m_transientZoom) +@@ -205,7 +205,7 @@ void LayerTreeHost::forceRepaint() + + if (!m_isWaitingForRenderer) { + OptionSet flags; +-#if PLATFORM(GTK) ++#if PLATFORM(GTK) && !OS(HAIKU) + if (!m_transientZoom) + flags.add(FinalizeRenderingUpdateFlags::ApplyScrollingTreeLayerPositions); + #else +@@ -476,7 +476,7 @@ void LayerTreeHost::renderNextFrame(bool forceRepaint) + } + } + +-#if PLATFORM(GTK) ++#if PLATFORM(GTK) && !OS(HAIKU) + FloatPoint LayerTreeHost::constrainTransientZoomOrigin(double scale, FloatPoint origin) const + { + FrameView& frameView = *m_webPage.mainFrameView(); +diff --git a/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/LayerTreeHost.h b/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/LayerTreeHost.h +index 9af7685..adaa9f2 100644 +--- a/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/LayerTreeHost.h ++++ b/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/LayerTreeHost.h +@@ -98,7 +98,7 @@ public: + + WebCore::PlatformDisplayID displayID() const { return m_displayID; } + +-#if PLATFORM(GTK) ++#if PLATFORM(GTK) && !OS(HAIKU) + void adjustTransientZoom(double, WebCore::FloatPoint); + void commitTransientZoom(double, WebCore::FloatPoint); + #endif +@@ -129,7 +129,7 @@ private: + void requestDisplayRefreshMonitorUpdate() override; + void handleDisplayRefreshMonitorUpdate(bool hasBeenRescheduled) override; + +-#if PLATFORM(GTK) ++#if PLATFORM(GTK) && !OS(HAIKU) + WebCore::FloatPoint constrainTransientZoomOrigin(double, WebCore::FloatPoint) const; + WebCore::CoordinatedGraphicsLayer* layerForTransientZoom() const; + void applyTransientZoomToLayers(double, WebCore::FloatPoint); +@@ -167,7 +167,7 @@ private: + #endif // USE(COORDINATED_GRAPHICS) + WebCore::PlatformDisplayID m_displayID; + +-#if PLATFORM(GTK) ++#if PLATFORM(GTK) && !OS(HAIKU) + bool m_transientZoom { false }; + double m_transientZoomScale { 1 }; + WebCore::FloatPoint m_transientZoomOrigin; +@@ -196,7 +196,7 @@ inline void LayerTreeHost::didChangeViewportAttributes(WebCore::ViewportAttribut + inline void LayerTreeHost::setIsDiscardable(bool) { } + inline void LayerTreeHost::deviceOrPageScaleFactorChanged() { } + inline RefPtr LayerTreeHost::createDisplayRefreshMonitor(WebCore::PlatformDisplayID) { return nullptr; } +-#if PLATFORM(GTK) ++#if PLATFORM(GTK) && !OS(HAIKU) + inline void LayerTreeHost::adjustTransientZoom(double, WebCore::FloatPoint) { } + inline void LayerTreeHost::commitTransientZoom(double, WebCore::FloatPoint) { } + #endif +diff --git a/Source/WebKit/WebProcess/WebProcess.cpp b/Source/WebKit/WebProcess/WebProcess.cpp +index da2955b..56aa728 100644 +--- a/Source/WebKit/WebProcess/WebProcess.cpp ++++ b/Source/WebKit/WebProcess/WebProcess.cpp +@@ -379,7 +379,7 @@ void WebProcess::initializeConnection(IPC::Connection* connection) + connection->setDidCloseOnConnectionWorkQueueCallback(callExit); + #endif + +-#if !PLATFORM(GTK) && !PLATFORM(WPE) && !ENABLE(IPC_TESTING_API) ++#if (!PLATFORM(GTK) && !PLATFORM(WPE) && !ENABLE(IPC_TESTING_API)) || OS(HAIKU) + connection->setShouldExitOnSyncMessageSendFailure(true); + #endif + +diff --git a/Source/cmake/WebKitCommon.cmake b/Source/cmake/WebKitCommon.cmake +index d9f32f0..44556f7 100644 +--- a/Source/cmake/WebKitCommon.cmake ++++ b/Source/cmake/WebKitCommon.cmake +@@ -159,7 +159,9 @@ if (NOT HAS_RUN_WEBKIT_COMMON) + set(WebKit_LIBRARY_TYPE SHARED) + set(WebCoreTestSupport_LIBRARY_TYPE STATIC) + +- set(CMAKE_POSITION_INDEPENDENT_CODE True) ++ if (NOT HAIKU) ++ set(CMAKE_POSITION_INDEPENDENT_CODE True) ++ endif () + + # ----------------------------------------------------------------------------- + # Install JavaScript shell +-- +2.37.3 + + +From f707ed70f009622f84693c974618ce1a6e3884a2 Mon Sep 17 00:00:00 2001 +From: Gerasim Troeglazov <3dEyes@gmail.com> +Date: Sat, 17 Dec 2022 23:37:24 +1000 +Subject: WTF: fix build, implement platform code + + +diff --git a/Source/WTF/wtf/CheckedArithmetic.h b/Source/WTF/wtf/CheckedArithmetic.h +index c9d31d5..25b90a3 100644 +--- a/Source/WTF/wtf/CheckedArithmetic.h ++++ b/Source/WTF/wtf/CheckedArithmetic.h +@@ -34,7 +34,7 @@ + /* On Linux with clang, libgcc is usually used instead of compiler-rt, and it does + * not provide the __mulodi4 symbol used by clang for __builtin_mul_overflow + */ +-#if COMPILER(GCC) || (COMPILER(CLANG) && !(CPU(ARM) && OS(LINUX))) && !PLATFORM(IOS_FAMILY_SIMULATOR) ++#if COMPILER(GCC) || (COMPILER(CLANG) && !(CPU(ARM) && OS(LINUX)) && !OS(HAIKU)) && !PLATFORM(IOS_FAMILY_SIMULATOR) + #define USE_MUL_OVERFLOW 1 + #endif + +diff --git a/Source/WTF/wtf/CurrentTime.cpp b/Source/WTF/wtf/CurrentTime.cpp +index c042a0f..2d253f5 100644 +--- a/Source/WTF/wtf/CurrentTime.cpp ++++ b/Source/WTF/wtf/CurrentTime.cpp +@@ -271,7 +271,7 @@ MonotonicTime MonotonicTime::now() + return fromMachAbsoluteTime(mach_absolute_time()); + #elif OS(FUCHSIA) + return fromRawSeconds(zx_clock_get_monotonic() / static_cast(ZX_SEC(1))); +-#elif OS(LINUX) || OS(FREEBSD) || OS(OPENBSD) || OS(NETBSD) ++#elif OS(LINUX) || OS(FREEBSD) || OS(OPENBSD) || OS(NETBSD) || OS(HAIKU) + struct timespec ts { }; + clock_gettime(CLOCK_MONOTONIC, &ts); + return fromRawSeconds(static_cast(ts.tv_sec) + ts.tv_nsec / 1.0e9); +diff --git a/Source/WTF/wtf/FastMalloc.cpp b/Source/WTF/wtf/FastMalloc.cpp +index 48b0c31..6ed66c8 100644 +--- a/Source/WTF/wtf/FastMalloc.cpp ++++ b/Source/WTF/wtf/FastMalloc.cpp +@@ -58,8 +58,8 @@ + namespace WTF { + + #if ASSERT_ENABLED +-thread_local static unsigned forbidMallocUseScopeCount; +-thread_local static unsigned disableMallocRestrictionScopeCount; ++__thread unsigned forbidMallocUseScopeCount; ++__thread unsigned disableMallocRestrictionScopeCount; + + ForbidMallocUseForCurrentThreadScope::ForbidMallocUseForCurrentThreadScope() + { diff --git a/Source/WTF/wtf/FileSystem.cpp b/Source/WTF/wtf/FileSystem.cpp -index 90dbf5a..a1eaf5b 100644 +index 82fdfa0..a18f98d 100644 --- a/Source/WTF/wtf/FileSystem.cpp +++ b/Source/WTF/wtf/FileSystem.cpp -@@ -40,6 +40,10 @@ +@@ -41,6 +41,10 @@ #include #endif @@ -76,7 +491,7 @@ index 90dbf5a..a1eaf5b 100644 #if USE(GLIB) #include #include -@@ -665,9 +669,13 @@ bool createSymbolicLink(const String& targetPath, const String& symbolicLinkPath +@@ -711,9 +715,13 @@ bool createSymbolicLink(const String& targetPath, const String& symbolicLinkPath bool hardLink(const String& targetPath, const String& linkPath) { @@ -91,9 +506,18 @@ index 90dbf5a..a1eaf5b 100644 bool hardLinkOrCopyFile(const String& targetPath, const String& linkPath) diff --git a/Source/WTF/wtf/InlineASM.h b/Source/WTF/wtf/InlineASM.h -index 8379a69..aba12e0 100644 +index 8379a69..04f2529 100644 --- a/Source/WTF/wtf/InlineASM.h +++ b/Source/WTF/wtf/InlineASM.h +@@ -43,7 +43,7 @@ + #define THUMB_FUNC_PARAM(name) + #endif + +-#if (OS(LINUX) || OS(FREEBSD)) && CPU(X86_64) ++#if (OS(LINUX) || OS(FREEBSD) || OS(HAIKU)) && CPU(X86_64) + #define GLOBAL_REFERENCE(name) #name "@plt" + #elif CPU(X86) && COMPILER(MINGW) + #define GLOBAL_REFERENCE(name) "@" #name "@4" @@ -69,6 +69,7 @@ || OS(FREEBSD) \ || OS(FUCHSIA) \ @@ -110,11 +534,61 @@ index 8379a69..aba12e0 100644 || OS(NETBSD) \ || COMPILER(MINGW) // GNU as-compatible syntax. +diff --git a/Source/WTF/wtf/NumberOfCores.cpp b/Source/WTF/wtf/NumberOfCores.cpp +index 7636865..dd2128e 100644 +--- a/Source/WTF/wtf/NumberOfCores.cpp ++++ b/Source/WTF/wtf/NumberOfCores.cpp +@@ -30,6 +30,8 @@ + + #if OS(DARWIN) + #include ++#elif OS(HAIKU) ++#include + #elif OS(LINUX) || OS(AIX) || OS(OPENBSD) || OS(NETBSD) || OS(FREEBSD) + #include + #elif OS(WINDOWS) +@@ -65,6 +67,10 @@ int numberOfProcessorCores() + int sysctlResult = sysctl(name, sizeof(name) / sizeof(int), &result, &length, 0, 0); + + s_numberOfCores = sysctlResult < 0 ? defaultIfUnavailable : result; ++#elif OS(HAIKU) ++ system_info info; ++ status_t result = get_system_info(&info); ++ s_numberOfCores = result == B_OK ? info.cpu_count : defaultIfUnavailable; + #elif OS(LINUX) || OS(AIX) || OS(OPENBSD) || OS(NETBSD) || OS(FREEBSD) + long sysconfResult = sysconf(_SC_NPROCESSORS_ONLN); + +diff --git a/Source/WTF/wtf/Packed.h b/Source/WTF/wtf/Packed.h +index 0d94f89..9921cb6 100644 +--- a/Source/WTF/wtf/Packed.h ++++ b/Source/WTF/wtf/Packed.h +@@ -151,7 +151,7 @@ public: + if (isAlignmentShiftProfitable) + value <<= alignmentShiftSize; + +-#if CPU(X86_64) && !(OS(DARWIN) || OS(LINUX) || OS(WINDOWS)) ++#if CPU(X86_64) && !(OS(DARWIN) || OS(LINUX) || OS(HAIKU) || OS(WINDOWS)) + // The AMD specification requires that the most significant 16 + // bits of any virtual address, bits 48 through 63, must be + // copies of bit 47 (in a manner akin to sign extension). +diff --git a/Source/WTF/wtf/PlatformEnable.h b/Source/WTF/wtf/PlatformEnable.h +index daad91d..ef2000c 100644 +--- a/Source/WTF/wtf/PlatformEnable.h ++++ b/Source/WTF/wtf/PlatformEnable.h +@@ -657,7 +657,7 @@ + #if !defined(ENABLE_DFG_JIT) && ENABLE(JIT) + + /* Enable the DFG JIT on X86 and X86_64. */ +-#if CPU(X86_64) && (OS(DARWIN) || OS(LINUX) || OS(FREEBSD) || OS(HURD) || OS(WINDOWS)) ++#if CPU(X86_64) && (OS(DARWIN) || OS(LINUX) || OS(HAIKU) || OS(FREEBSD) || OS(HURD) || OS(WINDOWS)) + #define ENABLE_DFG_JIT 1 + #endif + diff --git a/Source/WTF/wtf/PlatformHave.h b/Source/WTF/wtf/PlatformHave.h -index 7893367..def1eb3 100644 +index c65e25b..0023d69 100644 --- a/Source/WTF/wtf/PlatformHave.h +++ b/Source/WTF/wtf/PlatformHave.h -@@ -389,7 +389,7 @@ +@@ -385,7 +385,7 @@ #define HAVE_STACK_BOUNDS_FOR_NEW_THREAD 1 #endif @@ -160,6 +634,30 @@ index b981c13..76cfd55 100644 #elif OS(OPENBSD) typedef ucontext_t mcontext_t; #else +diff --git a/Source/WTF/wtf/RAMSize.cpp b/Source/WTF/wtf/RAMSize.cpp +index 164de5e..c1d5524 100644 +--- a/Source/WTF/wtf/RAMSize.cpp ++++ b/Source/WTF/wtf/RAMSize.cpp +@@ -33,6 +33,8 @@ + #elif USE(SYSTEM_MALLOC) + #if OS(LINUX) || OS(FREEBSD) + #include ++#elif OS(HAIKU) ++#include + #elif OS(UNIX) + #include + #endif // OS(LINUX) || OS(FREEBSD) || OS(UNIX) +@@ -60,6 +62,10 @@ static size_t computeRAMSize() + struct sysinfo si; + sysinfo(&si); + return si.totalram * si.mem_unit; ++#elif OS(HAIKU) ++ system_info info; ++ get_system_info(&info); ++ return info.max_pages * B_PAGE_SIZE; + #elif OS(UNIX) + long pages = sysconf(_SC_PHYS_PAGES); + long pageSize = sysconf(_SC_PAGE_SIZE); diff --git a/Source/WTF/wtf/StackBounds.cpp b/Source/WTF/wtf/StackBounds.cpp index e9d9d58..bc4d1c7 100644 --- a/Source/WTF/wtf/StackBounds.cpp @@ -186,296 +684,8 @@ index e9d9d58..bc4d1c7 100644 // e.g. on FreeBSD 5.4, neundorf@kde.org pthread_attr_get_np(thread, &sattr); #else -diff --git a/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp b/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp -index 54d6b1c..761ebca 100644 ---- a/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp -+++ b/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp -@@ -2219,6 +2219,8 @@ void MediaPlayerPrivateGStreamer::configureDownloadBuffer(GstElement* element) - GUniquePtr defaultValue(g_build_filename(G_DIR_SEPARATOR_S, "var", "tmp", nullptr)); - mediaDiskCachePath.swap(defaultValue); - } -+#elif defined(__HAIKU__) -+ GUniquePtr mediaDiskCachePath(g_build_filename(G_DIR_SEPARATOR_S, "system", "cache", "tmp", nullptr)); - #else - GUniquePtr mediaDiskCachePath(g_build_filename(G_DIR_SEPARATOR_S, "var", "tmp", nullptr)); - #endif -diff --git a/Source/WebKit/CMakeLists.txt b/Source/WebKit/CMakeLists.txt -index ebd7542..f05c803 100644 ---- a/Source/WebKit/CMakeLists.txt -+++ b/Source/WebKit/CMakeLists.txt -@@ -404,6 +404,10 @@ if (UNIX) - endif () - endif () - -+if (HAIKU) -+ list(APPEND WebKit_PRIVATE_LIBRARIES network) -+endif () -+ - macro(ADD_WEBKIT_PREFIX_HEADER _target) - if (WebKit_USE_PREFIX_HEADER) - get_target_property(OLD_COMPILE_FLAGS ${_target} COMPILE_FLAGS) -diff --git a/Source/WebKit/Platform/IPC/unix/ConnectionUnix.cpp b/Source/WebKit/Platform/IPC/unix/ConnectionUnix.cpp -index 42185f2..7188a6b 100644 ---- a/Source/WebKit/Platform/IPC/unix/ConnectionUnix.cpp -+++ b/Source/WebKit/Platform/IPC/unix/ConnectionUnix.cpp -@@ -270,7 +270,7 @@ bool Connection::processMessage() - return true; - } - --static ssize_t readBytesFromSocket(int socketDescriptor, Vector& buffer, Vector& fileDescriptors) -+static ssize_t readBytesFromSocket(int socketDescriptor, Vector& buffer, Vector& fileDescriptors, size_t size) - { - struct msghdr message; - memset(&message, 0, sizeof(message)); -@@ -286,7 +286,7 @@ static ssize_t readBytesFromSocket(int socketDescriptor, Vector& buffer - size_t previousBufferSize = buffer.size(); - buffer.grow(buffer.capacity()); - iov[0].iov_base = buffer.data() + previousBufferSize; -- iov[0].iov_len = buffer.size() - previousBufferSize; -+ iov[0].iov_len = size; - - message.msg_iov = iov; - message.msg_iovlen = 1; -@@ -337,6 +337,20 @@ static ssize_t readBytesFromSocket(int socketDescriptor, Vector& buffer - return -1; - } - -+static ssize_t readBytesFromSocket(int socketDescriptor, Vector& buffer, Vector& fileDescriptors) -+{ -+ ssize_t bytesRead = readBytesFromSocket(socketDescriptor, buffer, fileDescriptors, sizeof(MessageInfo)); -+ if (bytesRead <= 0) return bytesRead; -+ uint8_t* messageData = buffer.data(); -+ MessageInfo messageInfo; -+ memcpy(static_cast(&messageInfo), messageData, sizeof(messageInfo)); -+ messageData += sizeof(messageInfo); -+ size_t messageLength = messageInfo.attachmentCount() * sizeof(AttachmentInfo) + (messageInfo.isBodyOutOfLine() ? 0 : messageInfo.bodySize()); -+ if (messageLength == 0) return bytesRead; -+ bytesRead = readBytesFromSocket(socketDescriptor, buffer, fileDescriptors, messageLength); -+ return bytesRead; -+} -+ - void Connection::readyReadHandler() - { - while (true) { -@@ -609,7 +623,11 @@ bool Connection::sendOutputMessage(UnixMessage& outputMessage) - Connection::SocketPair Connection::createPlatformConnection(unsigned options) - { - int sockets[2]; -+#ifdef __HAIKU__ -+ RELEASE_ASSERT(socketpair(AF_LOCAL, SOCK_STREAM, 0, sockets) != -1); -+#else - RELEASE_ASSERT(socketpair(AF_UNIX, SOCKET_TYPE, 0, sockets) != -1); -+#endif - - if (options & SetCloexecOnServer) { - // Don't expose the child socket to the parent process. -diff --git a/Source/WebKit/UIProcess/API/glib/WebKitProtocolHandler.cpp b/Source/WebKit/UIProcess/API/glib/WebKitProtocolHandler.cpp -index f4318de..71ff0d8 100644 ---- a/Source/WebKit/UIProcess/API/glib/WebKitProtocolHandler.cpp -+++ b/Source/WebKit/UIProcess/API/glib/WebKitProtocolHandler.cpp -@@ -118,6 +118,8 @@ static const char* hardwareAccelerationPolicy(WebKitURISchemeRequest* request) - { - #if PLATFORM(WPE) - return "always"; -+#elif defined(__HAIKU__) -+ return "never"; - #elif PLATFORM(GTK) - auto* webView = webkit_uri_scheme_request_get_web_view(request); - ASSERT(webView); -@@ -147,6 +149,8 @@ static const char* openGLAPI() - if (epoxy_is_desktop_gl()) - return "OpenGL (libepoxy)"; - return "OpenGL ES 2 (libepoxy)"; -+#elif defined(__HAIKU__) -+ return "OpenGL"; - #else - #if USE(GLX) - if (PlatformDisplay::sharedDisplay().type() == PlatformDisplay::Type::X11) -diff --git a/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/DrawingAreaCoordinatedGraphics.cpp b/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/DrawingAreaCoordinatedGraphics.cpp -index 6bc7442..16f4326 100644 ---- a/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/DrawingAreaCoordinatedGraphics.cpp -+++ b/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/DrawingAreaCoordinatedGraphics.cpp -@@ -487,7 +487,7 @@ void DrawingAreaCoordinatedGraphics::didUpdate() - displayTimerFired(); - } - --#if PLATFORM(GTK) -+#if PLATFORM(GTK) && !OS(HAIKU) - void DrawingAreaCoordinatedGraphics::adjustTransientZoom(double scale, FloatPoint origin) - { - if (!m_transientZoom) { -@@ -620,7 +620,7 @@ void DrawingAreaCoordinatedGraphics::resumePainting() - - void DrawingAreaCoordinatedGraphics::enterAcceleratedCompositingMode(GraphicsLayer* graphicsLayer) - { --#if PLATFORM(GTK) -+#if PLATFORM(GTK) && !OS(HAIKU) - if (!m_alwaysUseCompositing) { - m_webPage.corePage()->settings().setForceCompositingMode(true); - m_alwaysUseCompositing = true; -diff --git a/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/DrawingAreaCoordinatedGraphics.h b/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/DrawingAreaCoordinatedGraphics.h -index dbef365..bf5f205 100644 ---- a/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/DrawingAreaCoordinatedGraphics.h -+++ b/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/DrawingAreaCoordinatedGraphics.h -@@ -85,7 +85,7 @@ private: - void targetRefreshRateDidChange(unsigned rate) override; - void didUpdate() override; - --#if PLATFORM(GTK) -+#if PLATFORM(GTK) && !OS(HAIKU) - void adjustTransientZoom(double scale, WebCore::FloatPoint origin) override; - void commitTransientZoom(double scale, WebCore::FloatPoint origin) override; - #endif -@@ -157,7 +157,7 @@ private: - - RunLoop::Timer m_displayTimer; - --#if PLATFORM(GTK) -+#if PLATFORM(GTK) && !OS(HAIKU) - bool m_transientZoom { false }; - WebCore::FloatPoint m_transientZoomInitialOrigin; - #endif -diff --git a/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/LayerTreeHost.cpp b/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/LayerTreeHost.cpp -index 60d596e..20d3026 100644 ---- a/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/LayerTreeHost.cpp -+++ b/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/LayerTreeHost.cpp -@@ -147,7 +147,7 @@ void LayerTreeHost::layerFlushTimerFired() - m_coordinator.forceFrameSync(); - - OptionSet flags; --#if PLATFORM(GTK) -+#if PLATFORM(GTK) && !OS(HAIKU) - if (!m_transientZoom) - flags.add(FinalizeRenderingUpdateFlags::ApplyScrollingTreeLayerPositions); - #else -@@ -156,7 +156,7 @@ void LayerTreeHost::layerFlushTimerFired() - - bool didSync = m_coordinator.flushPendingLayerChanges(flags); - --#if PLATFORM(GTK) -+#if PLATFORM(GTK) && !OS(HAIKU) - // If we have an active transient zoom, we want the zoom to win over any changes - // that WebCore makes to the relevant layers, so re-apply our changes after flushing. - if (m_transientZoom) -@@ -204,7 +204,7 @@ void LayerTreeHost::forceRepaint() - - if (!m_isWaitingForRenderer) { - OptionSet flags; --#if PLATFORM(GTK) -+#if PLATFORM(GTK) && !OS(HAIKU) - if (!m_transientZoom) - flags.add(FinalizeRenderingUpdateFlags::ApplyScrollingTreeLayerPositions); - #else -@@ -458,7 +458,7 @@ void LayerTreeHost::renderNextFrame(bool forceRepaint) - } - } - --#if PLATFORM(GTK) -+#if PLATFORM(GTK) && !OS(HAIKU) - FloatPoint LayerTreeHost::constrainTransientZoomOrigin(double scale, FloatPoint origin) const - { - FrameView& frameView = *m_webPage.mainFrameView(); -diff --git a/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/LayerTreeHost.h b/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/LayerTreeHost.h -index 1dfae4a..69f1889 100644 ---- a/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/LayerTreeHost.h -+++ b/Source/WebKit/WebProcess/WebPage/CoordinatedGraphics/LayerTreeHost.h -@@ -99,7 +99,7 @@ public: - - WebCore::PlatformDisplayID displayID() const { return m_displayID; } - --#if PLATFORM(GTK) -+#if PLATFORM(GTK) && !OS(HAIKU) - void adjustTransientZoom(double, WebCore::FloatPoint); - void commitTransientZoom(double, WebCore::FloatPoint); - #endif -@@ -125,7 +125,7 @@ private: - void requestDisplayRefreshMonitorUpdate(); - void handleDisplayRefreshMonitorUpdate(bool); - --#if PLATFORM(GTK) -+#if PLATFORM(GTK) && !OS(HAIKU) - WebCore::FloatPoint constrainTransientZoomOrigin(double, WebCore::FloatPoint) const; - WebCore::CoordinatedGraphicsLayer* layerForTransientZoom() const; - void applyTransientZoomToLayers(double, WebCore::FloatPoint); -@@ -212,7 +212,7 @@ private: - #endif // USE(COORDINATED_GRAPHICS) - WebCore::PlatformDisplayID m_displayID; - --#if PLATFORM(GTK) -+#if PLATFORM(GTK) && !OS(HAIKU) - bool m_transientZoom { false }; - double m_transientZoomScale { 1 }; - WebCore::FloatPoint m_transientZoomOrigin; -@@ -241,7 +241,7 @@ inline void LayerTreeHost::didChangeViewportAttributes(WebCore::ViewportAttribut - inline void LayerTreeHost::setIsDiscardable(bool) { } - inline void LayerTreeHost::deviceOrPageScaleFactorChanged() { } - inline RefPtr LayerTreeHost::createDisplayRefreshMonitor(WebCore::PlatformDisplayID) { return nullptr; } --#if PLATFORM(GTK) -+#if PLATFORM(GTK) && !OS(HAIKU) - inline void LayerTreeHost::adjustTransientZoom(double, WebCore::FloatPoint) { } - inline void LayerTreeHost::commitTransientZoom(double, WebCore::FloatPoint) { } - #endif -diff --git a/Source/cmake/WebKitCommon.cmake b/Source/cmake/WebKitCommon.cmake -index cd78c8c..87cb5a5 100644 ---- a/Source/cmake/WebKitCommon.cmake -+++ b/Source/cmake/WebKitCommon.cmake -@@ -159,7 +159,9 @@ if (NOT HAS_RUN_WEBKIT_COMMON) - set(WebKit_LIBRARY_TYPE SHARED) - set(WebCoreTestSupport_LIBRARY_TYPE STATIC) - -- set(CMAKE_POSITION_INDEPENDENT_CODE True) -+ if (NOT HAIKU) -+ set(CMAKE_POSITION_INDEPENDENT_CODE True) -+ endif () - - # ----------------------------------------------------------------------------- - # Install JavaScript shell --- -2.37.3 - - -From 995a6b23021382a48aed8806d5e1f04981f2ed71 Mon Sep 17 00:00:00 2001 -From: Gerasim Troeglazov <3dEyes@gmail.com> -Date: Fri, 11 Nov 2022 16:48:40 +1000 -Subject: Thread naming - - -diff --git a/Source/WTF/wtf/posix/ThreadingPOSIX.cpp b/Source/WTF/wtf/posix/ThreadingPOSIX.cpp -index e5f4761..a485dfa 100644 ---- a/Source/WTF/wtf/posix/ThreadingPOSIX.cpp -+++ b/Source/WTF/wtf/posix/ThreadingPOSIX.cpp -@@ -42,6 +42,10 @@ - #include - #include - -+#if OS(HAIKU) -+#include -+#endif -+ - #if OS(LINUX) - #include - #include -@@ -318,6 +322,8 @@ void Thread::initializeCurrentThreadInternal(const char* threadName) - { - #if HAVE(PTHREAD_SETNAME_NP) - pthread_setname_np(normalizeThreadName(threadName)); -+#elif OS(HAIKU) -+ rename_thread(find_thread(NULL), normalizeThreadName(threadName)); - #elif OS(LINUX) - prctl(PR_SET_NAME, normalizeThreadName(threadName)); - #else --- -2.37.3 - - -From 234fc18bfccd6893ae764506f16b30620e180f95 Mon Sep 17 00:00:00 2001 -From: Gerasim Troeglazov <3dEyes@gmail.com> -Date: Fri, 11 Nov 2022 16:49:03 +1000 -Subject: Fix memory reserve - - diff --git a/Source/WTF/wtf/posix/OSAllocatorPOSIX.cpp b/Source/WTF/wtf/posix/OSAllocatorPOSIX.cpp -index 7510126..0be4d44 100644 +index 396de82..97159c3 100644 --- a/Source/WTF/wtf/posix/OSAllocatorPOSIX.cpp +++ b/Source/WTF/wtf/posix/OSAllocatorPOSIX.cpp @@ -115,7 +115,7 @@ void* OSAllocator::tryReserveAndCommit(size_t bytes, Usage usage, bool writable, @@ -505,18 +715,42 @@ index 7510126..0be4d44 100644 while (madvise(address, bytes, MADV_DONTNEED) == -1 && errno == EAGAIN) { } #elif HAVE(MADV_FREE_REUSE) while (madvise(address, bytes, MADV_FREE_REUSABLE) == -1 && errno == EAGAIN) { } +diff --git a/Source/WTF/wtf/posix/ThreadingPOSIX.cpp b/Source/WTF/wtf/posix/ThreadingPOSIX.cpp +index e5cac15..5dabd58 100644 +--- a/Source/WTF/wtf/posix/ThreadingPOSIX.cpp ++++ b/Source/WTF/wtf/posix/ThreadingPOSIX.cpp +@@ -42,6 +42,10 @@ + #include + #include + ++#if OS(HAIKU) ++#include ++#endif ++ + #if OS(LINUX) + #include + #include +@@ -318,6 +322,8 @@ void Thread::initializeCurrentThreadInternal(const char* threadName) + { + #if HAVE(PTHREAD_SETNAME_NP) + pthread_setname_np(normalizeThreadName(threadName)); ++#elif OS(HAIKU) ++ rename_thread(find_thread(NULL), normalizeThreadName(threadName)); + #elif OS(LINUX) + prctl(PR_SET_NAME, normalizeThreadName(threadName)); + #else -- 2.37.3 -From 4824e201ddd43510c912b8e05ce58ebf839ec552 Mon Sep 17 00:00:00 2001 -From: "Samuel D. Crow" -Date: Tue, 22 Nov 2022 00:16:57 -0600 +From 01d9b43588be4ed5ae6bc45696537655ee361f05 Mon Sep 17 00:00:00 2001 +From: Gerasim Troeglazov <3dEyes@gmail.com> +Date: Sat, 17 Dec 2022 23:37:49 +1000 Subject: fix endian check diff --git a/Source/ThirdParty/xdgmime/CMakeLists.txt b/Source/ThirdParty/xdgmime/CMakeLists.txt -index 2605e1c..c01a1a0 100644 +index 2605e1c..afaa684 100644 --- a/Source/ThirdParty/xdgmime/CMakeLists.txt +++ b/Source/ThirdParty/xdgmime/CMakeLists.txt @@ -16,8 +16,10 @@ set(XDGMIME_SOURCES @@ -535,203 +769,10 @@ index 2605e1c..c01a1a0 100644 2.37.3 -From 15195b11b69b080ec88ffe2c0fae4f540920a41e Mon Sep 17 00:00:00 2001 +From 66fe015f6dd67c093db8da41dd5e260c43c84be1 Mon Sep 17 00:00:00 2001 From: Gerasim Troeglazov <3dEyes@gmail.com> -Date: Fri, 25 Nov 2022 17:49:09 +1000 -Subject: Use __thread instead thread_local - - -diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/Context.cpp b/Source/ThirdParty/ANGLE/src/libANGLE/Context.cpp -index 9fa9991..c1f6528 100644 ---- a/Source/ThirdParty/ANGLE/src/libANGLE/Context.cpp -+++ b/Source/ThirdParty/ANGLE/src/libANGLE/Context.cpp -@@ -424,7 +424,7 @@ void SetCurrentValidContextTLS(Context *context) - SetTLSValue(CurrentValidContextIndex, context); - } - #else --thread_local Context *gCurrentValidContext = nullptr; -+__thread Context *gCurrentValidContext = nullptr; - #endif - - Context::Context(egl::Display *display, -diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/Context.h b/Source/ThirdParty/ANGLE/src/libANGLE/Context.h -index 34a1fda..8d8b8a4 100644 ---- a/Source/ThirdParty/ANGLE/src/libANGLE/Context.h -+++ b/Source/ThirdParty/ANGLE/src/libANGLE/Context.h -@@ -859,7 +859,7 @@ class [[nodiscard]] ScopedContextRef - extern Context *GetCurrentValidContextTLS(); - extern void SetCurrentValidContextTLS(Context *context); - #else --extern thread_local Context *gCurrentValidContext; -+extern __thread Context *gCurrentValidContext; - #endif - - } // namespace gl -diff --git a/Source/ThirdParty/ANGLE/src/libGLESv2/global_state.cpp b/Source/ThirdParty/ANGLE/src/libGLESv2/global_state.cpp -index 18265d2..8b6f174 100644 ---- a/Source/ThirdParty/ANGLE/src/libGLESv2/global_state.cpp -+++ b/Source/ThirdParty/ANGLE/src/libGLESv2/global_state.cpp -@@ -141,7 +141,7 @@ void SetCurrentThreadTLS(Thread *thread) - SetTLSValue(CurrentThreadIndex, thread); - } - #else --thread_local Thread *gCurrentThread = nullptr; -+__thread Thread *gCurrentThread = nullptr; - #endif - - angle::GlobalMutex &GetGlobalMutex() -diff --git a/Source/ThirdParty/ANGLE/src/libGLESv2/global_state.h b/Source/ThirdParty/ANGLE/src/libGLESv2/global_state.h -index cfb2ae2..e85ec60 100644 ---- a/Source/ThirdParty/ANGLE/src/libGLESv2/global_state.h -+++ b/Source/ThirdParty/ANGLE/src/libGLESv2/global_state.h -@@ -97,7 +97,7 @@ class Thread; - extern Thread *GetCurrentThreadTLS(); - extern void SetCurrentThreadTLS(Thread *thread); - #else --extern thread_local Thread *gCurrentThread; -+extern __thread Thread *gCurrentThread; - #endif - - angle::GlobalMutex &GetGlobalMutex(); -diff --git a/Source/WTF/wtf/FastMalloc.cpp b/Source/WTF/wtf/FastMalloc.cpp -index 30e43b3..541915f 100644 ---- a/Source/WTF/wtf/FastMalloc.cpp -+++ b/Source/WTF/wtf/FastMalloc.cpp -@@ -58,8 +58,8 @@ - namespace WTF { - - #if ASSERT_ENABLED --thread_local static unsigned forbidMallocUseScopeCount; --thread_local static unsigned disableMallocRestrictionScopeCount; -+__thread unsigned forbidMallocUseScopeCount; -+__thread unsigned disableMallocRestrictionScopeCount; - - ForbidMallocUseForCurrentThreadScope::ForbidMallocUseForCurrentThreadScope() - { -diff --git a/Source/WebCore/platform/graphics/gbm/GraphicsContextGLANGLELinux.cpp b/Source/WebCore/platform/graphics/gbm/GraphicsContextGLANGLELinux.cpp -index a097b23..5d42aa1 100644 ---- a/Source/WebCore/platform/graphics/gbm/GraphicsContextGLANGLELinux.cpp -+++ b/Source/WebCore/platform/graphics/gbm/GraphicsContextGLANGLELinux.cpp -@@ -108,7 +108,7 @@ RefPtr GraphicsContextGLANGLE::readCompositedResults() - - bool GraphicsContextGLANGLE::makeContextCurrent() - { -- static thread_local TLS_MODEL_INITIAL_EXEC GraphicsContextGLANGLE* s_currentContext { nullptr }; -+ __thread TLS_MODEL_INITIAL_EXEC GraphicsContextGLANGLE* s_currentContext { nullptr }; - - if (s_currentContext == this) - return true; --- -2.37.3 - - -From 1d366b98de71c31f0664119e65c77957b9bcadb7 Mon Sep 17 00:00:00 2001 -From: Gerasim Troeglazov <3dEyes@gmail.com> -Date: Fri, 25 Nov 2022 17:54:59 +1000 -Subject: Fix platform defs - - -diff --git a/Source/WTF/wtf/CheckedArithmetic.h b/Source/WTF/wtf/CheckedArithmetic.h -index c9d31d5..25b90a3 100644 ---- a/Source/WTF/wtf/CheckedArithmetic.h -+++ b/Source/WTF/wtf/CheckedArithmetic.h -@@ -34,7 +34,7 @@ - /* On Linux with clang, libgcc is usually used instead of compiler-rt, and it does - * not provide the __mulodi4 symbol used by clang for __builtin_mul_overflow - */ --#if COMPILER(GCC) || (COMPILER(CLANG) && !(CPU(ARM) && OS(LINUX))) && !PLATFORM(IOS_FAMILY_SIMULATOR) -+#if COMPILER(GCC) || (COMPILER(CLANG) && !(CPU(ARM) && OS(LINUX)) && !OS(HAIKU)) && !PLATFORM(IOS_FAMILY_SIMULATOR) - #define USE_MUL_OVERFLOW 1 - #endif - -diff --git a/Source/WTF/wtf/InlineASM.h b/Source/WTF/wtf/InlineASM.h -index aba12e0..04f2529 100644 ---- a/Source/WTF/wtf/InlineASM.h -+++ b/Source/WTF/wtf/InlineASM.h -@@ -43,7 +43,7 @@ - #define THUMB_FUNC_PARAM(name) - #endif - --#if (OS(LINUX) || OS(FREEBSD)) && CPU(X86_64) -+#if (OS(LINUX) || OS(FREEBSD) || OS(HAIKU)) && CPU(X86_64) - #define GLOBAL_REFERENCE(name) #name "@plt" - #elif CPU(X86) && COMPILER(MINGW) - #define GLOBAL_REFERENCE(name) "@" #name "@4" -diff --git a/Source/WTF/wtf/PlatformEnable.h b/Source/WTF/wtf/PlatformEnable.h -index 8863f57..2e4548d 100644 ---- a/Source/WTF/wtf/PlatformEnable.h -+++ b/Source/WTF/wtf/PlatformEnable.h -@@ -646,7 +646,7 @@ - #if !defined(ENABLE_DFG_JIT) && ENABLE(JIT) - - /* Enable the DFG JIT on X86 and X86_64. */ --#if CPU(X86_64) && (OS(DARWIN) || OS(LINUX) || OS(FREEBSD) || OS(HURD) || OS(WINDOWS)) -+#if CPU(X86_64) && (OS(DARWIN) || OS(LINUX) || OS(HAIKU) || OS(FREEBSD) || OS(HURD) || OS(WINDOWS)) - #define ENABLE_DFG_JIT 1 - #endif - --- -2.37.3 - - -From 1225ec8c5d2b14320605f6093b9b9dceb33ec175 Mon Sep 17 00:00:00 2001 -From: Gerasim Troeglazov <3dEyes@gmail.com> -Date: Fri, 25 Nov 2022 17:55:35 +1000 -Subject: Fix build for x86 arch - - -diff --git a/Source/JavaScriptCore/API/glib/JSCOptions.cpp b/Source/JavaScriptCore/API/glib/JSCOptions.cpp -index dd46ff5..54f6dac 100644 ---- a/Source/JavaScriptCore/API/glib/JSCOptions.cpp -+++ b/Source/JavaScriptCore/API/glib/JSCOptions.cpp -@@ -73,7 +73,7 @@ static void valueToGValue(int32_t value, GValue* gValue) - g_value_set_int(gValue, value); - } - --#if CPU(ADDRESS64) -+#if CPU(ADDRESS64) || OS(HAIKU) - static bool valueFromGValue(const GValue* gValue, unsigned& value) - { - value = g_value_get_uint(gValue); -@@ -556,7 +556,7 @@ static JSCOptionType jscOptionsType(int) - return JSC_OPTION_INT; - } - --#if CPU(ADDRESS64) -+#if CPU(ADDRESS64) || OS(HAIKU) - static JSCOptionType jscOptionsType(unsigned) - { - return JSC_OPTION_UINT; -diff --git a/Source/JavaScriptCore/runtime/Options.cpp b/Source/JavaScriptCore/runtime/Options.cpp -index 47a6001..c10cfa0 100644 ---- a/Source/JavaScriptCore/runtime/Options.cpp -+++ b/Source/JavaScriptCore/runtime/Options.cpp -@@ -91,7 +91,7 @@ std::optional parse(const char* string) - return std::nullopt; - } - --#if CPU(ADDRESS64) || OS(DARWIN) -+#if CPU(ADDRESS64) || OS(DARWIN) || OS(HAIKU) - template<> - std::optional parse(const char* string) - { -@@ -100,7 +100,7 @@ std::optional parse(const char* string) - return value; - return std::nullopt; - } --#endif // CPU(ADDRESS64) || OS(DARWIN) -+#endif // CPU(ADDRESS64) || OS(DARWIN) || OS(HAIKU) - - template<> - std::optional parse(const char* string) --- -2.37.3 - - -From 758993fc64a16dbab32487bffe146915a9c08cb8 Mon Sep 17 00:00:00 2001 -From: Gerasim Troeglazov <3dEyes@gmail.com> -Date: Mon, 28 Nov 2022 15:49:52 +1000 -Subject: fix bmalloc for haiku +Date: Sat, 17 Dec 2022 23:38:33 +1000 +Subject: Fix build bmalloc allocator diff --git a/Source/bmalloc/bmalloc/AvailableMemory.cpp b/Source/bmalloc/bmalloc/AvailableMemory.cpp @@ -761,7 +802,7 @@ index c89de56..c342e71 100644 long pages = sysconf(_SC_PHYS_PAGES); long pageSize = sysconf(_SC_PAGE_SIZE); diff --git a/Source/bmalloc/bmalloc/BPlatform.h b/Source/bmalloc/bmalloc/BPlatform.h -index 0eae025..7000e28 100644 +index 00633b6..a243177 100644 --- a/Source/bmalloc/bmalloc/BPlatform.h +++ b/Source/bmalloc/bmalloc/BPlatform.h @@ -48,6 +48,10 @@ @@ -800,7 +841,7 @@ index 86dbb86..b2199d7 100644 // Truncate the given name since Linux limits the size of the thread name 16 including null terminator. std::array buf; diff --git a/Source/bmalloc/bmalloc/VMAllocate.h b/Source/bmalloc/bmalloc/VMAllocate.h -index de8e8b2..c14d19a 100644 +index 4315b4c..147d766 100644 --- a/Source/bmalloc/bmalloc/VMAllocate.h +++ b/Source/bmalloc/bmalloc/VMAllocate.h @@ -39,13 +39,17 @@ @@ -853,36 +894,81 @@ index de8e8b2..c14d19a 100644 2.37.3 -From 0d0f84f09c8a0f23ec5d4cad4efc1c4bc58af1f8 Mon Sep 17 00:00:00 2001 +From 90c00073b956e188ccd3f5e2e45873c85b3a4935 Mon Sep 17 00:00:00 2001 From: Gerasim Troeglazov <3dEyes@gmail.com> -Date: Tue, 29 Nov 2022 23:49:50 +1000 -Subject: Exit after stopping RunLoop +Date: Sat, 17 Dec 2022 23:38:56 +1000 +Subject: Use __thread instead thread_local -diff --git a/Source/WebKit/Shared/AuxiliaryProcess.cpp b/Source/WebKit/Shared/AuxiliaryProcess.cpp -index b7f04d4..a9c8ffc 100644 ---- a/Source/WebKit/Shared/AuxiliaryProcess.cpp -+++ b/Source/WebKit/Shared/AuxiliaryProcess.cpp -@@ -191,10 +191,18 @@ void AuxiliaryProcess::stopRunLoop() - platformStopRunLoop(); - } +diff --git a/Source/ThirdParty/ANGLE/src/common/system_utils_posix.cpp b/Source/ThirdParty/ANGLE/src/common/system_utils_posix.cpp +index ab0faee..b6ff86f 100644 +--- a/Source/ThirdParty/ANGLE/src/common/system_utils_posix.cpp ++++ b/Source/ThirdParty/ANGLE/src/common/system_utils_posix.cpp +@@ -199,10 +199,12 @@ void *OpenSystemLibraryWithExtensionAndGetError(const char *libraryName, + } --#if !PLATFORM(COCOA) -+#if !PLATFORM(COCOA) && !OS(HAIKU) -+void AuxiliaryProcess::platformStopRunLoop() -+{ -+ RunLoop::main().stop(); -+} + int extraFlags = 0; ++#ifndef __HAIKU__ + if (searchType == SearchType::AlreadyLoaded) + { + extraFlags = RTLD_NOLOAD; + } +#endif -+ -+#if OS(HAIKU) - void AuxiliaryProcess::platformStopRunLoop() - { - RunLoop::main().stop(); -+ _exit(EXIT_SUCCESS); + + std::string fullPath = directory + libraryName; + return OpenPosixLibrary(fullPath, extraFlags, errorOut); +diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/Context.cpp b/Source/ThirdParty/ANGLE/src/libANGLE/Context.cpp +index 0f3dd83..bc002de 100644 +--- a/Source/ThirdParty/ANGLE/src/libANGLE/Context.cpp ++++ b/Source/ThirdParty/ANGLE/src/libANGLE/Context.cpp +@@ -441,7 +441,7 @@ void SetCurrentValidContextTLS(Context *context) + SetTLSValue(CurrentValidContextIndex, context); } + #else +-thread_local Context *gCurrentValidContext = nullptr; ++__thread Context *gCurrentValidContext = nullptr; #endif + Context::Context(egl::Display *display, +diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/Context.h b/Source/ThirdParty/ANGLE/src/libANGLE/Context.h +index 2178a25..6a7071b 100644 +--- a/Source/ThirdParty/ANGLE/src/libANGLE/Context.h ++++ b/Source/ThirdParty/ANGLE/src/libANGLE/Context.h +@@ -894,7 +894,7 @@ class [[nodiscard]] ScopedContextRef + extern Context *GetCurrentValidContextTLS(); + extern void SetCurrentValidContextTLS(Context *context); + #else +-extern thread_local Context *gCurrentValidContext; ++extern __thread Context *gCurrentValidContext; + #endif + + } // namespace gl +diff --git a/Source/ThirdParty/ANGLE/src/libGLESv2/global_state.cpp b/Source/ThirdParty/ANGLE/src/libGLESv2/global_state.cpp +index f807cd2..3d975f0 100644 +--- a/Source/ThirdParty/ANGLE/src/libGLESv2/global_state.cpp ++++ b/Source/ThirdParty/ANGLE/src/libGLESv2/global_state.cpp +@@ -147,7 +147,7 @@ void SetCurrentThreadTLS(Thread *thread) + SetTLSValue(CurrentThreadIndex, thread); + } + #else +-thread_local Thread *gCurrentThread = nullptr; ++__thread Thread *gCurrentThread = nullptr; + #endif + + angle::GlobalMutex &GetGlobalMutex() +diff --git a/Source/ThirdParty/ANGLE/src/libGLESv2/global_state.h b/Source/ThirdParty/ANGLE/src/libGLESv2/global_state.h +index 947baf3..cb25561 100644 +--- a/Source/ThirdParty/ANGLE/src/libGLESv2/global_state.h ++++ b/Source/ThirdParty/ANGLE/src/libGLESv2/global_state.h +@@ -97,7 +97,7 @@ class Thread; + extern Thread *GetCurrentThreadTLS(); + extern void SetCurrentThreadTLS(Thread *thread); + #else +-extern thread_local Thread *gCurrentThread; ++extern __thread Thread *gCurrentThread; + #endif + + angle::GlobalMutex &GetGlobalMutex(); -- 2.37.3 diff --git a/net-libs/webkit-gtk/webkit_gtk-2.38.2.recipe b/net-libs/webkit-gtk/webkit_gtk-2.39.3.recipe similarity index 93% rename from net-libs/webkit-gtk/webkit_gtk-2.38.2.recipe rename to net-libs/webkit-gtk/webkit_gtk-2.39.3.recipe index a409657e7..abc8727f0 100644 --- a/net-libs/webkit-gtk/webkit_gtk-2.38.2.recipe +++ b/net-libs/webkit-gtk/webkit_gtk-2.39.3.recipe @@ -12,9 +12,9 @@ COPYRIGHT="2009‒2022 The WebKitGTK Team" LICENSE="GNU LGPL v2 BSD (2-clause) " -REVISION="6" +REVISION="1" SOURCE_URI="https://www.webkitgtk.org/releases/webkitgtk-$portVersion.tar.xz" -CHECKSUM_SHA256="f3eb82899651f583b4d99cacd16af784a1a7710fce9e7b6807bd6ccde909fe3e" +CHECKSUM_SHA256="6b783704f16f35e72cd6eeb546eaf6d5221ca70e70639f3906def2e9a473bf9b" SOURCE_DIR="webkitgtk-$portVersion" PATCHES="webkit_gtk-$portVersion.patchset" ADDITIONAL_FILES=" @@ -27,8 +27,8 @@ SECONDARY_ARCHITECTURES="x86" PROVIDES=" webkit_gtk$secondaryArchSuffix = $portVersion - lib:libwebkit2gtk_4.1$secondaryArchSuffix = 0.2.5 compat >= 0 - lib:libjavascriptcoregtk_4.1$secondaryArchSuffix = 0.2.5 compat >= 0 + lib:libwebkit2gtk_4.1$secondaryArchSuffix = 0.5.0 compat >= 0 + lib:libjavascriptcoregtk_4.1$secondaryArchSuffix = 0.3.2 compat >= 0 app:MiniBrowser = $portVersion " REQUIRES=" @@ -40,6 +40,7 @@ REQUIRES=" lib:libcairo$secondaryArchSuffix lib:libcairo_gobject$secondaryArchSuffix lib:libenchant_2$secondaryArchSuffix + lib:libepoxy$secondaryArchSuffix lib:libfontconfig$secondaryArchSuffix lib:libfreetype$secondaryArchSuffix lib:libgcrypt$secondaryArchSuffix @@ -92,8 +93,8 @@ REQUIRES=" PROVIDES_devel=" webkit_gtk${secondaryArchSuffix}_devel = $portVersion - devel:libwebkit2gtk_4.1$secondaryArchSuffix = 0.2.5 compat >= 0 - devel:libjavascriptcoregtk_4.1$secondaryArchSuffix = 0.2.5 compat >= 0 + devel:libwebkit2gtk_4.1$secondaryArchSuffix = 0.5.0 compat >= 0 + devel:libjavascriptcoregtk_4.1$secondaryArchSuffix = 0.3.2 compat >= 0 " REQUIRES_devel=" webkit_gtk$secondaryArchSuffix == $portVersion base @@ -115,6 +116,7 @@ BUILD_REQUIRES=" devel:libbrotlidec$secondaryArchSuffix devel:libcrypto$secondaryArchSuffix devel:libenchant_2$secondaryArchSuffix + devel:libepoxy$secondaryArchSuffix devel:libevent_2.1$secondaryArchSuffix devel:libfontconfig$secondaryArchSuffix devel:libfreetype$secondaryArchSuffix @@ -178,6 +180,7 @@ BUILD_PREREQUIRES=" cmd:ruby cmd:sed cmd:xargs + cmd:unifdef " PATCH() @@ -208,7 +211,7 @@ BUILD() -DENABLE_API_TESTS=OFF \ -DENABLE_BUBBLEWRAP_SANDBOX=OFF \ -DENABLE_DOCUMENTATION=OFF \ - -DENABLE_EXPERIMENTAL_FEATURES=OFF \ + -DENABLE_EXPERIMENTAL_FEATURES=ON \ -DENABLE_FTPDIR=ON \ -DENABLE_GAMEPAD=OFF \ -DENABLE_GEOLOCATION=ON \ @@ -216,28 +219,30 @@ BUILD() -DENABLE_GTKDOC=OFF \ -DENABLE_INTROSPECTION=ON \ -DENABLE_JOURNALD_LOG=OFF \ - -DENABLE_MEDIA_STREAM=ON \ + -DENABLE_MEDIA_STREAM=OFF \ -DENABLE_MEDIA_RECORDER=OFF \ -DENABLE_MEDIA_SOURCE=ON \ -DENABLE_MINIBROWSER=ON \ -DENABLE_QUARTZ_TARGET=OFF \ -DENABLE_SAMPLING_PROFILER=OFF \ - -DENABLE_SERVICE_WORKER=OFF \ + -DENABLE_SERVICE_WORKER=ON \ -DENABLE_SMOOTH_SCROLLING=OFF \ -DENABLE_SPELLCHECK=ON \ -DENABLE_UNIFIED_BUILDS=ON \ - -DENABLE_VARIATION_FONTS=OFF \ + -DENABLE_VARIATION_FONTS=ON \ -DENABLE_VIDEO=ON \ -DENABLE_WEB_AUDIO=ON \ -DENABLE_WEBDRIVER=OFF \ -DENABLE_WEBGL=ON \ + -DENABLE_WEBGL2=OFF \ -DENABLE_WEB_RTC=ON \ -DENABLE_WAYLAND_TARGET=OFF \ -DENABLE_X11_TARGET=OFF \ -DUSE_ATSPI=OFF \ -DUSE_AVIF=ON \ + -DUSE_GBM=OFF \ -DUSE_GSTREAMER_GL=OFF \ - -DUSE_GSTREAMER_WEBRTC=ON \ + -DUSE_GSTREAMER_WEBRTC=OFF \ -DUSE_GSTREAMER_TRANSCODER=OFF \ -DUSE_GTK4=OFF \ -DUSE_JPEGXL=ON \ @@ -249,7 +254,7 @@ BUILD() -DUSE_OPENGL=ON \ -DUSE_OPENJPEG=ON \ -DUSE_SOUP2=OFF \ - -DUSE_SYSTEM_MALLOC=OFF \ + -DUSE_SYSTEM_MALLOC=ON \ -DUSE_SYSTEMD=OFF \ -DUSE_WOFF2=ON \ -DUSE_WPE_RENDERER=OFF