From 41556c5c4e404fe2ffdf56f940e460a16484e4b0 Mon Sep 17 00:00:00 2001 From: Vasilito Date: Fri, 17 Apr 2026 13:34:28 +0100 Subject: [PATCH] Update build configs for D-Bus and service integration Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus --- config/redbear-desktop.toml | 3 ++ config/redbear-full.toml | 85 +++++++++++++++++++++++++++++- config/redbear-kde.toml | 100 +++++++++++++++++++++++++++++++++++- config/redbear-live.toml | 5 ++ config/redbear-minimal.toml | 5 +- 5 files changed, 192 insertions(+), 6 deletions(-) diff --git a/config/redbear-desktop.toml b/config/redbear-desktop.toml index 99450530..e87a4eb9 100644 --- a/config/redbear-desktop.toml +++ b/config/redbear-desktop.toml @@ -47,6 +47,9 @@ mc = {} # Package builder (cub -S/-B/-G CLI) cub = {} +# Core Red Bear umbrella package +redbear-meta = {} + # ── Desktop services (replace legacy desktop-minimal init scripts) ─────────── diff --git a/config/redbear-full.toml b/config/redbear-full.toml index 0c62248a..436db851 100644 --- a/config/redbear-full.toml +++ b/config/redbear-full.toml @@ -38,6 +38,9 @@ redbear-traceroute = {} redbear-mtr = {} redbear-nmap = {} +# Package builder / recipe utility +cub = {} + # Terminal file manager (Midnight Commander port) mc = {} @@ -55,6 +58,12 @@ udev-shim = {} # Desktop/session plumbing dbus = {} +redbear-sessiond = {} +redbear-dbus-services = {} +redbear-notifications = {} +redbear-upower = {} +redbear-udisks = {} +redbear-polkit = {} # Diagnostic tool redbear-info = {} @@ -74,8 +83,8 @@ libxkbcommon = {} # Qt6 base (Core+Concurrent+Xml+Gui+Widgets, software rendering) qtbase = {} -# RBOS meta-package — temporarily disabled (depends on GPU stack via redox-driver-sys) -# redbear-meta = {} +# Core Red Bear umbrella package +redbear-meta = {} # Firmware directory for AMD/Intel GPU blobs [[files]] @@ -169,6 +178,78 @@ args = [ type = "oneshot_async" """ +[[files]] +path = "/usr/lib/init.d/13_redbear-sessiond.service" +data = """ +[unit] +description = "Red Bear session broker (org.freedesktop.login1)" +requires_weak = [ + "12_dbus.service", +] + +[service] +cmd = "ion" +args = [ + "-c", + "sleep 5; redbear-sessiond", +] +type = "oneshot_async" +""" + +[[files]] +path = "/usr/lib/init.d/14_redbear-upower.service" +data = """ +[unit] +description = "UPower D-Bus service (org.freedesktop.UPower)" +requires_weak = [ + "12_dbus.service", +] + +[service] +cmd = "ion" +args = [ + "-c", + "sleep 5; redbear-upower", +] +type = "oneshot_async" +""" + +[[files]] +path = "/usr/lib/init.d/14_redbear-udisks.service" +data = """ +[unit] +description = "UDisks2 D-Bus service (org.freedesktop.UDisks2)" +requires_weak = [ + "12_dbus.service", +] + +[service] +cmd = "ion" +args = [ + "-c", + "sleep 5; redbear-udisks", +] +type = "oneshot_async" +""" + +[[files]] +path = "/usr/lib/init.d/14_redbear-polkit.service" +data = """ +[unit] +description = "PolicyKit1 D-Bus service (org.freedesktop.PolicyKit1)" +requires_weak = [ + "12_dbus.service", +] + +[service] +cmd = "ion" +args = [ + "-c", + "sleep 5; redbear-polkit", +] +type = "oneshot_async" +""" + [[files]] path = "/var/lib/dbus" data = "" diff --git a/config/redbear-kde.toml b/config/redbear-kde.toml index 225e6ddc..35f2a1cd 100644 --- a/config/redbear-kde.toml +++ b/config/redbear-kde.toml @@ -36,6 +36,12 @@ udev-shim = {} # D-Bus (session + system bus) dbus = {} +redbear-sessiond = {} +redbear-dbus-services = {} +redbear-notifications = {} +redbear-upower = {} +redbear-udisks = {} +redbear-polkit = {} # Diagnostic/runtime tooling redbear-info = {} @@ -115,8 +121,11 @@ requires_weak = [ ] [service] -cmd = "dbus-daemon" -args = ["--system"] +cmd = "ion" +args = [ + "-c", + "mkdir -p /var/lib/dbus /run/dbus; rm -f /run/dbus/pid; dbus-uuidgen --ensure; dbus-daemon --system", +] type = "oneshot_async" """ @@ -139,6 +148,7 @@ data = """ description = "seatd seat management daemon" requires_weak = [ "12_dbus.service", + "13_redbear-sessiond.service", ] [service] @@ -147,6 +157,78 @@ args = ["-l", "info"] type = "oneshot_async" """ +[[files]] +path = "/usr/lib/init.d/13_redbear-sessiond.service" +data = """ +[unit] +description = "Red Bear session broker (org.freedesktop.login1)" +requires_weak = [ + "12_dbus.service", +] + +[service] +cmd = "ion" +args = [ + "-c", + "sleep 5; redbear-sessiond", +] +type = "oneshot_async" +""" + +[[files]] +path = "/usr/lib/init.d/14_redbear-upower.service" +data = """ +[unit] +description = "UPower D-Bus service (org.freedesktop.UPower)" +requires_weak = [ + "12_dbus.service", +] + +[service] +cmd = "ion" +args = [ + "-c", + "sleep 5; redbear-upower", +] +type = "oneshot_async" +""" + +[[files]] +path = "/usr/lib/init.d/14_redbear-udisks.service" +data = """ +[unit] +description = "UDisks2 D-Bus service (org.freedesktop.UDisks2)" +requires_weak = [ + "12_dbus.service", +] + +[service] +cmd = "ion" +args = [ + "-c", + "sleep 5; redbear-udisks", +] +type = "oneshot_async" +""" + +[[files]] +path = "/usr/lib/init.d/14_redbear-polkit.service" +data = """ +[unit] +description = "PolicyKit1 D-Bus service (org.freedesktop.PolicyKit1)" +requires_weak = [ + "12_dbus.service", +] + +[service] +cmd = "ion" +args = [ + "-c", + "sleep 5; redbear-polkit", +] +type = "oneshot_async" +""" + [[files]] path = "/usr/lib/init.d/20_orbital.service" data = """ @@ -155,6 +237,7 @@ description = "Orbital display server (KDE session)" requires_weak = [ "10_net.target", "12_dbus.service", + "13_redbear-sessiond.service", "13_seatd.service", ] @@ -221,6 +304,8 @@ export DISPLAY="" export WAYLAND_DISPLAY=wayland-0 export XDG_RUNTIME_DIR=/tmp/run/user/0 export XDG_SESSION_TYPE=wayland +export XDG_SESSION_ID=c1 +export XDG_SEAT=seat0 export KDE_FULL_SESSION=true export XDG_CURRENT_DESKTOP=KDE export HOME=/root @@ -240,6 +325,17 @@ fi # Start D-Bus session bus eval $(dbus-launch --sh-syntax) +# Export session environment to D-Bus activation +dbus-update-activation-environment \ + WAYLAND_DISPLAY \ + XDG_SESSION_ID \ + XDG_SEAT \ + XDG_SESSION_TYPE \ + XDG_RUNTIME_DIR \ + XDG_CURRENT_DESKTOP \ + KDE_FULL_SESSION \ + DISPLAY + # Start KWin Wayland compositor kwin_wayland --replace """ diff --git a/config/redbear-live.toml b/config/redbear-live.toml index cd46cb79..a63a0894 100644 --- a/config/redbear-live.toml +++ b/config/redbear-live.toml @@ -8,3 +8,8 @@ include = ["redbear-desktop.toml"] [general] # Larger filesystem for live image with more tools filesystem_size = 12288 + +[packages] +# Keep these explicit for the live profile even though cub is inherited via redbear-desktop. +cub = {} +redbear-meta = {} diff --git a/config/redbear-minimal.toml b/config/redbear-minimal.toml index 247bb668..b979ed87 100644 --- a/config/redbear-minimal.toml +++ b/config/redbear-minimal.toml @@ -6,7 +6,9 @@ include = ["minimal.toml", "redbear-legacy-base.toml", "redbear-device-services.toml", "redbear-netctl.toml"] [general] -filesystem_size = 512 +# Minimal image now includes firmware payloads and Wi-Fi control-plane packages, +# so the previous 512 MiB image is too small for live ISO assembly. +filesystem_size = 2048 [packages] # Red Bear OS branding @@ -37,7 +39,6 @@ udev-shim = {} # Terminal file manager mc = {} - # Diagnostic tool redbear-info = {}