diff -ruwN source/Source/bmalloc/bmalloc/BPlatform.h source-new/Source/bmalloc/bmalloc/BPlatform.h
--- source/Source/bmalloc/bmalloc/BPlatform.h	2025-03-28 13:18:28.347204000 +0700
+++ source-new/Source/bmalloc/bmalloc/BPlatform.h	2025-10-07 20:55:41.123161164 +0700
@@ -40,7 +40,7 @@
 #define BOS_DARWIN 1
 #endif
 
-#if defined(__unix) || defined(__unix__)
+#if defined(__unix) || defined(__unix__) || defined(__redox__)
 #define BOS_UNIX 1
 #endif
 
@@ -339,7 +339,7 @@
 
 /* BENABLE(LIBPAS) is enabling libpas build. But this does not mean we use libpas for bmalloc replacement. */
 #if !defined(BENABLE_LIBPAS)
-#if BCPU(ADDRESS64) && (BOS(DARWIN) || (BOS(LINUX) && (BCPU(X86_64) || BCPU(ARM64))) || BPLATFORM(PLAYSTATION))
+#if BCPU(ADDRESS64) && (BOS(DARWIN) || (BOS(LINUX) && (BCPU(X86_64) || BCPU(ARM64))) || BPLATFORM(PLAYSTATION)) || defined(__redox__)
 #define BENABLE_LIBPAS 1
 #ifndef PAS_BMALLOC
 #define PAS_BMALLOC 1
diff -ruwN source/Source/bmalloc/libpas/src/libpas/pas_committed_pages_vector.c source-new/Source/bmalloc/libpas/src/libpas/pas_committed_pages_vector.c
--- source/Source/bmalloc/libpas/src/libpas/pas_committed_pages_vector.c	2023-09-18 14:56:46.731077000 +0700
+++ source-new/Source/bmalloc/libpas/src/libpas/pas_committed_pages_vector.c	2025-10-07 22:23:20.298893452 +0700
@@ -57,6 +57,8 @@
 
 #if PAS_OS(LINUX)
     PAS_SYSCALL(mincore(object, size, (unsigned char*)vector->raw_data));
+#elif PAS_OS(REDOX)
+    // no op
 #else
     PAS_SYSCALL(mincore(object, size, vector->raw_data));
 #endif
diff -ruwN source/Source/bmalloc/libpas/src/libpas/pas_committed_pages_vector.h source-new/Source/bmalloc/libpas/src/libpas/pas_committed_pages_vector.h
--- source/Source/bmalloc/libpas/src/libpas/pas_committed_pages_vector.h	2023-09-18 14:56:46.731077000 +0700
+++ source-new/Source/bmalloc/libpas/src/libpas/pas_committed_pages_vector.h	2025-10-07 22:23:29.232045934 +0700
@@ -56,6 +56,8 @@
     PAS_ASSERT(page_index < vector->size);
 #if PAS_OS(LINUX)
     return vector->raw_data[page_index];
+#elif PAS_OS(REDOX)
+    return true; // redox don't have swap yet
 #else
     return vector->raw_data[page_index] & (MINCORE_REFERENCED |
                                            MINCORE_REFERENCED_OTHER |
diff -ruwN source/Source/bmalloc/libpas/src/libpas/pas_monotonic_time.c source-new/Source/bmalloc/libpas/src/libpas/pas_monotonic_time.c
--- source/Source/bmalloc/libpas/src/libpas/pas_monotonic_time.c	2023-09-18 14:56:46.743076800 +0700
+++ source-new/Source/bmalloc/libpas/src/libpas/pas_monotonic_time.c	2025-10-07 22:23:50.202403881 +0700
@@ -89,6 +89,15 @@
     return ts.tv_sec * 1000u * 1000u * 1000u + ts.tv_nsec;
 }
 
+
+#elif PAS_OS(REDOX)
+
+uint64_t pas_get_current_monotonic_time_nanoseconds(void)
+{
+    struct timespec ts;
+    clock_gettime(CLOCK_MONOTONIC, &ts);
+    return (uint64_t)ts.tv_sec * 1000000000 + (uint64_t)ts.tv_nsec;
+}
 #endif
 
 #endif /* LIBPAS_ENABLED */
diff -ruwN source/Source/bmalloc/libpas/src/libpas/pas_page_malloc.c source-new/Source/bmalloc/libpas/src/libpas/pas_page_malloc.c
--- source/Source/bmalloc/libpas/src/libpas/pas_page_malloc.c	2024-12-20 17:10:23.123508500 +0700
+++ source-new/Source/bmalloc/libpas/src/libpas/pas_page_malloc.c	2025-10-07 22:26:27.358086406 +0700
@@ -228,6 +228,8 @@
     PAS_SYSCALL(madvise(ptr, size, MADV_DODUMP));
 #elif PAS_PLATFORM(PLAYSTATION)
     // We don't need to call madvise to map page.
+#elif PAS_OS(REDOX)
+    // madvise not implemented
 #elif PAS_OS(FREEBSD)
     PAS_SYSCALL(madvise(ptr, size, MADV_NORMAL));
 #endif
@@ -276,6 +278,8 @@
 #elif PAS_OS(LINUX)
     PAS_SYSCALL(madvise(ptr, size, MADV_DONTNEED));
     PAS_SYSCALL(madvise(ptr, size, MADV_DONTDUMP));
+#elif PAS_OS(REDOX)
+    // madvise not implemented
 #else
     PAS_SYSCALL(madvise(ptr, size, MADV_DONTNEED));
 #endif
diff -ruwN source/Source/bmalloc/libpas/src/libpas/pas_platform.h source-new/Source/bmalloc/libpas/src/libpas/pas_platform.h
--- source/Source/bmalloc/libpas/src/libpas/pas_platform.h	2024-11-07 21:16:41.458338300 +0700
+++ source-new/Source/bmalloc/libpas/src/libpas/pas_platform.h	2025-10-07 22:22:50.849390772 +0700
@@ -132,6 +132,10 @@
 #define PAS_OS_LINUX 1
 #endif
 
+#ifdef __redox__
+#define PAS_OS_REDOX 1
+#endif
+
 #if defined(__FreeBSD__) || defined(__DragonFly__) || defined(__FreeBSD_kernel__)
 #define PAS_OS_FREEBSD 1
 #endif
diff -ruwN source/Source/bmalloc/libpas/src/libpas/pas_probabilistic_guard_malloc_allocator.c source-new/Source/bmalloc/libpas/src/libpas/pas_probabilistic_guard_malloc_allocator.c
--- source/Source/bmalloc/libpas/src/libpas/pas_probabilistic_guard_malloc_allocator.c	2025-03-27 13:32:32.679094000 +0700
+++ source-new/Source/bmalloc/libpas/src/libpas/pas_probabilistic_guard_malloc_allocator.c	2025-10-07 22:27:40.764339395 +0700
@@ -165,16 +165,6 @@
     mprotect_res = mprotect((void*)upper_guard, upper_guard_size, PROT_NONE);
     PAS_ASSERT(!mprotect_res);
 
-    /*
-     * ensure physical addresses are released
-     * TODO: investigate using MADV_FREE_REUSABLE instead
-     */
-    int madvise_res = madvise((void*)upper_guard, upper_guard_size, MADV_FREE);
-    PAS_ASSERT(!madvise_res);
-
-    madvise_res = madvise((void*)lower_guard, lower_guard_size, MADV_FREE);
-    PAS_ASSERT(!madvise_res);
-
     PAS_PROFILE(PGM_ALLOCATE, heap_config, key);
 
     /* create struct to hold hash map value */
@@ -231,13 +221,6 @@
     int mprotect_res = mprotect((void*)value->start_of_data_pages, value->size_of_data_pages, PROT_NONE);
     PAS_ASSERT(!mprotect_res);
 
-    /*
-     * ensure physical addresses are released
-     * TODO: investigate using MADV_FREE_REUSABLE instead
-     */
-    int madvise_res = madvise((void*)value->start_of_data_pages, value->size_of_data_pages, MADV_FREE);
-    PAS_ASSERT(!madvise_res);
-
     free_wasted_mem  += value->mem_to_waste;
     free_virtual_mem += value->size_of_allocated_pages;
 
diff -ruwN source/Source/JavaScriptCore/heap/BlockDirectory.cpp source-new/Source/JavaScriptCore/heap/BlockDirectory.cpp
--- source/Source/JavaScriptCore/heap/BlockDirectory.cpp	2025-03-21 00:07:59.015023500 +0700
+++ source-new/Source/JavaScriptCore/heap/BlockDirectory.cpp	2025-09-09 09:08:03.419985553 +0700
@@ -68,7 +68,7 @@
     // FIXME: We should figure out a solution for Windows and PlayStation.
     // QNX doesn't have mincore(), though the information can be had. But since all mapped
     // pages are resident, does it matter?
-#if OS(UNIX) && !PLATFORM(PLAYSTATION) && !OS(QNX) && !OS(HAIKU)
+#if OS(UNIX) && !PLATFORM(PLAYSTATION) && !OS(QNX) && !OS(HAIKU) && !defined(__redox__)
     size_t pageSize = WTF::pageSize();
     ASSERT(!(MarkedBlock::blockSize % pageSize));
     auto numberOfPagesInMarkedBlock = MarkedBlock::blockSize / pageSize;
diff -ruwN source/Source/JavaScriptCore/jsc.cpp source-new/Source/JavaScriptCore/jsc.cpp
--- source/Source/JavaScriptCore/jsc.cpp	2025-03-21 18:07:10.820055200 +0700
+++ source-new/Source/JavaScriptCore/jsc.cpp	2025-09-09 09:08:03.446985840 +0700
@@ -208,6 +208,8 @@
         for (;;) {
 #if OS(WINDOWS)
             Sleep(1000);
+#elif defined(__redox__)
+            //TODO
 #else
             pause();
 #endif
diff -ruwN source/Source/JavaScriptCore/runtime/JSCBytecodeCacheVersion.cpp source-new/Source/JavaScriptCore/runtime/JSCBytecodeCacheVersion.cpp
--- source/Source/JavaScriptCore/runtime/JSCBytecodeCacheVersion.cpp	2025-03-21 00:07:59.015023500 +0700
+++ source-new/Source/JavaScriptCore/runtime/JSCBytecodeCacheVersion.cpp	2025-09-09 09:08:03.446985840 +0700
@@ -37,7 +37,7 @@
 #include <mach-o/dyld.h>
 #include <uuid/uuid.h>
 #include <wtf/spi/darwin/dyldSPI.h>
-#else
+#elif !defined(__redox__)
 #include <link.h>
 #endif
 #endif
@@ -66,7 +66,7 @@
         }
         cacheVersion.construct(0);
         dataLogLnIf(JSCBytecodeCacheVersionInternal::verbose, "Failed to get UUID for JavaScriptCore framework");
-#elif OS(UNIX) && !PLATFORM(PLAYSTATION) && !OS(HAIKU)
+#elif OS(UNIX) && !PLATFORM(PLAYSTATION) && !OS(HAIKU) && !defined(__redox__)
         auto result = ([&] -> std::optional<uint32_t> {
             Dl_info info { };
             if (!dladdr(jsFunctionAddr, &info))
diff -ruwN source/Source/JavaScriptCore/runtime/MachineContext.h source-new/Source/JavaScriptCore/runtime/MachineContext.h
--- source/Source/JavaScriptCore/runtime/MachineContext.h	2025-03-21 00:07:59.015023500 +0700
+++ source-new/Source/JavaScriptCore/runtime/MachineContext.h	2025-09-09 09:08:03.473986127 +0700
@@ -158,7 +158,7 @@
 {
 #if OS(DARWIN)
     return stackPointerImpl(machineContext->__ss);
-#elif OS(HAIKU)
+#elif OS(HAIKU) || defined(__redox__)
 #if CPU(X86_64)
     return reinterpret_cast<void*&>(machineContext.rsp);
 #else
@@ -287,7 +287,7 @@
 {
 #if OS(DARWIN)
     return framePointerImpl(machineContext->__ss);
-#elif OS(HAIKU)
+#elif OS(HAIKU) || defined(__redox__)
 #if CPU(X86_64)
     return reinterpret_cast<void*&>(machineContext.rbp);
 #else
@@ -455,7 +455,7 @@
 {
 #if OS(DARWIN)
     return instructionPointerImpl(machineContext->__ss);
-#elif OS(HAIKU)
+#elif OS(HAIKU) || defined(__redox__)
 #if CPU(X86_64)
     return reinterpret_cast<void*&>((uintptr_t&) machineContext.rip);
 #else
@@ -649,7 +649,7 @@
 {
 #if OS(DARWIN)
     return argumentPointer<1>(machineContext->__ss);
-#elif OS(HAIKU)
+#elif OS(HAIKU) || defined(__redox__)
 #if CPU(X86_64)
     return reinterpret_cast<void*&>((uintptr_t&) machineContext.rsi);
 #else
@@ -760,6 +760,13 @@
 #error Unknown Architecture
 #endif
 
+#elif defined(__redox__)
+#if CPU(X86_64)
+    return reinterpret_cast<void*>((uintptr_t) machineContext.rbx);
+#else
+#error Unknown Architecture
+#endif
+
 #else
 #error Need a way to get the frame pointer for another thread on this platform
 #endif
@@ -834,7 +841,7 @@
     // LLInt uses regT4 as PC.
 #if OS(DARWIN)
     return llintInstructionPointer(machineContext->__ss);
-#elif OS(HAIKU)
+#elif OS(HAIKU) || defined(__redox__)
 #if CPU(X86_64)
     return reinterpret_cast<void*&>((uintptr_t&) machineContext.r8);
 #else
diff -ruwN source/Source/JavaScriptCore/runtime/Options.cpp source-new/Source/JavaScriptCore/runtime/Options.cpp
--- source/Source/JavaScriptCore/runtime/Options.cpp	2025-03-20 18:07:59.015023500 +0100
+++ source-new/Source/JavaScriptCore/runtime/Options.cpp	2026-05-22 01:21:58.011957922 +0200
@@ -36,6 +36,7 @@
 #include <mutex>
 #include <stdlib.h>
 #include <string.h>
+#include <strings.h>
 #include <wtf/ASCIICType.h>
 #include <wtf/BitSet.h>
 #include <wtf/Compiler.h>
diff -ruwN source/Source/JavaScriptCore/yarr/YarrPattern.cpp source-new/Source/JavaScriptCore/yarr/YarrPattern.cpp
--- source/Source/JavaScriptCore/yarr/YarrPattern.cpp	2025-03-07 12:11:01.486010300 +0100
+++ source-new/Source/JavaScriptCore/yarr/YarrPattern.cpp	2026-05-22 01:28:48.678618215 +0200
@@ -2639,7 +2639,7 @@
         return;
     out.print(" {", quantityMinCount.value());
     if (quantityMinCount != quantityMaxCount) {
-        if (quantityMaxCount == UINT_MAX)
+        if (quantityMaxCount == (uint32_t)UINT_MAX)
             out.print(",...");
         else
             out.print(",", quantityMaxCount.value());
diff -ruwN source/Source/ThirdParty/ANGLE/GLESv2.cmake source-new/Source/ThirdParty/ANGLE/GLESv2.cmake
--- source/Source/ThirdParty/ANGLE/GLESv2.cmake	2025-02-17 19:59:58.567796700 +0700
+++ source-new/Source/ThirdParty/ANGLE/GLESv2.cmake	2025-09-09 09:08:03.495986361 +0700
@@ -120,7 +120,7 @@
 
 if(is_linux OR is_chromeos OR is_android OR is_fuchsia)
     list(APPEND libangle_common_sources
-        "src/common/system_utils_linux.cpp"
+        #"src/common/system_utils_linux.cpp"
         "src/common/system_utils_posix.cpp"
     )
 endif()
diff -ruwN source/Source/ThirdParty/ANGLE/PlatformGTK.cmake source-new/Source/ThirdParty/ANGLE/PlatformGTK.cmake
--- source/Source/ThirdParty/ANGLE/PlatformGTK.cmake	2023-10-21 14:33:32.730009300 +0700
+++ source-new/Source/ThirdParty/ANGLE/PlatformGTK.cmake	2025-09-09 09:08:03.500986415 +0700
@@ -1,4 +1,4 @@
-list(APPEND ANGLE_DEFINITIONS ANGLE_PLATFORM_LINUX EGL_NO_PLATFORM_SPECIFIC_TYPES USE_SYSTEM_EGL)
+list(APPEND ANGLE_DEFINITIONS ANGLE_PLATFORM_POSIX EGL_NO_PLATFORM_SPECIFIC_TYPES USE_SYSTEM_EGL)
 include(linux.cmake)
 
 if (USE_OPENGL)
diff -ruwN source/Source/ThirdParty/ANGLE/src/common/log_utils.h source-new/Source/ThirdParty/ANGLE/src/common/log_utils.h
--- source/Source/ThirdParty/ANGLE/src/common/log_utils.h	2025-02-17 19:59:58.571796700 +0700
+++ source-new/Source/ThirdParty/ANGLE/src/common/log_utils.h	2025-09-09 09:08:03.501986425 +0700
@@ -136,10 +136,12 @@
         return FmtHexAutoSized(os, fmt.mValue, fmt.mPrefix, "0x", '0');
     }
 
+#if !defined(__redox__)
     friend std::wostream &operator<<(std::wostream &wos, const FmtHexHelper &fmt)
     {
         return FmtHexAutoSized(wos, fmt.mValue, fmt.mPrefix, L"0x", L'0');
     }
+#endif
 };
 
 }  // namespace priv
diff -ruwN source/Source/ThirdParty/ANGLE/src/common/platform.h source-new/Source/ThirdParty/ANGLE/src/common/platform.h
--- source/Source/ThirdParty/ANGLE/src/common/platform.h	2024-09-03 13:28:47.067031900 +0700
+++ source-new/Source/ThirdParty/ANGLE/src/common/platform.h	2025-09-09 09:08:03.518986606 +0700
@@ -28,7 +28,7 @@
 #    define ANGLE_PLATFORM_POSIX 1
 #elif defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) ||              \
     defined(__DragonFly__) || defined(__sun) || defined(__GLIBC__) || defined(__GNU__) || \
-    defined(__QNX__) || defined(__Fuchsia__) || defined(__HAIKU__)
+    defined(__QNX__) || defined(__Fuchsia__) || defined(__HAIKU__) || defined(__redox__)
 #    define ANGLE_PLATFORM_POSIX 1
 #else
 #    error Unsupported platform.
diff -ruwN source/Source/ThirdParty/ANGLE/src/common/system_utils.h source-new/Source/ThirdParty/ANGLE/src/common/system_utils.h
--- source/Source/ThirdParty/ANGLE/src/common/system_utils.h	2024-05-30 18:59:22.953676200 +0700
+++ source-new/Source/ThirdParty/ANGLE/src/common/system_utils.h	2025-09-09 09:08:03.536986798 +0700
@@ -256,7 +256,9 @@
 }
 #endif
 
-void SetCurrentThreadName(const char *name);
+#if !defined(__redox__)
+void SetCurrentThreadName(const char *name)
+#endif
 }  // namespace angle
 
 #endif  // COMMON_SYSTEM_UTILS_H_
diff -ruwN source/Source/ThirdParty/ANGLE/src/common/system_utils_posix.cpp source-new/Source/ThirdParty/ANGLE/src/common/system_utils_posix.cpp
--- source/Source/ThirdParty/ANGLE/src/common/system_utils_posix.cpp	2024-05-30 18:59:22.953676200 +0700
+++ source-new/Source/ThirdParty/ANGLE/src/common/system_utils_posix.cpp	2025-09-09 09:08:03.539986830 +0700
@@ -33,6 +33,11 @@
 #    include <sys/resource.h>
 #endif
 
+#if defined(__redox__)
+#define SEGV_MAPERR 1
+#define SEGV_ACCERR 2
+#endif
+
 namespace angle
 {
 
diff -ruwN source/Source/ThirdParty/ANGLE/src/common/WorkerThread.cpp source-new/Source/ThirdParty/ANGLE/src/common/WorkerThread.cpp
--- source/Source/ThirdParty/ANGLE/src/common/WorkerThread.cpp	2024-06-25 15:04:37.142420000 +0700
+++ source-new/Source/ThirdParty/ANGLE/src/common/WorkerThread.cpp	2025-09-09 09:08:03.557987021 +0700
@@ -165,7 +165,9 @@
 
 void AsyncWorkerPool::threadLoop()
 {
+#if !defined(__redox__)
     angle::SetCurrentThreadName("ANGLE-Worker");
+#endif
 
     while (true)
     {
diff -ruwN source/Source/ThirdParty/ANGLE/src/libANGLE/Display.cpp source-new/Source/ThirdParty/ANGLE/src/libANGLE/Display.cpp
--- source/Source/ThirdParty/ANGLE/src/libANGLE/Display.cpp	2025-02-05 16:14:42.678567400 +0700
+++ source-new/Source/ThirdParty/ANGLE/src/libANGLE/Display.cpp	2025-09-09 09:08:03.577987234 +0700
@@ -58,7 +58,7 @@
 #        include "libANGLE/renderer/gl/wgl/DisplayWGL.h"
 #    elif ANGLE_ENABLE_CGL
 #        include "libANGLE/renderer/gl/cgl/DisplayCGL.h"
-#    elif defined(ANGLE_PLATFORM_LINUX)
+#    elif defined(ANGLE_PLATFORM_LINUX) || defined(__redox__)
 #        include "libANGLE/renderer/gl/egl/DisplayEGL.h"
 #        if defined(ANGLE_USE_X11)
 #            include "libANGLE/renderer/gl/glx/DisplayGLX_api.h"
@@ -422,7 +422,7 @@
             impl = new rx::DisplayCGL(state);
             break;
 
-#    elif defined(ANGLE_PLATFORM_LINUX)
+#    elif defined(ANGLE_PLATFORM_LINUX) || defined(__redox__)
 #        if defined(ANGLE_USE_GBM)
             if (platformType == 0)
             {
diff -ruwN source/Source/ThirdParty/ANGLE/src/libANGLE/renderer/vulkan/CLCommandQueueVk.cpp source-new/Source/ThirdParty/ANGLE/src/libANGLE/renderer/vulkan/CLCommandQueueVk.cpp
--- source/Source/ThirdParty/ANGLE/src/libANGLE/renderer/vulkan/CLCommandQueueVk.cpp	2025-02-17 19:59:58.575796600 +0700
+++ source-new/Source/ThirdParty/ANGLE/src/libANGLE/renderer/vulkan/CLCommandQueueVk.cpp	2025-09-09 09:08:03.578987245 +0700
@@ -142,7 +142,9 @@
 
 angle::Result DispatchWorkThread::finishLoop()
 {
+#if !defined(__redox__)
     angle::SetCurrentThreadName("ANGLE-CL-CQD");
+#endif
 
     while (true)
     {
diff -ruwN source/Source/ThirdParty/ANGLE/src/libANGLE/renderer/vulkan/CommandQueue.cpp source-new/Source/ThirdParty/ANGLE/src/libANGLE/renderer/vulkan/CommandQueue.cpp
--- source/Source/ThirdParty/ANGLE/src/libANGLE/renderer/vulkan/CommandQueue.cpp	2025-02-05 16:14:42.690567300 +0700
+++ source-new/Source/ThirdParty/ANGLE/src/libANGLE/renderer/vulkan/CommandQueue.cpp	2025-09-09 09:08:03.578987245 +0700
@@ -378,7 +378,9 @@
 
 void CleanUpThread::processTasks()
 {
+#if !defined(__redox__)
     angle::SetCurrentThreadName("ANGLE-GC");
+#endif
 
     while (true)
     {
diff -ruwN source/Source/ThirdParty/ANGLE/src/libGLESv2.gni source-new/Source/ThirdParty/ANGLE/src/libGLESv2.gni
--- source/Source/ThirdParty/ANGLE/src/libGLESv2.gni	2025-02-17 19:59:58.587796200 +0700
+++ source-new/Source/ThirdParty/ANGLE/src/libGLESv2.gni	2025-09-09 09:08:03.578987245 +0700
@@ -115,7 +115,7 @@
 
 if (is_linux || is_chromeos || is_android || is_fuchsia) {
   libangle_common_sources += [
-    "src/common/system_utils_linux.cpp",
+    #"src/common/system_utils_linux.cpp",
     "src/common/system_utils_posix.cpp",
   ]
 }
diff -ruwN source/Source/ThirdParty/skia/src/gpu/ganesh/GrAutoLocaleSetter.h source-new/Source/ThirdParty/skia/src/gpu/ganesh/GrAutoLocaleSetter.h
--- source/Source/ThirdParty/skia/src/gpu/ganesh/GrAutoLocaleSetter.h	2024-08-14 15:56:17.506453500 +0700
+++ source-new/Source/ThirdParty/skia/src/gpu/ganesh/GrAutoLocaleSetter.h	2025-09-09 09:08:03.579987255 +0700
@@ -27,7 +27,7 @@
 #define HAVE_XLOCALE 0
 #endif
 
-#if defined(SK_BUILD_FOR_ANDROID) || defined(__UCLIBC__) || defined(_NEWLIB_VERSION)
+#if defined(SK_BUILD_FOR_ANDROID) || defined(__UCLIBC__) || defined(_NEWLIB_VERSION) || defined(__redox__)
 #define HAVE_LOCALE_T 0
 #else
 #define HAVE_LOCALE_T 1
diff -ruwN source/Source/ThirdParty/skia/src/ports/SkMemory_malloc.cpp source-new/Source/ThirdParty/skia/src/ports/SkMemory_malloc.cpp
--- source/Source/ThirdParty/skia/src/ports/SkMemory_malloc.cpp	2024-05-30 18:59:23.965655000 +0700
+++ source-new/Source/ThirdParty/skia/src/ports/SkMemory_malloc.cpp	2025-09-09 09:08:03.579987255 +0700
@@ -126,7 +126,7 @@
     #elif defined(SK_BUILD_FOR_ANDROID) && __ANDROID_API__ >= 17
         completeSize = malloc_usable_size(addr);
         SkASSERT(completeSize >= size);
-    #elif defined(SK_BUILD_FOR_UNIX)
+    #elif defined(SK_BUILD_FOR_UNIX) && !defined(__redox__)
         completeSize = malloc_usable_size(addr);
         SkASSERT(completeSize >= size);
     #elif defined(SK_BUILD_FOR_WIN)
diff -ruwN source/Source/WebCore/page/Page.cpp source-new/Source/WebCore/page/Page.cpp
--- source/Source/WebCore/page/Page.cpp	2025-04-01 14:53:09.527295000 +0700
+++ source-new/Source/WebCore/page/Page.cpp	2025-09-09 09:08:03.580987266 +0700
@@ -536,8 +536,10 @@
     if (RefPtr scrollingCoordinator = m_scrollingCoordinator)
         scrollingCoordinator->pageDestroyed();
 
+#if ENABLE(RESOURCE_USAGE)
     if (RefPtr resourceUsageOverlay = m_resourceUsageOverlay)
         resourceUsageOverlay->detachFromPage();
+#endif
 
     checkedBackForward()->close();
     if (!isUtilityPage())
@@ -2981,9 +2983,11 @@
         return;
 
     m_shouldSuppressHDR = shouldSuppressHDR;
+    #if ENABLE(VIDEO)
     forEachDocument([](auto& document) {
         document.shouldSuppressHDRDidChange();
     });
+    #endif
 }
 
 #if ENABLE(MEDIA_STREAM)
diff -ruwN source/Source/WebCore/PlatformGTK.cmake source-new/Source/WebCore/PlatformGTK.cmake
--- source/Source/WebCore/PlatformGTK.cmake	2024-12-16 16:07:48.162613200 +0700
+++ source-new/Source/WebCore/PlatformGTK.cmake	2025-09-09 09:08:03.580987266 +0700
@@ -75,21 +75,18 @@
 )
 
 list(APPEND WebCore_LIBRARIES
-    ${ENCHANT_LIBRARIES}
     ${GLIB_GIO_LIBRARIES}
     ${GLIB_GMODULE_LIBRARIES}
     ${GLIB_GOBJECT_LIBRARIES}
     ${GLIB_LIBRARIES}
     ${LIBSECRET_LIBRARIES}
     ${LIBTASN1_LIBRARIES}
-    ${HYPHEN_LIBRARIES}
     ${UPOWERGLIB_LIBRARIES}
     ${X11_X11_LIB}
     GTK::GTK
 )
 
 list(APPEND WebCore_SYSTEM_INCLUDE_DIRECTORIES
-    ${ENCHANT_INCLUDE_DIRS}
     ${GIO_UNIX_INCLUDE_DIRS}
     ${GLIB_INCLUDE_DIRS}
     ${LIBSECRET_INCLUDE_DIRS}
diff -ruwN source/Source/WebKit/Platform/IPC/unix/ConnectionUnix.cpp source-new/Source/WebKit/Platform/IPC/unix/ConnectionUnix.cpp
--- source/Source/WebKit/Platform/IPC/unix/ConnectionUnix.cpp	2025-03-31 16:35:43.461813700 +0700
+++ source-new/Source/WebKit/Platform/IPC/unix/ConnectionUnix.cpp	2025-09-09 09:08:03.591987383 +0700
@@ -48,13 +48,13 @@
 #include <wtf/glib/GUniquePtr.h>
 #endif
 
-#if OS(DARWIN)
+#if OS(DARWIN) || defined(__redox__)
 #define MSG_NOSIGNAL 0
 #endif
 
 // Although it's available on Darwin, SOCK_SEQPACKET seems to work differently
 // than in traditional Unix so fallback to STREAM on that platform.
-#if defined(SOCK_SEQPACKET) && !OS(DARWIN)
+#if defined(SOCK_SEQPACKET) && !OS(DARWIN) && !defined(__redox__)
 #define SOCKET_TYPE SOCK_SEQPACKET
 #else
 #if USE(GLIB)
diff -ruwN source/Source/WebKit/PlatformGTK.cmake source-new/Source/WebKit/PlatformGTK.cmake
--- source/Source/WebKit/PlatformGTK.cmake	2025-03-05 17:09:47.273706000 +0700
+++ source-new/Source/WebKit/PlatformGTK.cmake	2025-09-09 09:08:03.644987947 +0700
@@ -313,7 +313,6 @@
 )
 
 list(APPEND WebKit_SYSTEM_INCLUDE_DIRECTORIES
-    ${ENCHANT_INCLUDE_DIRS}
     ${GIO_UNIX_INCLUDE_DIRS}
     ${GLIB_INCLUDE_DIRS}
     ${GSTREAMER_INCLUDE_DIRS}
diff -ruwN source/Source/WTF/wtf/glib/FileSystemGlib.cpp source-new/Source/WTF/wtf/glib/FileSystemGlib.cpp
--- source/Source/WTF/wtf/glib/FileSystemGlib.cpp	2024-12-16 16:07:48.134613800 +0700
+++ source-new/Source/WTF/wtf/glib/FileSystemGlib.cpp	2025-09-09 09:08:03.644987947 +0700
@@ -70,7 +70,7 @@
     return CString({ readLinkBuffer, static_cast<size_t>(result) });
 WTF_ALLOW_UNSAFE_BUFFER_USAGE_END
 }
-#elif OS(HURD)
+#elif OS(HURD) || defined(__redox__)
 CString currentExecutablePath()
 {
     return { };
diff -ruwN source/Source/WTF/wtf/InlineASM.h source-new/Source/WTF/wtf/InlineASM.h
--- source/Source/WTF/wtf/InlineASM.h	2024-09-23 17:54:44.750106000 +0700
+++ source-new/Source/WTF/wtf/InlineASM.h	2025-09-09 09:08:03.667988192 +0700
@@ -89,7 +89,8 @@
     || OS(HURD)                \
     || OS(NETBSD)              \
     || OS(QNX)                 \
-    || OS(WINDOWS)
+    || OS(WINDOWS)             \
+    || defined(__redox__)
     // GNU as-compatible syntax.
 #define LOCAL_LABEL_STRING(name) ".L" #name
 #endif
diff -ruwN source/Source/WTF/wtf/PlatformEnable.h source-new/Source/WTF/wtf/PlatformEnable.h
--- source/Source/WTF/wtf/PlatformEnable.h	2025-03-18 15:33:00.063181400 +0700
+++ source-new/Source/WTF/wtf/PlatformEnable.h	2026-03-16 10:49:25.498709796 +0700
@@ -698,7 +698,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(HAIKU) || OS(HURD) || OS(WINDOWS))
+#if CPU(X86_64) && (OS(DARWIN) || OS(LINUX) || OS(FREEBSD) || OS(HAIKU) || OS(HURD) || OS(WINDOWS) || defined(__redox__))
 #define ENABLE_DFG_JIT 1
 #endif
 
diff -ruwN source/Source/WTF/wtf/PlatformHave.h source-new/Source/WTF/wtf/PlatformHave.h
--- source/Source/WTF/wtf/PlatformHave.h	2025-04-02 19:09:45.800669000 +0700
+++ source-new/Source/WTF/wtf/PlatformHave.h	2025-09-09 09:08:03.707988617 +0700
@@ -231,7 +231,7 @@
 #define HAVE_MACH_MEMORY_ENTRY 1
 #endif
 
-#if OS(DARWIN) || OS(FUCHSIA) || ((OS(FREEBSD) || OS(HAIKU) || OS(NETBSD) || OS(OPENBSD) || OS(LINUX) || OS(HURD) || OS(QNX)) && (CPU(X86_64) || CPU(ARM) || CPU(ARM64) || CPU(RISCV64)))
+#if OS(DARWIN) || OS(FUCHSIA) || ((OS(FREEBSD) || OS(HAIKU) || OS(NETBSD) || OS(OPENBSD) || OS(LINUX) || OS(HURD) || OS(QNX) || defined(__redox__)) && (CPU(X86_64) || CPU(ARM) || CPU(ARM64) || CPU(RISCV64)))
 #define HAVE_MACHINE_CONTEXT 1
 #endif
 
diff -ruwN source/Source/WTF/wtf/PlatformOS.h source-new/Source/WTF/wtf/PlatformOS.h
--- source/Source/WTF/wtf/PlatformOS.h	2025-04-03 12:49:09.282701700 +0700
+++ source-new/Source/WTF/wtf/PlatformOS.h	2025-09-09 09:08:03.709988639 +0700
@@ -143,7 +143,8 @@
     || OS(OPENBSD)          \
     || defined(unix)        \
     || defined(__unix)      \
-    || defined(__unix__)
+    || defined(__unix__)    \
+    || defined(__redox__)
 #define WTF_OS_UNIX 1
 #endif
 
diff -ruwN source/Source/WTF/wtf/PlatformRegisters.h source-new/Source/WTF/wtf/PlatformRegisters.h
--- source/Source/WTF/wtf/PlatformRegisters.h	2024-11-20 20:56:01.847236400 +0700
+++ source-new/Source/WTF/wtf/PlatformRegisters.h	2025-09-09 09:08:03.723988787 +0700
@@ -39,6 +39,8 @@
 typedef ucontext_t mcontext_t;
 #elif OS(QNX)
 #include <ucontext.h>
+#elif defined(__redox__)
+#include <signal.h>
 #else
 #include <sys/ucontext.h>
 #endif
diff -ruwN source/Source/WTF/wtf/posix/CPUTimePOSIX.cpp source-new/Source/WTF/wtf/posix/CPUTimePOSIX.cpp
--- source/Source/WTF/wtf/posix/CPUTimePOSIX.cpp	2023-09-18 14:56:45.363115500 +0700
+++ source-new/Source/WTF/wtf/posix/CPUTimePOSIX.cpp	2025-09-09 09:08:03.727988830 +0700
@@ -47,10 +47,14 @@
 
 Seconds CPUTime::forCurrentThread()
 {
+#if defined(__redox__)
+    return Seconds(0);
+#else
     struct timespec ts { };
     int ret = clock_gettime(CLOCK_THREAD_CPUTIME_ID, &ts);
     RELEASE_ASSERT(!ret);
     return Seconds(ts.tv_sec) + Seconds::fromNanoseconds(ts.tv_nsec);
+#endif
 }
 
 }
diff -ruwN source/Source/WTF/wtf/posix/FileHandlePOSIX.cpp source-new/Source/WTF/wtf/posix/FileHandlePOSIX.cpp
--- source/Source/WTF/wtf/posix/FileHandlePOSIX.cpp	2025-03-21 18:07:10.828055100 +0700
+++ source-new/Source/WTF/wtf/posix/FileHandlePOSIX.cpp	2025-09-09 09:08:03.757989149 +0700
@@ -39,6 +39,10 @@
 #include <wtf/MallocSpan.h>
 #include <wtf/MappedFileData.h>
 
+#if defined(__redox__)
+#define MAP_FILE 0
+#endif
+
 namespace WTF::FileSystemImpl {
 
 std::optional<uint64_t> FileHandle::read(std::span<uint8_t> data)
diff -ruwN source/Source/WTF/wtf/posix/ThreadingPOSIX.cpp source-new/Source/WTF/wtf/posix/ThreadingPOSIX.cpp
--- source/Source/WTF/wtf/posix/ThreadingPOSIX.cpp	2025-03-05 17:09:47.149706400 +0700
+++ source-new/Source/WTF/wtf/posix/ThreadingPOSIX.cpp	2025-09-09 09:08:03.762989203 +0700
@@ -356,7 +356,7 @@
 
 void Thread::changePriority(int delta)
 {
-#if HAVE(PTHREAD_SETSCHEDPARAM)
+#if HAVE(PTHREAD_SETSCHEDPARAM) && !defined(__redox__)
     Locker locker { m_mutex };
 
     int policy;
