Open source operating system written in Rust and Assembly
Rust Assembly Makefile
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
crates
docs
src
.editorconfig
.gitignore
BUILDING.md
CONTRIBUTING.md
Cargo.toml
LICENSE.md
Makefile
README.md
x86_64-mirus.json

README.md

mirus CircleCI

Mirus is a hobby operating system written in Rust and Assembly. Mirus is NOT yet-another-UNIX-clone, but rather a combination of interesting ideas.

About

Mirus is currently under heavy development, and thus is obviously not stable for any intents or purposes at the moment. Eventually, the goal is to be able to perform basic every day tasks on Mirus. Mirus is a hybrid kernel operating system, meaning that while it is modeled after a microkernel, many high priority components are still included in the kernel itself. Mirus is heavily inspired by Windows NT and Plan 9 from Bell Labs.

Features

Mirus is designed largely around the POSIX (2013) specification. While Mirus implements POSIX, it is not aiming to be a fully POSIX compliant operating system, nor a UNIX clone of any type.

What is working

  • Boot, multiboot headers reading
  • 64 bit long mode
  • Virtual memory manager
  • Physical memory management
  • Paging
  • Simple VGA driver
  • (some) Interrupts
  • Exception handling
  • Return from interrupt (breakpoints, etc.)

What is not

  • 256 interrupt handlers
  • Filesystem (ext2 and then mirfs)
  • Ramdisk
  • Executable loading (ELF64)
  • Keyboard
  • Processes
  • Multitasking
  • Kernel debugger/logger

Building

Dependencies

  • yasm
  • grub2
  • xorriso
  • x86_64 cross compiled GNU binutils
  • Nightly Rust compiler
  • xargo

binutils

You will need to create a cross-compiled binutils package in order to properly build Mirus on any platform. Your cross compilers must target x86_64-elf.

Rust

You will additionally need the latest nightly builds of rustc. I recommend you use rustup to install them. Make sure to set your target triple to x86_64-unknown-linux-gnu

Source Code

$ git clone git@github.com:joshbeitler/mirus.git

Building the kernel

To build the kernel, simply run make in the root directory. If you want to build and then run QEMU, use make run instead. Make will fetch all Rust dependencies and build the kernel.

Making disk images

If you only want an ISO image, run make iso. The resulting image will be located in the build/ directory.

Debugging

In order to debug Mirus, use either lldb or gdb. As I develop on OS X, I use LLDB to do so, as I found that the GDB in Homebrew's repositories does not support my kernel executables. Both LLDB and GDB will be able to connect to QEMU's remote debugging ports.

License

The Mirus kernel and related components are released under the Apache License, Version 2.0. Certain components of the kernel are released under the GPL license, such as the GRUB boot loader and multiboot.h.

Copyright 2016 Joshua Beitler, Mirus Project

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.