diff --git a/config/wayland.toml b/config/wayland.toml index 98bca601c6..0c4d5d87d0 100644 --- a/config/wayland.toml +++ b/config/wayland.toml @@ -211,7 +211,7 @@ wait_for_wayland_socket() { if [ -e "$socket_path" ]; then return 0 fi - if ! kill -0 "$kwin_pid" 2>/scheme/null; then + if ! kill -0 "$compositor_pid" 2>/scheme/null; then return 1 fi attempts=$((attempts + 1)) @@ -245,11 +245,14 @@ if [ -z "${KWIN_DRM_DEVICES:-}" ] && [ -e /scheme/drm/card0 ]; then export KWIN_DRM_DEVICES=/scheme/drm/card0 fi +# Bootstrap compositor: redbear-compositor provides a bounded Wayland +# surface (DRM/KMS + core protocols) until KWin completes its build. +# When KWin is ready, replace with: kwin_wayland --drm & redbear-compositor --drm & -kwin_pid=$! +compositor_pid=$! if ! wait_for_wayland_socket; then - echo "kwin_wayland failed to expose $XDG_RUNTIME_DIR/$WAYLAND_DISPLAY" >&2 + echo "Wayland compositor failed to expose $XDG_RUNTIME_DIR/$WAYLAND_DISPLAY" >&2 exit 1 fi