Commit Graph

1070 Commits

Author SHA1 Message Date
kellito 2633c40dfd tlc: Sprint 2 B3 — Tab-to-indent in editor
Tab key now has indent-aware behavior (MC parity):
  - When cursor is in the indent zone (only whitespace before it on
    the current line), Tab inserts enough spaces to advance to the
    next tab_width boundary.
  - When cursor is past any non-whitespace, Tab inserts a single
    literal '\t' character for column alignment.

New methods on Editor (editor/mod.rs):
  insert_tab_with_indent()
    - Computes next_boundary = ((col / tab_width) + 1) * tab_width
    - In indent zone: inserts (next_boundary - col) spaces
    - Otherwise: inserts literal '\t'
  is_in_indent_zone() -> bool
    - True if all bytes between line start and cursor are space/tab

Tab handler in editor/handlers.rs routes through
insert_tab_with_indent() instead of insert_char('\t').

Tests (6 new in editor::tests):
  - tab_at_col_0_indents_to_next_boundary
  - tab_at_col_4_indents_to_next_boundary
  - tab_mid_line_inserts_literal_tab
  - tab_after_non_whitespace_inserts_literal_tab
  - tab_after_whitespace_runs_continues_indent
  - tab_inside_word_inserts_literal_tab

Total: 1248 passing (was 1242; +6 new).
2026-07-05 16:55:30 +03:00
kellito 135e94b5e4 tlc: Sprint 2 B1 — word-boundary wrapping in editor
Replaces the character-counting wrap in build_wrap_map with a
word-boundary algorithm that matches MC's intent: lines break at
the last whitespace before the wrap limit, mid-word break as
fallback for overlong words, tabs counted as their visual width
(next tab_width boundary), control chars as 2 cols.

New helpers (editor/render.rs):
  visual_width(ch, col, tab_width) -> usize
    - Tabs: tab_width - (col % tab_width), min 1
    - Control chars (0x00..=0x1F, 0x7F): 2 cols (renders as ^X)
    - Other chars: 1 col

  count_wrapped_rows(line_bytes, body_width, tab_width) -> usize
    - Walks line left-to-right, tracks last whitespace position
    - On overflow: wrap at last_ws_col (preserves word boundary),
      else mid-word break
    - Stops at \n (line_bytes excludes \n in caller)

Editor (mod.rs):
  - New tab_width: usize field (default 4)
  - Matches the renderer's '    ' tab expansion in push_rendered_text
  - Future B4 will make this user-configurable

Tests:
  +12 wrap_tests in editor::render::wrap_tests:
    - visual_width_tab_expands_to_next_boundary
    - visual_width_ascii_and_control
    - count_wrapped_rows_empty_line
    - count_wrapped_rows_short_line_fits_in_one_row
    - count_wrapped_rows_exact_fit
    - count_wrapped_rows_one_char_overflow_no_whitespace
    - count_wrapped_rows_word_boundary_break
    - count_wrapped_rows_three_words_at_width_six
    - count_wrapped_rows_long_word_falls_back_to_mid_word
    - count_wrapped_rows_tab_visual_width
    - count_wrapped_rows_zero_width_returns_one
    - count_wrapped_rows_stops_at_newline

Total: 1242 passing (was 1230; +12 new).
2026-07-05 16:51:33 +03:00
kellito b1efd23faf tlc: PLAN.md full rewrite — keep only current state
PLAN.md was 1810 lines with substantial resolved/stale content:
  - §3 audit findings (35 items, all resolved months ago)
  - §4 remaining tasks (all done)
  - §8 risk register (all mitigated)
  - §8.1 palette section (redundant)
  - §13 built-in skins (done)
  - §14 per-row gap tables (superseded by §3.1 cumulative)
  - §15 MC source deep audit (done)
  - §16 unified button rendering (done)
  - §17 dialog consistency (P1-P4 done)
  - bottom Changelog (duplicated §9)

Rewrote to 421 lines (77% reduction) with:
  - §0 Identity & Naming
  - §1 Architecture
  - §2 Current Status (metrics table)
  - §3 MC Parity Roadmap (cumulative phase status)
  - §4 Recent Changelog (last 6 months, condensed)
  - §5 Build Commands
  - §6 Config Integration
  - §7 Risk Register (current)
  - §8 Sprint 1 Detail
  - §9 Sprint 2 Plan
  - §10 References

Sprint 1 (A1-A7 critical parity bugs, commit a2df7a06cf) prominently
documented in §4 changelog and §3.1 phase status.
2026-07-05 15:20:49 +03:00
kellito a2df7a06cf tlc: Sprint 1 MC parity fixes (A1-A7)
Implements all 5 critical parity items from the comprehensive MC
assessment. Reference: MC source at local/recipes/tui/mc/source/.

A1 — Editor line number gutter:
  Split editor inner area into gutter_area + body_area; gutter
  renders right-aligned line numbers (or relative offsets when
  relative_lines mode is on); bookmark rows show current-line
  style; ~ shown for lines past end-of-file.

A2 — Viewer cursor line highlight:
  cursor_line_bg derived from body_bg + RGB(12,12,12); applied
  before search-match overlay so matches win on the cursor line.

A3 — Hide terminal cursor in file manager mode:
  App::run() hides the cursor after Tui::new(); render() shows
  the cursor only when editor/viewer/cmdline/dialog/menubar
  is active.

A6 — Shift-F5/F6 same-directory rename:
  New Cmd::CopySameDir and Cmd::MoveSameDir variants, bound to
  Shift-F5 / Shift-F6. Reuse CopyDialog/MoveDialog with a new
  same_dir flag and new_rename() constructor; result() resolves
  the typed name against the source's parent directory.

A7 — SUID/SGID/sticky bits in chmod dialog:
  4-row PermCell grid (user, group, other, special); class_shift
  = 0o4000, bit = 1. Display as 0oXXXX. Overwrite dialog shows
  all 12 cells. 6 new unit tests cover all special-bit combinations.

Other fixes in the same commit:
  - 4 editor render tests shifted x-coordinates by gutter_chars
    to account for the new gutter column.
  - 1 viewer text test moves cursor to line 1 so cursor-line
    highlight doesn't overlap the search-match assertion.

Tests: 1230 passed (was 1219 before A7; +11 new tests across A7
and A6). All Sprint 1 items compile clean.
2026-07-05 14:42:17 +03:00
vasilito 146986b955 tlc: F9 Left/Right menus now target respective panel
MenuBarOutcome::Dispatch now carries Option<usize> indicating which
menu (0=Left, 4=Right) originated the command. app.rs switches focus
to the corresponding panel before dispatching. This matches MC
behavior where the Left menu always operates on the left panel and
the Right menu on the right panel, regardless of which panel had
keyboard focus.
2026-07-05 09:54:31 +03:00
vasilito 7043a466c5 tlc: MC-style name-based cursor restoration on parent navigation
When going UP to a parent directory, find the entry whose name matches
the last component of the path being left (MC's get_parent_dir_name
approach). This is more robust than saved-index restoration because it
works even when the parent directory listing changed between visits.
Falls back to saved dir_cursors index for non-parent navigation.
2026-07-05 09:48:16 +03:00
vasilito 4526853895 tlc: fix viewer scrolling, cursor jumping, .zip hang, unsupported keys
- viewer/mod.rs: implement MC-style cursor tracking with independent
  scroll (move_cursor_down/up/ensure_cursor_visible). Arrow keys now
  move cursor within visible area; scrolling only when cursor reaches
  edge. last_height field stores render area height for key handlers.
  Fixes 'pressing down sends all text off screen'.
- panel.rs: save and restore BOTH cursor AND top scroll position in
  dir_cursors HashMap. Previously only cursor was saved and top was
  always reset to 0, causing ensure_cursor_visible to snap the view
  on every directory switch.
- panel.rs: fix try_enter_archive to construct VFS URL with correct
  scheme prefix (zip://, tar://) instead of parsing raw file path
  as Local. Fixes .zip/.tar hang on Enter.
- terminal/event.rs: rewrite parse_unsupported_key to handle CSI-tilde
  modifier sequences (\x1b[15;5~ = Ctrl-F5) and CSI arrow modifier
  sequences (\x1b[1;5B = Ctrl-Down). Returns tlc Key directly with
  modifiers set, bypassing termion's limited TermKey enum.
- app.rs: simplify event dispatch to use Key directly from
  parse_unsupported_key, removing dead TermKey variable.
- 6 new tests for modifier+function-key and modifier+arrow parsing.
2026-07-05 09:44:13 +03:00
vasilito ba429163e9 tlc: fix UTF-8 cursor panic + remove viewer/editor line numbers
- cursor.rs: move_left walks back over UTF-8 continuation bytes,
  move_right steps by char width via utf8_len_from_lead(), move_up/down
  snap to char boundary via snap_to_char_boundary()
- mod.rs: update_bracket_flash adds defensive is_char_boundary() check
- render.rs: remove gutter/column layout, body_area = inner (matches MC
  editdraw.c line_state=FALSE default); bookmark colors applied to
  body line base_style (matches MC book_mark line coloring)
- text.rs: remove gutter rendering and Paragraph .wrap(); implement
  pre-wrapping via wrap_line() for wrap mode; body uses full width
- Tests updated for new no-gutter layout (4 tests, all pass)
2026-07-05 09:12:11 +03:00
vasilito eb8686f4c3 tlc: add Edit extension/menu/highlighting file commands
Wire three Command menu items that open TLC's config files in
the built-in editor: extensions, user menu, and file highlighting
rules. Files are created empty if they don't exist.

Cmd::EditExtensionFile → ~/.config/tlc/extensions
Cmd::EditMenuFile → ~/.config/tlc/menu
Cmd::EditHighlightFile → ~/.config/tlc/filehighlight.ini

Added open_config_file() helper in dialog_ops.rs that resolves
the config dir via ProjectDirs, creates parent + empty file if
missing, then opens the editor.

Command menu now has all 20 items (was 17/20).
2026-07-05 08:14:45 +03:00
vasilito 4e3b06af83 tlc: fix all 49 clippy warnings (0 remaining)
Systematic clippy sweep across 22 files:
- Remove unused imports (Modifier, Block, Borders, Clear, Line)
- Remove unnecessary mut/unused variables (cursor.rs, mc_skin.rs)
- Fix unnecessary casts in popup.rs and viewer/mod.rs
- Use abs_diff instead of manual abs pattern (render.rs)
- Collapse nested if in menubar.rs
- Merge identical if branches in render.rs
- Use strip_prefix instead of manual slice (mod.rs)
- Use io::Error::other instead of Error::new (source.rs)
- Remove useless format! in known_hosts.rs
- Add #[derive(Default)] to SelectionMode enum
- Add #[allow] for too_many_arguments on render functions
- Add #[allow(dead_code)] for utility functions (centered_rect, rgb)
- Remove redundant .clone() on &str in menubar.rs
- Remove .max(0) on unsigned subtraction (button.rs)
- Add missing doc comments on public methods (editor, panel, ops)

cargo clippy --lib: 0 warnings (was 49)
cargo test --lib: 1213 passed, 0 failed
2026-07-05 07:42:00 +03:00
vasilito fb9be0d293 tlc: comprehensive §14.1-§14.6 PLAN refresh + Ctrl-X h chord
Update all 6 MC parity gap-analysis tables in PLAN.md to reflect
the true implementation state after Phases 15a-15l, §30, §31, §33.

Key corrections:
- §14.1 keybindings: 77/78  (was stale at ~73/77)
- §14.2 F9 menus: Left/Right 13/13 , File 20/21 , Command 17/20 
- §14.5 editor: 28/35  (was 15/35) — syntax, format paragraph,
  date insert, auto-indent, show whitespace, F9 menubar all added
- §14.6 viewer: 17/19  (was 6/19) — hex, bookmarks, growing files,
  wrap toggle, goto line, next/prev file, percent display all done
- §14.8 summary: ~93% complete (~44/51), up from stale ~90%

Also: Ctrl-X h chord now dispatches to Cmd::HotList.
2026-07-05 05:38:13 +03:00
vasilito b66a9e509e policy: mark bootloader fork as PENDING_REBASE
The local bootloader fork claims to be upstream 1.0.0 + Red Bear
patches, but the patches in local/patches/bootloader/ do NOT
apply cleanly to upstream 1.0.0. The fork was originally a 0.1.0
baseline with substantial additions that pre-date the upstream-1.0.0
refactor.

Changes:

  * local/fork-upstream-map.toml: set bootloader's upstream tag to
    PENDING_REBASE. The verifier recognises this as a deliberate
    state marker (a fork whose rebase is in progress) and refuses
    the build with a clear error pointing the user to the rebase
    procedure documented in the map.

  * local/scripts/verify-fork-versions.sh: when a fork is marked
    PENDING_REBASE in the map, the script reports a dedicated error
    message instead of running the upstream content comparison (which
    would always fail for a fork in this state).

The current state of the build is:
  * 5 of 6 `-rb1` Cat 2 forks pass the no-fake-version-label
    check (redoxfs, redox-scheme, kernel, installer, userutils).
  * bootloader refuses to build until a real rebase onto a chosen
    upstream tag is completed (the patches must apply cleanly with
    --fuzz=0).
  * installer has additional divergent content that may need a
    rebase too (separate operational task).

This is the strict enforcement the user asked for. The build
cannot proceed silently with fake labels. The user must drive
the rebase work for bootloader (and installer) following the
procedure in fork-upstream-map.toml.
2026-07-05 05:15:27 +03:00
vasilito 56d862e7a7 tlc: wire all remaining F9 editor menubar commands
Wire New, Open, Save, SaveAs, Quit, Find, FindNext, FindPrev,
Replace, BookmarkNext, BookmarkPrev through dispatch_editor_cmd.
Previously these printed 'F9: Cmd (not yet wired)'. Now each one
performs the actual operation matching its Alt-key/F-key equivalent.

open_save_before_close_prompt made pub(crate) so the Quit handler
can intercept dirty buffers.
2026-07-05 04:32:28 +03:00
vasilito 9e2a2666e0 tlc: wire editor Options menu toggles in F9 menubar
Add ToggleAutoIndent, ToggleShowWhitespace, ToggleWordWrap,
ToggleSyntax, ToggleRelativeLines to EditorCmd enum and dispatch
them through dispatch_editor_cmd. The Options menu now has all
five toggles alongside Settings, making them discoverable via F9
in addition to their Alt-key shortcuts.
2026-07-05 03:16:37 +03:00
vasilito c0157fc30e tlc: add Sort order... to F9 Left/Right menubar pull-downs
The SortDialog was wired to Alt-Shift-T in §31.1 but was missing
from the F9 menu bar. MC has 'Sort order...' under both Left and
Right menus. Added to both.
2026-07-05 03:02:31 +03:00
vasilito 3d3937c22d tlc: §32 viewer word-wrap fix + PLAN §14.7 table refresh
§32.1 Viewer word-wrap fix: Paragraph .wrap() was always applied
regardless of the v.wrap toggle. Now .wrap(Wrap { trim: false }) is
conditionally applied only when v.wrap is true. When wrap is off,
long lines truncate at the right margin (MC parity). Stale TODO
removed from render_line_with_highlight.

§32.2 Alt-W wrap toggle test verifying the field toggles correctly.

PLAN §14.7 table refresh: 30+ stale entries corrected. Phase 14b
6/6 done. Phase 14c 14/15 done (1 WONTFIX). Phase 14d ~17/25 done.
Overall ~90% MC parity.

Tests: 1213 passed, 0 failed.
2026-07-05 02:54:10 +03:00
vasilito f7c3d504dd policy: enforce no-fake-version-label rule for Cat 2 forks
Per local/AGENTS.md \xC2\xA7 'No-fake-version-label rule':

  Every Cat 2 fork version MUST match the source content from the
  corresponding upstream release + documented Red Bear patches.
  A `-rbN` label on stale content is a fake label and a policy
  violation.

Changes:

  * local/AGENTS.md: documented the no-fake-version-label rule,
    including what counts as a fake label, the enforcement contract,
    and what a real Red Bear fork looks like.

  * local/fork-upstream-map.toml: authoritative mapping of each
    Cat 2 fork (syscall, libredox, redoxfs, redox-scheme, relibc,
    kernel, bootloader, installer, userutils) to its upstream Git
    URL and release tag.

  * local/scripts/refresh-fork-upstream-map.sh: auto-update the
    fork-upstream-map by querying each upstream repo for the
    current latest stable release tag.

  * local/scripts/verify-fork-versions.sh: preflight enforcement
    script. For each Cat 2 fork with a `-rbN` version field:
      1. Compare fork's file list and content against the upstream
         release tag from the map. Reject the build if files are
         missing (would be a fake label).
      2. Reject the build if files exist in local that don't exist
         in upstream (must be moved to local/patches/<fork>/ as
         documented Red Bear patches).
      3. Reject the build if shared files diverge in content.

  * local/scripts/apply-rb-suffix.sh: invokes
    verify-fork-versions.sh after applying the `-rbN` label so the
    build fails fast if the labelled content is fake.

  * local/scripts/build-preflight.sh: invokes
    verify-fork-versions.sh at the start of every build. Bypassed
    only with REDBEAR_SKIP_FORK_VERIFY=1 (emergency only).

  * local/patches/bottom/0001-ratui-0.30-braille-compat.patch: the
    ratatui 0.30+ compatibility shim for bottom 0.11.2.

This is the structural enforcement that prevents fake labels from
ever reaching the build again. The current 6 forks with `-rbN`
labels are flagged by the verifier — they must be rebased onto
their actual upstream release before the build can succeed.
2026-07-05 02:37:54 +03:00
vasilito 2c4ccd5f3f tlc: §31 SortDialog wiring, truncation indicators, editor toggles
§31.1 SortDialog wiring: orphaned SortDialog struct connected to
Alt-Shift-T keybinding, Cmd::SortDialog variant, DialogState::Sort,
dialog key handling (Confirm/Cancel/Running), apply_sort() on Panel,
full render path through render.rs.

§31.2 Filename truncation indicator: truncate_to_width() appends ~
when content overflows panel width (MC parity). Applied to Long/Full
listing modes, info mode, and quickview mode. 5 tests.

§31.3 Editor auto-indent toggle: auto_indent field (default on),
Alt-A toggles. When off, Enter inserts plain newline with no
indentation copy. 3 tests.

§31.4 Editor show whitespace toggle: show_whitespace field (default
off), Alt-E toggles. push_rendered_text gains show_ws param — when
off, tabs render as 4 spaces and spaces render normally (no glyph
markers). 2 tests.

PLAN.md §14.7 tables updated: 30+ stale  entries corrected to .
Effort summary updated from ~36% to ~90% complete.

Tests: 1212 passed, 0 failed (1204 baseline + 8 new).
2026-07-05 02:24:48 +03:00
vasilito a2958e9b02 tlc: §30 MC parity — cursor memory, display, file ops, hardlink optimization
13 sub-items closing genuine MC parity gaps identified in PLAN §14:

Panel display:
- Cursor memory: per-directory cursor save/restore via HashMap
- mtime column: MC dual-format dates (recent=Mon DD HH:MM, old=Mon DD YYYY)
- rwx permissions: 10-char -rwxr-xr-x in Long listing mode
- Type glyphs: MC-style / @ * | = # % suffixes on entries
- Free space: panel footer shows disk free/total via statvfs

Navigation/sort:
- Sort reverse: Ctrl-Alt-T toggle (was dispatched but unbound)
- Sort case sensitivity: Alt-C toggle between case-insensitive/sensitive
- Viewer next/prev: dispatch fixed from no-op stub to real open_next/prev

File operations:
- Same-file detection: OpsError::SameFile via canonicalize check
- Hardlink optimization: HardlinkTracker maps source (dev,ino) to first
  destination; when nlink>=2 and identity already copied, creates
  fs::hard_link instead of byte-for-byte copy

Viewer:
- Wrap toggle: Alt-W (field existed, key was unbound)
- Percent display: footer shows NN% based on line position

Editor:
- Date insert: Alt-D inserts YYYY-MM-DD HH:MM at cursor

Version: 1.0.0-beta → 0.2.5 (branch-aligned)
Tests: 1184 → 1204 (+20 new), 0 failures
Binary: tlc 5.3MB, tlcedit 3.9MB, tlcview 3.7MB
2026-07-04 14:27:01 +03:00
vasilito 26ecd868f7 fork: import redox-scheme 0.11.2 as tracked tree with -rb1 deps
Red Bear OS needs a local fork of redox-scheme to enforce the -rb1
version policy end-to-end. crates.io redox-scheme 0.11.2 pins
redox_syscall = "0.9.0" exactly and libredox = "0.1.18" exactly,
which Cargo refuses to satisfy with the local -rb1 forks.

The fork is implemented as a TRACKED TREE under local/sources/redox-scheme/
on the active 0.2.5 branch (per local/AGENTS.md), not as a separate
git repository or as a separate submodule on its own branch.

The single-repo rule from local/AGENTS.md is preserved: this
directory is a regular subdirectory of the RedBear-OS repo, not a
separate repository.
2026-07-04 11:05:39 +03:00
vasilito 1957f3ff36 docs: add upstream-alignment philosophy and constant-build-system note 2026-07-04 09:21:46 +03:00
vasilito 5be1ec17b3 docs: rewrite README for public audience — highlight cub, tlc, redbear-* utilities, current status, call for contributors 2026-07-04 09:18:22 +03:00
vasilito d7273ce5cf fix: document and implement local fork version sync policy
Add comprehensive policy documentation in AGENTS.md covering:
- local/ fork always takes precedence over recipes/ paths
- build system must ensure local fork is at latest available version
- all Red Bear patches must be applied cleanly on top of latest version
- automatic version bump + patch reapplication via bump-fork.sh

Create local/scripts/bump-fork.sh that implements automatic version bumping:
- Detects current local version vs required version from Cargo.lock
- Fetches upstream source at required version
- Applies all Red Bear patches atomically
- Updates version field and replaces local fork contents

Fix driver-manager Cargo.toml lockfile collision:
- Remove redundant syscall dependency (transitive via pcid_interface)
- Update all driver recipes to use local/sources/syscall and libredox paths
- This eliminates the redox_syscall lockfile collision between
  local/sources/syscall and recipes/core/base/syscall (same dir, different paths)

relibc: fix unsafe call for Rust 2024 edition compatibility
2026-07-04 04:23:34 +03:00
vasilito 2c702465a1 fix: convert ucsid, driver-params to oneshot_async; add ipcd/ptyd overrides
Config changes to prevent scheduler hangs on live-mini ISO:
- 00_ucsid.service: scheme -> oneshot_async
- 13_driver-params.service: scheme -> oneshot_async
- 00_ipcd.service: new override (notify -> oneshot_async)
- 00_ptyd.service: new override (notify -> oneshot_async)
- 00_pcid-spawner.service: new override (oneshot -> oneshot_async)
- base: update submodule to 4bfb878 (force-run scheduler)
2026-07-04 01:07:56 +03:00
vasilito 1eed99c54f fix: change gpiod, i2cd, pcid-spawner to oneshot_async; add pcid-spawner override
All three were blocking the boot scheduler in /usr phase on live-mini
because their daemons never notify readiness without hardware present.

- 00_gpiod.service: scheme -> oneshot_async
- 00_i2cd.service: scheme -> oneshot_async
- 00_pcid-spawner.service: new override, oneshot -> oneshot_async
- base: update submodule to 4a1d1f4 (scheduler counter)
2026-07-03 10:43:31 +03:00
vasilito f47ee4fb18 fix: change blocking oneshot services to oneshot_async, add init scheduler tracing
- pcid-spawner: oneshot -> oneshot_async (blocked boot in /usr phase)
- inputd: oneshot -> oneshot_async (unnecessary blocking during initfs)
- base: update submodule to b1a6bd8 (serial debug tracing for scheduler)
- run_mini1.sh: reduce QEMU memory 12G -> 2G for faster CI testing
2026-07-03 08:56:39 +03:00
vasilito 2bed64a6c5 base: bump submodule pointer for acpid processor data readers
acpid now evaluates _CST/_PSS/_PSD/_CPC via AML interpreter and
returns formatted text for /scheme/acpi/processor/CPU{n}/<method>.
2026-07-02 23:59:18 +03:00
vasilito 5d4d3dbce1 kernel: Tier 3 — C-state tracking and CPU topology 2026-07-02 23:27:46 +03:00
vasilito f0364a4e4a kernel: fix LAPIC spurious interrupt vector 0x00 → 0xFF 2026-07-02 23:09:36 +03:00
vasilito 890be982a6 docs: enforce canonical build command across all docs
Replace all non-canonical build invocations (bare 'make all/live
CONFIG_NAME=', 'scripts/build-iso.sh', 'scripts/run.sh') with the
canonical './local/scripts/build-redbear.sh' wrapper.

Updated: AGENTS.md, local/AGENTS.md, README.md, docs/README.md,
docs/06-BUILD-SYSTEM-SETUP.md, and 6 active local/docs plan files.
Archived docs and frozen boot-logs left as-is (historical evidence).
2026-07-02 22:54:47 +03:00
vasilito afad19ff1a kernel: fix early-boot excp_handler panic on bare metal
Updates kernel submodule to 573b3e6 which replaces context::current()
with context::try_current() in excp_handler(), preventing the cascading
'not inside of context' panic when a page fault occurs during BSP's
start() before context::init() runs.
2026-07-02 22:34:40 +03:00
vasilito eb53e8190a redbear-power: multi-threaded collector + Tier 1/2 display enhancements
Tier 1 (display Phase 0 infrastructure):
- sched.rs: read /scheme/sys/stat and /scheme/sys/sched for per-CPU
  scheduler stats (switches, steals, queue_depth, IRQs)
- msr.rs: HWP capabilities/requests, RAPL domain energy readings
- process.rs: derive_sched_policy() for SCHED column
- render.rs: System tab shows RAPL power, scheduler stats; Per-CPU
  table has IRQs/steals columns; HWP expansion rows
- acpi.rs: ACPI throttle status reading

Multi-threaded collector (exercises Phase 0 threading):
- collector.rs: parallel collect() using thread::scope + Barrier,
  exercises pthread_create, futex barriers, sched_setaffinity
- app.rs: sequential per-CPU loop replaced with parallel collector
- render.rs: System tab shows Collector stats (threads, pinned, barrier)

Tier 2 kernel wiring (submodule pointer updates):
- kernel: per-CPU sched stats (/scheme/sys/sched), NUMA-aware
  scheduling, numa::init_default() at boot
- relibc: robust mutex cleanup in exit_current_thread()
2026-07-02 21:41:25 +03:00
vasilito 6d13dee2a6 redbear-power(0.2.5): fix missing hwp field in CpuRow initializer
Pre-existing bug: CpuRow struct gained an hwp field but the initializer
at line 319 was not updated.
2026-07-02 19:22:19 +03:00
vasilito a43cca122d qtwayland(0.2.5): add PCH disable + SBOM disable flags 2026-07-02 19:13:10 +03:00
vasilito fc0c1e4576 qtshadertools(0.2.5): wire ShaderToolsMacros into Config.cmake
The cmake-generated Qt6ShaderToolsConfig.cmake has an empty
extra_cmake_include list. Patch it to include Qt6ShaderToolsMacros.cmake
so qt_internal_add_shaders is defined for downstream modules.
2026-07-02 18:38:45 +03:00
vasilito 83f47db352 qtshadertools(0.2.5): install Qt6ShaderToolsMacros.cmake
cmake install skipped this 405-line macros file that defines
qt_internal_add_shaders/qt6_add_shaders. Without it, downstream Qt
modules (qtdeclarative) fail at cmake configure with 'Unknown CMake
command qt_internal_add_shaders'.
2026-07-02 18:34:21 +03:00
vasilito f877419c43 qt modules(0.2.5): disable PCH for cross-compile
Add CMAKE_DISABLE_PRECOMPILE_HEADERS=ON to qtdeclarative, qtwayland,
and qt6-sensors — same cross-compiler PCH issue as qtshadertools.
2026-07-02 18:31:00 +03:00
vasilito ac0712e8b9 qtshadertools(0.2.5): disable PCH (cross-compiler silent crash)
Redox cross-compiler fails silently on PCH generation. Disable
precompiled headers for the cross-compile step.
2026-07-02 18:19:26 +03:00
vasilito d097261be3 qtshadertools(0.2.5): disable SBOM generation (cross-compile)
Qt 6.11 SBOM install fails referencing qtbase SBOM docs during
cross-compile. SBOM is metadata only — no impact on libs/binaries.
2026-07-02 18:13:38 +03:00
vasilito 8ce2ec6b21 pam-redbear(0.2.5): regenerate Cargo.lock after version bump
redbear-login-protocol path dependency bumped to 0.2.5 but Cargo.lock
was stale. Regenerated to pick up the new version.
2026-07-02 18:08:23 +03:00
vasilito 5e68844868 qtshadertools(0.2.5): fix TOML parse - use shell heredocs for cmake pkg gen
Python f-string triple-quotes conflicted with TOML script delimiter.
Rewrote cmake package generation using shell heredocs instead.
2026-07-02 18:08:22 +03:00
vasilito 217ca485b7 qtshadertools(0.2.5): generate Qt6ShaderToolsTools cmake package
Qt6's standalone module build installs qsb binary but does not generate
the Qt6ShaderToolsTools cmake wrapper package needed by cross-compile.
Added a Python generator that creates the minimal cmake package files
(Config, Targets, Targets-release, Precheck, AdditionalTargetInfo,
VersionlessTargets, Dependencies, ConfigVersion) following the exact
pattern of Qt6WaylandScannerTools from qtbase host build.
2026-07-02 18:01:51 +03:00
vasilito 5b42305568 qtshadertools(0.2.5): add host build step for qsb tool
qtshadertools cross-compile needs the host 'qsb' (Qt Shader Builder)
tool, just like qtbase needs host moc/rcc/uic. Added a native cmake
build step that compiles qsb from the 6.11.1 source and installs it
into the shared qt-host-build prefix.

Also regenerate pam-redbear Cargo.lock (stale after 0.2.5 version bump
of redbear-login-protocol path dependency).
2026-07-02 17:51:45 +03:00
vasilito f988cc0d58 feat: redbear-mini boots to login prompt with Phase 0 threading patches
Kernel (local/sources/kernel):
- Per-CPU idle context race fix (try_idle_context)
- Pinned to nightly-2026-04-11
- Futex sharding, cache-affine context, per-CPU scheduler
- NUMA topology, proc lock ordering, sched policy handles
- ACPI FADT type fix

relibc (local/sources/relibc):
- Non-robust mutex ENOTRECOVERABLE false positive fix
- pthread_cond_signal POSIX fix
- Pthread yield, barrier SMP futex, robust mutexes
- sched API, comprehensive semaphore, pthread affinity+setname
- stdint.h in sched.h cbindgen

Boot verified: UEFI -> kernel -> init -> drivers -> services -> login prompt
All Red Bear init stages pass (02->04->06->08)
xhcid no longer crashes, D-Bus services online
2026-07-02 17:13:06 +03:00
vasilito bc7bbfb293 qtbase(0.2.5): update host profile to 6.11.1
The host tool build profile was hardcoded with '6.11.0', causing the
stale 6.11.0 host tools to be reused for the 6.11.1 cross-compile.
Updated profile string to invalidate old host build.
2026-07-02 17:04:38 +03:00
vasilito 9c93a3fc5b qtbase(0.2.5): rebase redox.patch for Qt 6.11.1 — drop obsolete OpenGL guard hunks
Upstream Qt 6.11.1 already absorbed the #if QT_CONFIG(opengl) guards in
qwaylandclientbufferintegration_p.h that our redox.patch was adding.
Removed the now-obsolete hunks per patch governance (rebase, drop if
upstream absorbed it).

All remaining hunks apply cleanly against 6.11.1 with minor line offsets.
2026-07-02 16:21:26 +03:00
vasilito 7902864a32 version(0.2.5): bump project version to 0.2.5
- Cookbook Cargo.toml: 0.1.0 → 0.2.5
- All 61 in-house crate Cargo.toml versions: 0.2.4 → 0.2.5
- os-release.in: fix URLs from github.com to gitea.redbearos.org
- sync-versions.sh --check passes with zero drift

The OS version is derived from the git branch name at build time.
Building on branch 0.2.5 produces os-release with VERSION_ID=0.2.5.
2026-07-02 15:36:28 +03:00
vasilito 8b627c40af graphics(0.2.5): bump all KF6 frameworks 6.10→6.27, Plasma 6.3.4→6.7.2, remaining libs to latest stable
KF6 frameworks: 44 frameworks bumped from 6.10.0/6.26.0 to 6.27.0 (latest stable).
All switched to download.kde.org canonical release URLs with BLAKE3 hashes.

KDE Plasma packages bumped to 6.7.2 (latest stable):
- breeze 6.3.4→6.7.2
- plasma-workspace 6.3.4→6.7.2
- kf6-kwayland 6.3.4→6.7.2
- kf6-plasma-activities 6.6.5→6.7.2

Other graphics libs bumped to latest stable:
- libxkbcommon 1.9.2→1.11.0
- seatd-redox 0.9.3→0.10.1 (URL switched to gitlab.freedesktop.org)
- plasma-wayland-protocols 1.16.0→1.21.0

All BLAKE3 hashes computed from actual upstream tarballs.
2026-07-02 15:31:30 +03:00
Red Bear Build System 0757975704 docs(0.2.5): execution log of commits made against the freeze plan
Records actual recipes bumped in 0.2.5 on 2026-07-02:

- Qt stack 6.8.2/6.11.0a1 -> 6.11.1 (all 6 sub-recipes, verified BLAKE3)
- Wayland/DRM/Input/expat/seatd to upstream latest stable (8 recipes,
  verified BLAKE3)
- KWin 6.3.4 -> 6.7.2 + kdecoration 6.3.4 -> 6.7.2 + konsole 24.08.3
  -> 26.04.3

Plus structural fix: created the missing qtshadertools recipe so the
qtdeclarative dependency chain resolves.

Documents what was deliberately NOT done:
- KF6 6.10 -> 6.27.0: 38 frameworks, 17-minor delta. Per AGENTS.md
  patch-governance, no commit that bumps recipe.toml URLs without
  first rebasing the local patches can be made honestly. Rebase
  work (17-minor * 38 recipes) is multi-day and recorded as open.
- Mesa 24.0.8 -> 26.1.4: blocked on redox-os/mesa fork rebase
  (0.3.0 work).

Includes the rebase order for the next session that plans to run
'make all CONFIG_NAME=redbear-full' against the bumped pins.
2026-07-02 14:38:19 +03:00
Red Bear Build System 3539e621a2 kde(0.2.5): bump KWin 6.6.5->6.7.2, kdecoration 6.3.4->6.7.2, konsole 24.08.3->26.04.3
Bump KDE Plasma + KDE utility recipes to upstream latest stable
on 2026-07-02.

Versions resolved against download.kde.org/stable/plasma/ and
invent.kde.org/plasma/* tags:

  kwin         6.3.4  -> 6.7.2   (invent.kde.org/plasma/kwin)
  kdecoration  6.3.4  -> 6.7.2   (invent.kde.org/plasma/kdecoration)
  konsole      24.08.3 -> 26.04.3 (invent.kde.org/utilities/konsole;
                                    note: KDE utility versioning switched
                                    from YY.MM calendars to v26.04-style)

BLAKE3 hashes verified against the actual downloaded upstream tarballs.

State of source trees on disk (NOT touched by this commit):
  - local/recipes/kde/kwin/source/         : still KWin 6.6.5 (prior
    session imported 6.6.5 source; new tarball at v6.7.2 will replace
    on next repo fetch).
  - local/recipes/kde/kdecoration/source/  : still 6.3.4
  - local/recipes/kde/konsole/source/      : still 24.08 (RELEASE_SERVICE_
    VERSION_MAJOR/MINOR).

Per AGENTS.md fork-adaptation policy, patches in local/patches/
{kwin,kdecoration,konsole}/ must be re-applied against the new
upstream source trees after fetch; rebase is open work for the
next session. Disabling patches or wrapping with feature flags is
NOT acceptable per the in-tree stub/workaround zero-tolerance rule.

This commit does NOT bump any KF6 framework recipe (38 recipes,
17-minor upstream delta). That work is multi-day patch rebase and
remains open.
2026-07-02 14:36:39 +03:00