The ClaraOS logo: a sun

A small operating system for x86_64 and AArch64, written to be read from the first instruction up.

Those two lines at the top are what the kernel prints when it takes over from the firmware. ClaraOS is a Lisp machine in the making: a C kernel small enough for one person to hold in their head, under a world written in Common Lisp. It has a window manager, and a world that was saved in it boots straight into it; its applications are Lisp programs, a text editor named Emma, a file browser named Jaid and a web browser named Ares among them, each loaded from its file when it is first picked. Its Lisp has a compiler, written in that Lisp, and everything in the world is compiled by it, the compiler included, and then translated into the instructions of the processor itself, which runs it with nothing in between. It is not a Unix, and it does not try to run Linux software.

The substrate is the C kernel. It brings up the processor, hands out memory, runs threads, takes interrupts, and holds the Lisp runtime itself: the reader, the evaluator, the machine that runs compiled code and the garbage collector.

The world is Lisp: the console and the REPL, the logic of the drivers, the filesystem, the window manager and every application.

One address space, one heap, no user mode. Lisp code cannot forge a pointer, so protection comes from the language and not from page tables. An application that fails is a condition for the window manager to handle.

The Lisp is a subset of Common Lisp, chosen so that every file also loads under SBCL on an ordinary computer, where it is written and tested.

The image is the system. The whole Lisp world can be saved to the disk, and a machine that finds it there starts from it, with everything that was defined. A world that was saved with the window manager running starts in it.

Version 0.0.86. 40 of 40 milestones are finished, the latest being M21c, Intel's sound card, and the work since then comes from the issues of the repository. A milestone counts as finished when the machine boots and passes its own checks on both architectures.

Milestones lists every version and what it brought, and the roadmap says what each of them holds and what was left open along the way.

The ClaraOS window manager at the end of a boot that started from a saved world. Along the top of the screen is a bar with the word Applications at its left end and, at the right, ClaraOS and its version and after them a clock, the day and the time at which the picture was taken, in Greenwich: all in the smooth letters of a font of outlines, as the titles of the windows are. A window named REPL shows four forms, their parentheses in pink and, where one pair lies inside another, in blue: the first was typed before the world was saved, and the arrow up has brought it back to be read again; the second is that line once more, with the word list and a parenthesis typed into the middle of it, where the arrow left had taken the cursor; the third is a loop without end that Ctrl-C stopped, answered with the words interrupted from the keyboard. Over its right half lies the window of Emma, the text editor: its title is Emma - /clara/hello.lisp, the name of a file after the editor's own, and it shows the thirteen lines of that file, a small application written in Lisp, each pair of its parentheses in a colour of its own, pink for the outermost and then blue, yellow, purple, orange and green for the pairs inside, with a row below them that says 13 lines, and line 1, column 1. Over the lower left corner lies the window of Jaid, the file browser, whose title is Jaid - /clara/, the name of a directory after its own, with a list of names in it, the first of them picked: the way up, the directory of the system that runs, which is named by its version and the digits of its build, a file with a long name, clara.image, which is the world that was saved, hello.lisp and more. At the lower right is a smaller window named A picture, with a picture in it: the title ClaraOS in bold letters, five squares of colour and the words drawn in Lisp in italics, both in that font. And on the REPL's window, to the left of Emma's, lies a small one that has the focus, whose title is the word Emoji and a sun with a face: in it is a row of seven emoji, each a picture in its own colours and two letters wide, a sun, a rainbow, a rocket, a party popper, a waving hand, a red heart and a laptop. The pointer, an arrow, is in the middle of the screen.
The screen of version 0.0.86 on AArch64 under QEMU, in a world that an earlier boot saved with the window manager running, after the boot test has typed its session: on the keyboard, into the REPL's window, and on the serial port, whose last forms opened the window with the picture and launched Jaid, the file browser, and Emma, the editor, on a file that the boot before wrote, and wrote a row of emoji into a window of its own.

On macOS with Homebrew. clang builds both architectures and QEMU boots them, with the same firmware UTM uses.

brew install llvm lld qemu sbcl
git clone https://github.com/the-clara-os/clara-os
cd clara-os
make test          # boot both architectures without a window
make run-aarch64   # a QEMU window, the serial port on your terminal: type a form

At the prompt, (clara.windows:start) starts the window manager in the QEMU window.

The user manual has the rest: running it in UTM, working at the prompt, files, saving the world, windows, and what to do when something goes wrong.