diff --git a/local/recipes/dev/meson/source.tar b/local/recipes/dev/meson/source.tar index 7fc2a73b5a..41ee8362df 100644 Binary files a/local/recipes/dev/meson/source.tar and b/local/recipes/dev/meson/source.tar differ diff --git a/local/recipes/kde/kf6-extra-cmake-modules/source.tar b/local/recipes/kde/kf6-extra-cmake-modules/source.tar index b1b62e1323..c599929aca 100644 Binary files a/local/recipes/kde/kf6-extra-cmake-modules/source.tar and b/local/recipes/kde/kf6-extra-cmake-modules/source.tar differ diff --git a/local/recipes/libs/cairo/recipe.toml b/local/recipes/libs/cairo/recipe.toml new file mode 100644 index 0000000000..47b1d5ebdb --- /dev/null +++ b/local/recipes/libs/cairo/recipe.toml @@ -0,0 +1,35 @@ +[source] +tar = "https://www.cairographics.org/releases/cairo-1.18.4.tar.xz" +blake3 = "b9fa14e02f85ec4e72396c62236c98502d04dbbdf8daf01ab9557a1c7aa7106e" +patches = ["redox.patch"] + +[build] +dependencies = [ + "expat", + "freetype2", + "fontconfig", + "gettext", + "glib", + "libffi", + "libiconv", + "libpng", + "libpthread-stubs", + "libx11", + "libxau", + "libxcb", + "libxext", + "pcre2", + "pixman", + "x11proto", + "zlib", +] +template = "custom" +script = """ +DYNAMIC_INIT +#TODO: fix mutex implementation +#TODO: why are math defines missing? +CFLAGS="${CFLAGS} -DCAIRO_NO_MUTEX=1 -DM_SQRT2=1.41421356237309504880 -DM_LN2=0.69314718055994530942" +cookbook_meson \ + -Dxlib-xcb=enabled \ + -Dtests=disabled +""" diff --git a/local/recipes/libs/cairo/redox.patch b/local/recipes/libs/cairo/redox.patch new file mode 100644 index 0000000000..110b39a1e5 --- /dev/null +++ b/local/recipes/libs/cairo/redox.patch @@ -0,0 +1,50 @@ +diff -ruwN cairo-1.18.4/meson.build source/meson.build +--- cairo-1.18.4/meson.build 2025-03-08 05:35:35.000000000 -0700 ++++ source/meson.build 2025-05-04 18:07:04.594213814 -0600 +@@ -440,13 +440,13 @@ + if feature_conf.get('CAIRO_HAS_XCB_SURFACE', 0) == 1 + xcbshm_dep = dependency('xcb-shm', required: get_option('xcb')) + if xcbshm_dep.found() +- feature_conf.set('CAIRO_HAS_XCB_SHM_FUNCTIONS', 1) +- deps += [xcbshm_dep] +- built_features += [{ +- 'name': 'cairo-xcb-shm', +- 'description': 'XCB/SHM functions', +- 'deps': [xcbshm_dep], +- }] ++ #feature_conf.set('CAIRO_HAS_XCB_SHM_FUNCTIONS', 1) ++ #deps += [xcbshm_dep] ++ #built_features += [{ ++ # 'name': 'cairo-xcb-shm', ++ # 'description': 'XCB/SHM functions', ++ # 'deps': [xcbshm_dep], ++ #}] + endif + endif + +diff -ruwN cairo-1.18.4/perf/Makefile.in source/perf/Makefile.in +--- cairo-1.18.4/perf/Makefile.in 1969-12-31 17:00:00.000000000 -0700 ++++ source/perf/Makefile.in 2025-05-01 12:52:11.400963345 -0600 +@@ -0,0 +1,3 @@ ++all: ++ ++install: +diff -ruwN cairo-1.18.4/src/cairo-ps-surface.c source/src/cairo-ps-surface.c +--- cairo-1.18.4/src/cairo-ps-surface.c 2025-03-08 05:35:35.000000000 -0700 ++++ source/src/cairo-ps-surface.c 2025-05-04 18:08:43.821264417 -0600 +@@ -102,7 +102,7 @@ + #define DEBUG_FALLBACK(s) + #endif + +-#ifndef HAVE_CTIME_R ++#if !defined(HAVE_CTIME_R) && !defined(__redox__) + static char *ctime_r(const time_t *timep, char *buf) + { + (void)buf; +diff -ruwN cairo-1.18.4/test/Makefile.in source/test/Makefile.in +--- cairo-1.18.4/test/Makefile.in 1969-12-31 17:00:00.000000000 -0700 ++++ source/test/Makefile.in 2025-05-01 12:52:11.400963345 -0600 +@@ -0,0 +1,3 @@ ++all: ++ ++install: diff --git a/local/recipes/libs/freetype2/source.tar b/local/recipes/libs/freetype2/source.tar index 4e2d0d4285..41454b739f 100644 Binary files a/local/recipes/libs/freetype2/source.tar and b/local/recipes/libs/freetype2/source.tar differ diff --git a/local/recipes/libs/glib/source.tar b/local/recipes/libs/glib/source.tar index 0c97a7f32f..5bb0d2b958 100644 Binary files a/local/recipes/libs/glib/source.tar and b/local/recipes/libs/glib/source.tar differ diff --git a/local/recipes/libs/libxkbcommon/source.tar b/local/recipes/libs/libxkbcommon/source.tar index eba0a5d717..9d6a127871 100644 Binary files a/local/recipes/libs/libxkbcommon/source.tar and b/local/recipes/libs/libxkbcommon/source.tar differ diff --git a/local/recipes/libs/mesa/source.tar b/local/recipes/libs/mesa/source.tar new file mode 100644 index 0000000000..4dc1cdaff4 Binary files /dev/null and b/local/recipes/libs/mesa/source.tar differ diff --git a/local/recipes/libs/pango/redox.patch b/local/recipes/libs/pango/redox.patch new file mode 100644 index 0000000000..d04c9538d5 --- /dev/null +++ b/local/recipes/libs/pango/redox.patch @@ -0,0 +1,14 @@ +diff -ruwN pango-1.56.3/meson.build source/meson.build +--- pango-1.56.3/meson.build 2025-03-16 05:45:47.000000000 -0600 ++++ source/meson.build 2025-05-01 13:51:05.834742120 -0600 +@@ -551,8 +551,8 @@ + pango_inc = include_directories('pango') + + subdir('pango') +-subdir('utils') +-subdir('tools') ++#TODO: fails to build on Redox: subdir('utils') ++#TODO: fails to build on Redox: subdir('tools') + subdir('docs') + if get_option('build-testsuite') + subdir('tests') diff --git a/local/scripts/verify-absorbed-patches.sh b/local/scripts/verify-absorbed-patches.sh new file mode 100755 index 0000000000..94c1e9ea45 --- /dev/null +++ b/local/scripts/verify-absorbed-patches.sh @@ -0,0 +1,94 @@ +#!/bin/bash +# verify-absorbed-patches.sh — verify which local/patches/relibc/absorbed/ patches +# have their changes present in local/sources/relibc source. +# +# Strategy: hardlink-copy relibc source into tmp, then test each patch. +# Use hardlinks so the relibc working tree is not mutated and the copy +# is fast (no full 4.5G copy). + +set -euo pipefail + +ROOT="$(cd "$(dirname "$0")/../.." && pwd)" +ABSORBED_DIR="$ROOT/local/patches/relibc/absorbed" +RELIBC_DIR="$ROOT/local/sources/relibc" + +if [ ! -d "$ABSORBED_DIR" ]; then + echo "ERROR: $ABSORBED_DIR not found"; exit 1 +fi +if [ ! -d "$RELIBC_DIR" ]; then + echo "ERROR: $RELIBC_DIR not found"; exit 1 +fi + +TMPDIR="$(mktemp -d -t rb-absorbed-check.XXXXXX)" +mkdir -p "$TMPDIR/src" + +# Hardlink-copy with .git excluded (avoid cross-device hardlink failures) +rsync -a --exclude='.git' "$RELIBC_DIR"/ "$TMPDIR/src/" +cd "$TMPDIR/src" + +OK_COUNT=0 +GONE_COUNT=0 +FAIL_COUNT=0 +declare -a GONE_PATCHES=() +declare -a FAIL_PATCHES=() + +for patch in "$ABSORBED_DIR"/*.patch; do + [ -e "$patch" ] || continue + name="$(basename "$patch")" + + # Try dry-run apply first (-N = no backup, --dry-run = test only). + if patch --dry-run -p1 -N -i "$patch" >/dev/null 2>&1; then + # Forward applies. Now test reverse — if reverse applies, the + # content is currently present (STILL-EFFECTIVE); if reverse fails, + # the content was merged upstream (MERGED-UPSTREAM). + if patch --dry-run -p1 -R -N -i "$patch" >/dev/null 2>&1; then + OK_COUNT=$((OK_COUNT+1)); status="STILL-EFFECTIVE" + else + OK_COUNT=$((OK_COUNT+1)); status="MERGED-UPSTREAM" + fi + # Restore source by removing the forward-applied hunks via reverse. + patch -p1 -R -N -i "$patch" >/dev/null 2>&1 || true + else + # Forward dry-run fails. Test real apply; if successful, the content + # was missing and the patch is now applied. + if patch -p1 -N -i "$patch" >/dev/null 2>&1; then + GONE_COUNT=$((GONE_COUNT+1)); status="APPLIED-NEW" + GONE_PATCHES+=("$name") + # Restore source for next patch. + patch -p1 -R -N -i "$patch" >/dev/null 2>&1 || true + else + FAIL_COUNT=$((FAIL_COUNT+1)); status="BROKEN" + FAIL_PATCHES+=("$name") + fi + fi + + printf '%-45s %s\n' "$name" "$status" +done + +echo "" +echo "==========================================" +echo " ABSORBED-PATCH AUDIT SUMMARY" +echo "==========================================" +echo "Effective or merged: $OK_COUNT" +echo "APPLIED-NEW (was missing): $GONE_COUNT" +echo "Broken (cannot apply): $FAIL_COUNT" +echo "" + +if [ ${#GONE_PATCHES[@]} -gt 0 ]; then + echo "Patches now applicable (likely needed):" + for p in "${GONE_PATCHES[@]}"; do echo " - $p"; done + echo "" +fi + +if [ ${#FAIL_PATCHES[@]} -gt 0 ]; then + echo "Broken patches:" + for p in "${FAIL_PATCHES[@]}"; do echo " - $p"; done + echo "" +fi + +rm -rf "$TMPDIR" + +if [ $FAIL_COUNT -gt 0 ]; then + exit 1 +fi +exit 0 diff --git a/local/sources/base b/local/sources/base index aedc416f0c..75f6cf902d 160000 --- a/local/sources/base +++ b/local/sources/base @@ -1 +1 @@ -Subproject commit aedc416f0c96fdfdc5941b5d5104a8ad78744df4 +Subproject commit 75f6cf902def9bc394a6738213bf1b34d9874fc9 diff --git a/local/sources/bootloader b/local/sources/bootloader index 902fecd48e..3d41cf72ba 160000 --- a/local/sources/bootloader +++ b/local/sources/bootloader @@ -1 +1 @@ -Subproject commit 902fecd48e49b06be92b37d55f38e2544d0785e5 +Subproject commit 3d41cf72ba650d3c9cd4a0c6f310355dc323dd83 diff --git a/local/sources/installer b/local/sources/installer index a1bc3ff0f4..04f80ba395 160000 --- a/local/sources/installer +++ b/local/sources/installer @@ -1 +1 @@ -Subproject commit a1bc3ff0f40007abecc340e584075858da80da2a +Subproject commit 04f80ba3950bb13c8f0f758b7a132224a735353a diff --git a/local/sources/relibc b/local/sources/relibc index af769016b4..d60ba8730d 160000 --- a/local/sources/relibc +++ b/local/sources/relibc @@ -1 +1 @@ -Subproject commit af769016b4cb85d9b096e373fdfaeaf1cfd2516f +Subproject commit d60ba8730dd4bbeb83a9da10cd166592e5301052