Commit Graph
276 Commits
Author SHA1 Message Date
daniel 724029cacb feat: add userspace system logging, rename klog to syslog, rename relevant syscalls and API functions 2026-08-14 18:37:27 +02:00
daniel 0f81276efc feat: add inherited sessions and desktop session teardown 2026-08-14 10:33:20 +02:00
daniel e3ef1b81ad fix: fix text overlap bug in file dialogs and remove unnecessary hint in Keyboard applet 2026-08-13 18:10:00 +02:00
daniel 821543238d feat: add keyboard layout support 2026-08-13 17:57:44 +02:00
daniel a28b8ad0b2 fix: fix ramdisk readdir inconsistency. 2026-08-12 18:35:14 +02:00
daniel 7f2d4b693f feat: add crash stack snapshots and context menu annotations 2026-08-12 18:30:08 +02:00
daniel 3ef98a9fd5 fix: inherit process environment and untrack libc objects 2026-08-11 13:08:40 +02:00
daniel 0a91131cb0 feat: add ssh server (sshd) 2026-08-11 12:53:36 +02:00
daniel 69725658cf feat: init - dynamic service discovery via init.toml 2026-08-10 17:00:52 +02:00
daniel e25ef470e0 feat: files - update volume label formatting 2026-08-10 16:53:48 +02:00
daniel 990d184bd0 feat: pdfviewer - expand PDF rendering support 2026-08-10 15:03:54 +02:00
daniel 9b23d99082 feat: overhaul userspace heap and virtual memory 2026-08-10 12:25:27 +02:00
danielandClaude Opus 5 27c13b8dc2 refactor: move DOOM out to the mtkports ports tree
Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_018Ae69wJS7sueQMUwNxV3nX
2026-08-07 20:10:52 +02:00
daniel 53d3e6c568 refactor: remove old hello.elf userspace program 2026-08-07 13:26:06 +02:00
daniel cc1d80442e refactor: split out game engine experiment and demo game 2026-08-07 13:24:46 +02:00
daniel 326416636d feat: desktop - use MTK buttons for power dialogs 2026-08-07 11:41:47 +02:00
daniel 0e1601be74 feat: desktop - use MTK menu for desktop right-click menu 2026-08-07 10:55:38 +02:00
daniel 9eb21eb3e3 feat: wi-fi - expand support and fix issues, add GUI components 2026-08-07 10:36:53 +02:00
daniel bbe1df62fd feat: wi-fi - join WPA2/WPA3-PSK networks and carry traffic like ethernet 2026-08-06 19:44:35 +02:00
daniel a01e63c717 feat: intel wi-fi (AX211) driver with network scanning 2026-08-06 08:36:10 +02:00
daniel 75d92d560c refactor: libc - share printf, split the float path, fix relink deps 2026-08-04 17:29:24 +02:00
daniel edc3452d61 feat: real stat metadata across all filesystems, plus mkdir and rmdir 2026-08-04 13:03:08 +02:00
daniel ca5331c9db feat: vfs - add dynamic filesystem mounts and safe unmount lifecycle 2026-08-04 08:58:50 +02:00
daniel b1c55073c7 fix: kernel concurrency, interrupt context, and user VA safety 2026-08-01 15:43:38 +02:00
daniel f222bf1f04 cleanup: remove "MODESETTING SAFETY" section in Display app 2026-07-31 18:56:27 +02:00
daniel 18122136dd fix: improve Bluetooth reliability 2026-07-31 18:42:48 +02:00
daniel 471903bafb feat: expand Intel GPU display management 2026-07-30 17:12:08 +01:00
daniel 86de3400a9 feat: audio - add concurrent mixing, output switching, and device-aware UI 2026-07-29 20:03:35 +01:00
daniel d99dab45e5 feat: add NTP; fix networking bugs/regressions 2026-07-29 16:32:18 +01:00
daniel a288dee7df refactor: network - harden TCP/IP and unify HTTP clients 2026-07-29 15:35:17 +01:00
daniel 75ae7ede56 refactor: unify desktop apps and Settings under item catalog 2026-07-29 13:59:46 +01:00
daniel e9d8c66ff5 feat: files app - render modified dates in Properties dialog 2026-07-21 14:44:44 +02:00
daniel 2319858e8c fix: add path qualification to Files app pathbar 2026-07-18 12:07:53 +02:00
daniel b319399139 feat: revamp Installer UI 2026-07-18 11:55:11 +02:00
daniel 3ac25b7abd feat: raised max windows to 32 2026-07-18 10:34:46 +02:00
daniel 796ed46d12 fix: fix Font Preview crash if opened manually 2026-07-18 10:21:22 +02:00
daniel 7c8b7a5cf7 fix: fix totals calculation in Software step, Installer app 2026-07-18 10:14:59 +02:00
danielandClaude Opus 4.8 0377be4524 feat: redesign installer on MTK toolkit with component selection
Rewrite the Installer app on the Montauk Toolkit (Canvas + gui/mtk
widgets, theme, hover states, scrollbar) replacing the hand-rolled px_*
renderer and bespoke TrueType usage.

Add a new "Software" step: an expandable checkbox tree for optional
components (Montauk SDK with gcc/g++, binutils, tcc, lua sub-items;
Games; Office; Internet apps; Printing; experimental httpd and SDR).
Unchecked components' paths are excluded from the install copy, with a
longest-path ownership rule so e.g. sdk/tcc installs even when the rest
of the SDK is deselected. The update flow refreshes only the components
the target already has.

Add tri-state checkbox and disclosure-arrow widgets to the MTK toolkit
(anti-aliased, supersampled).

Merge tcc and lua into 0:/sdk (0:/sdk/tcc, 0:/sdk/lua) and drop 0:/lib:
update tcc config.h, lua luaconf.h, both Makefiles, the devkit clean
scope, man pages and montaukos.org notices.

Make printing optional: init skips printd when 0:/os/printd.elf is
absent.

Co-Authored-By: Claude Opus 4.8 <[email protected]>
2026-07-17 20:52:19 +02:00
danielandClaude Fable 5 75184e0651 feat: process exit codes, posix_spawn, 4 KiB command lines
Groundwork for the GCC driver: a compiler driver must spawn cc1/as/ld
and know whether each stage succeeded.

Kernel: the scheduler keeps an exit-code ledger (pid -> code; pids are
monotonic so entries never alias), published during teardown right
before waiters wake. SYS_EXIT records main()'s return value, SYS_KILL
records 256+SIGKILL, and the exception handler records 256+signal
mapped from the fault vector (#PF/#GP -> SIGSEGV, #DE/FP -> SIGFPE,
#UD -> SIGILL). SYS_WAITPID now returns the code: 0..255 for a normal
exit, 256+signal for a violent death. Process args grow from 256
bytes to 4 KiB (cc1 invocations do not fit in 256), with crt1 now
parsing up to 255 argv entries from a static buffer.

libc: new spawn.h with posix_spawn/posix_spawnp over SYS_SPAWN -
libiberty's pex layer has a posix_spawn backend, so GCC's driver works
without fork. argv is joined into the kernel args string (spaces in
arguments rejected; no kernel quoting), envp is not transferred, and
non-empty file actions fail loudly with ENOTSUP until the kernel can
redirect stdio on spawn. waitpid() now decodes real POSIX status and
the sys/wait.h macros distinguish exited from signaled children.

Shell: prints [exit code N] after nonzero exits and [terminated by
signal N] for killed or crashed children.

Verified on the OS: cat on a missing file reports exit code 1; a
window-close (clean exit 0) stays silent as it should.

Co-Authored-By: Claude Fable 5 <[email protected]>
2026-07-16 16:59:17 +02:00
danielandClaude Fable 5 54c0584b85 refactor: move the native devkit from 0:/usr to 0:/sdk (Montauk SDK)
0:/usr was a Unix transplant in an otherwise Montauk-native layout.
The SDK now lives at 0:/sdk/{bin,include,lib} (+ ldscripts under
0:/sdk/x86_64-montauk): Montauk-flavored, and a clean unit for a
future per-component installer tickbox. Native binutils is rebuilt
with --prefix=/sdk so ld's compiled-in search paths follow; future
ports configure with --prefix=/sdk.

Also add pathconf() with _PC_* names to the libc: now that realpath
exists, libiberty's lrealpath.c compiles its pathconf fallback path
unconditionally.

Shell command resolution and tab completion updated to 0:/sdk/bin.
Boot-verified in QEMU: setup, login, desktop on the new image with
zero usr/ remnants in the ramdisk.

Co-Authored-By: Claude Fable 5 <[email protected]>
2026-07-15 09:11:05 +02:00
danielandClaude Fable 5 fe040f8fea feat: ship native dev tools and target sysroot at 0:/usr
The devkit target in programs/GNUmakefile stages the native binutils
(as, ld, ar, nm, objcopy, objdump, readelf, ranlib, strip, size,
strings, addr2line, c++filt, elfedit as *.elf) into the image at
0:/usr/bin, plus a target-side sysroot: libc headers, montauk/ and
Api/ SDK headers and the freestanding C++ set at 0:/usr/include, and
libc.a + crt1/crti/crtn objects (with empty libm/libstdc++ stand-ins)
at 0:/usr/lib. ld's ldscripts ship under 0:/usr/x86_64-montauk.

The /usr prefix matches the binutils configure prefix, and the kernel
already resolves driveless absolute paths against the cwd drive, so
compiled-in /usr/lib search paths work natively on drive 0.

The shell resolves commands from 0:/usr/bin (after 0:/os) and tab
completion lists it. When toolchain/native/ has not been built, the
devkit step skips cleanly and the image builds as before.

Co-Authored-By: Claude Fable 5 <[email protected]>
2026-07-14 20:53:57 +02:00
danielandClaude Fable 5 bd9158fdcc feat: POSIX libc surface, native binutils (as/ld/ar run on MontaukOS)
Grow the Montauk libc enough to cross-build binutils 2.43.1 with
--host=x86_64-montauk. gas, ld, ar, nm, objcopy, objdump, readelf,
ranlib, strip and friends now link as native ET_EXEC Montauk binaries
(staged stripped in toolchain/native/, not yet shipped in the image).

New libc surface: full Linux errno and signal sets, O_* flags with
real O_EXCL/O_APPEND semantics, unlink/rmdir/dup/dup2/getpid/_exit,
kill (SYS_KILL), fcntl, fileno/fdopen, putc/getchar/rewind,
ctime/asctime, strtoll/strtoull/atoll, bsearch, mkstemp/mktemp,
realpath (lexical, drive-prefix aware), mbstowcs/mblen, chmod/fchmod/
umask/utime no-ops (VFS has no modes or settable times), full struct
stat with fake inodes, sscanf field widths (bounded conversions),
SCN*/PRI* completions, wait/waitpid over SYS_WAITPID, and new headers
sys/wait.h, sys/param.h, utime.h, wchar.h, memory.h.

fork/exec/pipe are declared but fail with ENOSYS: binutils never
spawns, and real process plumbing is the posix_spawn milestone, which
needs kernel support (exit status reporting, fd redirection).

TCC's montauk_compat.h shims (unlink, chmod, execvp, realpath, fdopen,
strtoll, strtoull) are retired in favor of the libc versions.

Co-Authored-By: Claude Fable 5 <[email protected]>
2026-07-14 10:55:39 +02:00
danielandClaude Fable 5 648f7111c0 feat: build userspace programs with the x86_64-montauk toolchain
Switch all program and library Makefiles from host g++ (or the
bare-metal x86_64-elf compiler) to x86_64-montauk-g++/gcc and drop the
flags the target now owns: -nostdinc + kernel freestanding -isystem
paths, -m64/-march, -fno-PIC, -mno-red-zone, -mcmodel=small, -static,
-Wl,-m,elf_x86_64, -z max-page-size, --build-id=none. Deliberate
policy flags stay (-ffreestanding, per-app SSE, -nostdlib + link.ld).

Program builds now require the montauk toolchain and fail with a
pointer to build-montauk-toolchain.sh; lib/ and libs/ keep the host
fallback since the toolchain script bootstraps libc through it.
Userspace is also now pinned to the cross GCC instead of drifting
with the distro compiler.

Co-Authored-By: Claude Fable 5 <[email protected]>
2026-07-14 10:19:35 +02:00
danielandClaude Fable 5 e1a5364824 fix: eliminate desktop stall when deleting large files
Deleting a big file froze the desktop for seconds: ext2 FreeBlock did 4
synchronous disk I/Os per data block (bitmap + BGDT read/write), and the
file manager deleted single files inline on the desktop main thread.

- Ext2: batch block frees per block group; keep the bitmap resident,
  clear bits in memory, flush bitmap + BGDT once per group transition.
  Also covers the truncate-on-overwrite path.
- Ext2: refuse to mount volumes with block size > 4096; temp buffers
  throughout the driver are single 4 KiB pages, so larger blocks would
  overflow them (our mkfs always uses 4K).
- Files: route single-file deletes past 4 MiB to the background worker
  + progress dialog; refuse (instead of stalling inline) when another
  file operation already owns the worker.

Co-Authored-By: Claude Fable 5 <[email protected]>
2026-07-09 23:20:19 +02:00
daniel c3d157e880 feat: add warning in DOOM for missing wad 2026-07-09 11:43:21 +02:00
danielandClaude Fable 5 bd7ad4f5d6 feat: default login-screen wallpaper
Ship a default wallpaper (blossoms by Nikhil Kumar, Unsplash License) in
a new 0:/os/wallpapers/ directory for OS-provided imagery, staged from
programs/data/wallpapers/. login.elf falls back to
0:/os/wallpapers/default.jpg when the desktop config names no wallpaper
or the configured file cannot be opened. Attribution added to
THIRD-PARTY-NOTICES.txt and man legal.

Co-Authored-By: Claude Fable 5 <[email protected]>
2026-07-08 16:07:27 +02:00
danielandClaude Fable 5 99997dd822 fix: display Bluetooth MAC addresses in conventional MSB-first order
bdAddr bytes are stored LSB-first (HCI wire order) throughout the stack,
but the bluetooth app and btbonds tool formatted them LSB-first too, so
every MAC displayed byte-reversed. Print addr[5] down to addr[0] instead.
Display-only change; wire-order parsing and syscalls untouched.

Co-Authored-By: Claude Fable 5 <[email protected]>
2026-07-08 10:57:48 +02:00
daniel 78494cb072 feat: add header dependency tracking for programs 2026-07-08 10:24:21 +02:00
daniel 857122c07c cleanup: rename shared libraries to remove 'lib' prefix 2026-07-08 10:12:32 +02:00
daniel 9eccdd9334 cleanup: remove test programs/libraries 2026-07-08 10:06:07 +02:00