Port pipewire's Linux-isms to Redox (baked into vendored source/):
- mem.c: add __redox__ to the BSD/GNU guard that #defines MAP_LOCKED 0 (Redox
has no page-locking; the flag is a no-op).
- pipewire.c: guard #include <sys/prctl.h> and the prctl(PR_GET_NAME) thread-
name block for __redox__ (Redox has no prctl; thread naming is skipped).
alloca resolved on a clean cook (-include alloca.h + staged relibc alloca.h).
qtmultimedia: drop qtdeclarative dep (its staged QtQuick scenegraph config
header made QT_CONFIG(quick_sprite) divide by zero for consumers); keep
qtshadertools (video-frame shaders need qt_internal_add_shaders). Builds
libQt6Multimedia (API-only). konsole: drop the 439-line optional-multimedia
workaround patch and depend on qtmultimedia + qt5compat + qtbase-printsupport
directly — port the modules, don't work around them.
Per the no-workarounds policy, provide the Qt modules KDE needs instead of
patching KDE to avoid them:
- qt5compat (Core5Compat): promoted from recipes/wip, re-laid to 6.11.1
(matches the rest of Qt); no Redox source port needed. Unblocks 8 KDE pkgs.
- qtmultimedia: new recipe at 6.11.1, built API-only (all platform backends
off: ffmpeg/gstreamer/pulseaudio/alsa/pipewire/v4l2) so libQt6Multimedia
links for consumers (konsole bell); playback is a no-op until a Redox audio
backend exists.
- libclc: convert git= -> path=source (it was fully vendored; a fresh fetch
broke on the removed .git). Overlay symlinks added for both new qt modules.
Qt6PrintSupport ships inside qtbase (src/printsupport) — it was disabled, not
missing. konsole and 8 KDE packages (kxmlgui, kwin, plasma-desktop, ...) need
Qt6::PrintSupport; enable it rather than working around its absence.
Per the no-deferred-versions policy, bring every stale KDE recipe up to the
version its recipe declares (source/, source.tar, blake3, stamp all aligned):
- kf6-kiconthemes, kf6-kded6 -> 6.28.0 pristine (their old Redox shims are
obsolete: the guarded code was removed/refactored upstream)
- kirigami -> 6.28.0 (01-initial-migration baked; 02-qnetwork obsolete — 6.28
already uses a real QNetworkAccessManager in icon.cpp)
- breeze, kde-cli-tools -> 6.7.2 pristine (no Redox port)
- kf6-kservice -> 6.28.0 (QSharedMemory: relibc now has posix sems; verify at build)
- konsole -> 26.04.3 (multimedia/printsupport-optional port still required —
RedBear has no qtmultimedia; patch regeneration tracked as follow-up)
Codify in local/AGENTS.md: every package in a config builds from source/ at the
declared latest version; no stale source/, no mixed versions within a stack, no
commenting a package out of a config to make the build pass. When the auto-rebase
engine rejects a package, re-port it by hand to the new version — never freeze it
at the old one. A deferred old version or excluded package is a build failure to
fix, not a state to ship.
kf6-kcoreaddons 6.28.0 requires ECM >= 6.28.0 but the vendored ECM source/ was
still 6.10.0: the sync engine skipped it because ECM's version marker is a bare
set(VERSION "X.Y.Z") that the parser didn't recognize (only KF_VERSION /
PROJECT_VERSION / RELEASE_SERVICE_VERSION). Re-lay ECM from its 6.28.0 source.tar
(pure cmake modules, no Redox port) and teach both the sync engine and the
validator to read set(VERSION) so this class is caught, not silently skipped.
git links -lintl (libintl, from gettext) for i18n but never declared gettext as
a build dependency — it was implicitly relying on libintl.a already being in the
shared prefix sysroot from another package. When the relibc/kernel-touched boot-
ABI relink cleaned the sysroot, git's own sysroot lacked libintl and the link
failed. Declare the dependency so libintl.a is staged into git's sysroot.
486a7818 'Fix poll hang in os-test basic/poll': the fork still had
unregister_queue as a //TODO stub, so closed event queues leaked their registry
entries (the poll-hang class). Merged with RedBear's ref-counted queue-close
logic: keep the kdup dec_ref/is_last handling, and call unregister_queue(id,
token) to clean the registry when the last fd closes. Event-timeout handling was
already present as RedBear's own impl.
Pull genuinely-new upstream Redox fixes that apply cleanly onto the fork (the
poll-timeout crash fix was already present as RedBear's own tested impl):
- 72c0078d Fix ld.so PLT relocations by relocating lazily before is_me check
(relevant to RedBear's ld.so panic class)
- f8ef2864 Fix connect for Unix sockets outside the rootfs (UDS robustness)
- 8965d7fc Fix an unwind-safety issue in openat
The PipeWire audio stack needs more Redox porting (alloca via meson, MAP_LOCKED
and other Linux mmap/ioctl-isms across many files). Audio is not required for the
SDDM login or the desktop session, so defer both to reach the login milestone;
re-add once the audio port is complete. Baked patches + recipes stay in the tree.
pipewire uses alloca() in 41 source files without including <alloca.h> (glibc
declares it via stdlib.h; relibc does not), so cross-compiling hit -Werror=
implicit-function-declaration on conf.c:356. relibc provides <alloca.h> — add
-include alloca.h to CFLAGS so every TU gets the declaration.
These four recipes applied their local/patches/ at build time via
cookbook_apply_patches — a helper that is NOT defined in the cook environment
('command not found', aborting the build on pipewire). Per the full-fork vendored
model, bake each recipe's patches into its committed source/ (redox compat shims,
qnetwork impl, kf6 migration) and remove the broken call. The .patch files stay
tracked in local/patches/ for version-bump re-derivation.
Three fixes to build sddm on Redox (Wayland-only, Qt6):
- KeyboardModel.cpp: guard the XcbKeyboardBackend include + its runtime branch
with #ifndef __redox__ (platformName is never 'xcb' on Redox, but the dead
branch still pulled in <xcb/xkb.h> -> fatal error). Wayland backend kept.
- XAuth.h: declare ~XAuth() (the recipe's XAuth.cpp defines it, but the header
only declared the ctor -> 'definition of implicitly-declared destructor').
- wayland-patch.sh XAuth.cpp heredoc: add <QFileInfo> + <QRandomGenerator>
includes and replace Qt5 qrand() with QRandomGenerator (removed in Qt6).
Converting [source] git=/tar= to path="source" removed the URL cookbook parsed
the package version from, so non-Cargo recipes without an explicit
[package].version failed at packaging ('cannot guess version', hit on
ninja-build). Add version = "0.3.1" (the branch version, matching the vendored
convention e.g. brush) to the 3 affected recipes, and make vendor-recipe.sh add
it automatically on future conversions.
verify-patch-sanity.py validates every active recipe .patch has internally-
consistent hunk line counts — catching the 'malformed patch at line N' failure
at commit/CI/preflight time instead of hours into a cook. This cycle hit that
class three times (qtwaylandscanner, sddm, xwayland), each only discovered when
cookbook tried to apply the patch.
Running it across the repo found 29 latent malformed patches (validated against
GNU patch: e.g. relibc/P3-sysv-ipc reproduces 'malformed patch at line 22').
They were harmless only because they sit in vendored recipes (baked, not re-
applied) — but would fail on any version-bump re-derivation. --fix recounts the
hunk headers (body untouched) and repaired all 29.
Wired into build-preflight.sh (Phase 1.0D) and redbear-ci.yml, with a unit test
(test-patch-sanity.sh). Skips archived/legacy trees and unvalidatable formats
(empty placeholders, bare-@@ git hunks).
qt6-sensors provides Qt6::Sensors (needed by KWin) but its source/ (436 files)
was only present on disk, never git-tracked — not reproducible. Commit it as a
proper vendored tree for the full-fork build.
Root cause of the recurring line-duplication corruption (duplicate #include
<sys/ioctl.h>, nested #if QT_CONFIG(opengl), duplicate assert.h): several of the
recipe's in-place source-munging steps were NOT guarded, so on a committed
(vendored) source/ they re-applied every cook and accumulated. Guard the four
unguarded ones (qwaylandclientbufferintegration opengl-wrap, qnet_unix ioctl
include, corelib CMakeLists REDOX storageinfo block) with grep/marker checks so
re-running on an already-patched tree is a no-op. The rest were already guarded
or naturally idempotent (text.replace consuming its needle).
vendor-recipe.sh converts a transient recipe to the vendored full-fork model
(repo fetch -> strip .git -> [source] path=source with provenance comment ->
un-ignore -> stamp). Used to vendor 23 of the 26 transients. xwayland deferred
(corrupt redox.patch needs regeneration; X11-compat, not login-critical);
smallvil + seatd-redox not in the full set.
Convert the transient git-fetch sddm recipe to the vendored model: commit the
source/ tree (pristine sddm @63780fcd + the two Redox patches baked in), switch
[source] to path="source" so the build never reaches github at cook time, and
keep the .patch files tracked for re-application on a version bump. Also fixes
the malformed redox-helper-utmpx-stub.patch (wrong hunk line-counts -> 'malformed
patch at line 24') by regenerating it with correct headers. First of the 26
transient recipes being vendored for an offline, reproducible full-fork build.
Proves build-redbear.sh's vendored source/ staleness loop: seeds on first sight
(no spurious rebuild), stays quiet unchanged, and invalidates target/ on
committed/uncommitted/untracked source/ changes. Keeps the loop body in sync.
The staleness gap behind the qtshadertools failure: cookbook keys its build
cache on the source.tar hash, but the actual build input for a vendored recipe
is the git-committed source/ tree. A version bump that propagates into source/
without changing source.tar (Qt's source.tar was already 6.11.1 while source/
was a 6.11.0 muddle) leaves cookbook reusing a stale stage — the desktop then
builds the old version. New loop fingerprints each vendored source/ by its git
tree hash (+ dirty flag) and rm's target/ on change; first observation only
seeds the fingerprint so it never forces a spurious full rebuild.
The 6 Plasma modules (breeze/kdecoration/kf6-kwayland/kglobalacceld/kwin) and
konsole were 'no-marker(skip)' because src_version/the validator only knew KF's
KF_VERSION. Now both also read set(PROJECT_VERSION) (Plasma) and the split
RELEASE_SERVICE_VERSION_MAJOR/MINOR/MICRO (KDE Gear), so these vendored modules
are version-checked and rebasable. Test E23.