Commit Graph
18 Commits
Author SHA1 Message Date
danielandClaude Fable 5 f234c67a2b feat: native GCC - cc1, cc1plus and the gcc driver run on MontaukOS
Cross-build GCC 14.2.0 with --host=x86_64-montauk: the driver, cc1,
cc1plus and collect2 now link as static Montauk ET_EXEC binaries
against the hosted libstdc++, and ship in the SDK. Together with the
native binutils, TCC and the target sysroot, MontaukOS carries a
complete self-contained C and C++ toolchain at 0:/sdk.

libc: anonymous mmap/munmap over SYS_ALLOC (GCC's page allocator
wants mmap; SYS_ALLOC memory is page-aligned by construction),
getpagesize, minimal sysconf, MB_CUR_MAX, isascii/toascii, POSIX id
typedefs (ino_t, dev_t, nlink_t, ...), struct stat fields switched to
proper POSIX types (st_size is a signed off_t now), and a
conventional _STDIO_H guard marker so GMP's FILE detection works.

Build recipe and the five host-build gotchas (bundled config.subs,
gettext removal, stdio guard sniffing, endianness cache preset,
sysroot sdk symlink) are documented in toolchain/README.md. The
devkit stages the driver as gcc.elf/g++.elf/cpp.elf, the backends in
the libexec layout the driver expects, a copy of ld where collect2
searches, and a 0:/tmp scratch dir. Ramdisk: 1604 files, 368 MB.

Co-Authored-By: Claude Fable 5 <[email protected]>
2026-07-16 23:51:30 +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 778f897f1a feat: x86_64-montauk userspace cross toolchain
Add build-montauk-toolchain.sh: builds an OS-aware cross GCC/binutils
(same versions and prefix as the bare-metal x86_64-elf toolchain) whose
x86_64-montauk target links static ET_EXEC binaries against the Montauk
libc sysroot with no special flags: 4 KiB max page size for the kernel
ELF loader, -mno-red-zone by default, crt1/crti/crtn + -lc from the
sysroot, __montauk__ defined. Target patches are checked into
toolchain/patches/, the GCC target header into toolchain/files/.

sys/types.h now includes <stdint.h> so hosted code (libgcov and
friends) sees intptr_t via the stdio include chain.

Co-Authored-By: Claude Fable 5 <[email protected]>
2026-07-14 10:19:35 +02:00
daniel 70539c94dd feat: properties menu in Files and delete confirmation for directories 2026-05-06 17:55:57 +02:00
daniel 74ec062573 feat: bump version; release notes for 0.1.2; archive 0.1.2 iso 2026-05-02 14:53:31 +02:00
daniel 14971e6f02 feat: architectural improvements for Apps and System Configuration virtual folders in Files 2026-04-30 16:51:08 +02:00
daniel 3611535df0 feat: port bluetooth to MTK toolkit 2026-04-17 15:26:27 +02:00
daniel f1b49b3c4e wip: shared library support 2026-04-05 15:14:07 +02:00
daniel e793955a0a fix: add ramdisk.tar to .gitignore 2026-03-01 10:19:38 +01:00
daniel bb1dca1d2c fix: update gitignore 2026-02-24 07:09:54 +01:00
daniel 73c3f5621a fix: interim README change 2026-02-23 20:59:26 +01:00
daniel 9e191f64a9 feat: TrueType (TTF) font rendering, many new desktop applications and DOOM support, among other improvements 2026-02-20 22:46:41 +01:00
daniel 0106a9e881 feat: Desktop improvements 2026-02-20 14:13:25 +01:00
daniel 5810306e14 feat(kernel): Add USB devicde and keyboard/mouse support 2026-02-19 23:06:18 +01:00
daniel fb8d16ee7b feat: expand user mode, add DOOM game, add manpages 2026-02-18 15:13:53 +01:00
daniel e2f059bf90 fix: Cross-compilation & build tools script, IoPort fix 2026-02-17 11:15:43 +01:00
daniel 4d98c6a7d6 fix(kernel/Terminal): Fix Terminal.cpp 2025-06-12 08:22:30 +02:00
Daniel Hammer 6f1c6f1316 GDT, page frame allocator 2025-02-27 19:48:03 +04:00