Plan directeur 14 phases / 5 ans (REDOX_COSMIC_XWAYLAND_RS_PLAN.md).
Phase 1 — Audit Redox (docs/existing-redox-gui.md, 486 lignes) :
- Orbital, graphics-ipc (API DRM compatible Linux subset KMS), inputd, vesad
- relibc support : AF_UNIX, SCM_RIGHTS, shm_open, mmap, poll
- 3 manques identifiés : memfd_create, keymap XKB, AT-SPI
Phase 2 — Validation primitives sur Redox via redoxer (5 tests + 1 POC) :
- test-unix-socket : SOCK_STREAM Wayland-shaped roundtrip
- test-fd-passing : SCM_RIGHTS mono-process (artefact kernel)
- test-fd-passing-fork : SCM_RIGHTS multi-process (validation Wayland critique)
- test-shm-open : shm_open + mmap + persistance + unlink
- test-poll-multifd : poll() multiplexing + POLLHUP
- poc-pixels : datapath shm + SCM_RIGHTS bout en bout (10000 pixels ARGB)
Phase 3 — wayland-rs sur Redox (compile + runtime) :
- wayland-{scanner,backend,server,client} compilent pour x86_64-unknown-redox
sans patch upstream (rustix supporte Redox via libc backend)
- test-handshake : server/client wl_registry handshake roundtrip
- test-shm-pipeline : pipeline complet (ListeningSocket Unix réel + fd passing
via wl_shm.create_pool + wl_shm_pool + wl_buffer + wl_surface + commit +
serveur lit pixels via fd reçu, validation pixel-perfect)
Verdict phase 3 : wayland-rs upstream est viable sur Redox out-of-the-box,
le port "Wayland sur Redox" est désormais un problème de compositor à écrire,
pas de stack à porter.
Prérequis build : redoxer (pas cargo direct, car CMSG_NXTHDR/CMSG_DATA
ne sont pas linkés autrement vers librelibc.a).
Leyoda 2026 – GPLv3
3.2 KiB
redox-wayland-compositor
Portage de Wayland sur Redox OS, en Rust pur, visant à terme à remplacer Orbital comme serveur graphique de base.
État : phases 1+2+3 du plan directeur complétées le 2026-05-08.
Le pipeline shm Wayland complet est validé end-to-end sur Redox via redoxer
(crate redox-wl-test-shm-pipeline) : socket Unix réel, wl_compositor +
wl_shm globals, fd passing via SCM_RIGHTS, wl_shm_pool + wl_buffer,
wl_surface.attach/damage/commit, lecture pixels côté serveur via le
fd reçu — pixel-perfect.
Structure
.
├── REDOX_COSMIC_XWAYLAND_RS_PLAN.md # plan directeur 14 phases / 5 ans
├── docs/
│ ├── existing-redox-gui.md # phase 1 : audit Orbital + graphics-ipc + inputd + relibc
│ └── redox-wayland-primitives.md # phase 2 : 5 primitives + POC pixels validés sur Redox
├── crates/
│ ├── redox-wl-test-unix-socket/ # primitive 1 : SOCK_STREAM Wayland-shaped
│ ├── redox-wl-test-fd-passing/ # primitive 2 : SCM_RIGHTS mono-process (artefact)
│ ├── redox-wl-test-fd-passing-fork/ # primitive 2b : SCM_RIGHTS via fork (vrai cas Wayland)
│ ├── redox-wl-test-shm-open/ # primitive 3 : shm_open + mmap MAP_SHARED
│ ├── redox-wl-test-poll-multifd/ # primitive 4 : poll() multiplexing + POLLHUP
│ ├── redox-wl-poc-pixels/ # POC : datapath shm + SCM_RIGHTS bout en bout
│ ├── redox-wl-test-handshake/ # phase 3 : wayland-rs server/client registry
│ └── redox-wl-test-shm-pipeline/ # phase 3 : pipeline shm complet validé
└── (pas de Cargo.toml racine : chaque crate est standalone — voir note ci-dessous)
Note structure : pas de workspace Cargo racine. Chaque crate dans
crates/est autonome avec son propreCargo.tomlet son propretarget/lors de la build. Raison :redoxer build/redoxer runcherche le binaire dans<crate>/target/...et n'arrive pas à le retrouver si letarget/est centralisé au niveau workspace. Ce sera repensé quand on aura un compositor unique vs plusieurs binaires de tests.
Prérequis
- Rust nightly (récent — testé 2026-05-07)
- Target installé :
rustup target add x86_64-unknown-redox --toolchain nightly cargo install redoxerpuisredoxer install(sysroot Redox ~456 Mo)- Repo upstream
Smithay/wayland-rscloné en../wayland-rs/(paths relatifs depuiscrates/*/Cargo.toml)
Reproduire les tests
Chaque crate s'exécute via redoxer (mini-VM Redox sous QEMU) :
cd crates/redox-wl-test-shm-pipeline
redoxer run --release
Pattern attendu en fin d'exécution : [test-XX] PASS: ....
Important : utiliser
redoxer buildouredoxer run, pascargo build --target=x86_64-unknown-redoxdirect qui fait un fail au link (undefined reference CMSG_NXTHDR/CMSG_DATA) parce que le linker host ne sait pas chaîner librelibc.a du sysroot Redox.redoxerconfigure le linker correctement.
Roadmap
Voir REDOX_COSMIC_XWAYLAND_RS_PLAN.md pour le plan complet 14 phases / 5 ans.
Prochaine étape : phase 4 — display backend Redox via graphics-ipc::V2GraphicsHandle.
Licence
Leyoda 2026 — GPLv3+