Build & Test | |
---|---|
all OS' | |
Linux only |
eduOS-rs is a Unix-like operating system based on a monolithic architecture for educational purposes. It is developed for the course Operating Systems at RWTH Aachen University and includes a modified hypervisor that simplifies the boot process to increase the intelligibility of the OS. eduOS-rs is derived from following tutorials and software distributions:
- Philipp Oppermann's excellent series of blog posts.
- Erik Kidd's toyos-rs, which is an extension of Philipp Opermann's kernel.
- The original version of eduOS, which was the old teaching kernel written in C.
eduOS-rs is tested under Linux, macOS, and Windows.
Apple's Command Line Tools must be installed. The Command Line Tool package gives macOS terminal users many commonly used tools and compilers, that are usually found in default Linux installations. Following terminal command installs these tools without Apple's IDE Xcode:
$ xcode-select --install
To build eduOS-rs you have to install a linker, make and a git client. We tested the eduOS-rs with the linker from Visual Studio. Consequently, we suggest installing Visual Studio in addition to make and git.
Linux users should install common developer tools. For instance, on Ubuntu 18.04 the following command installs the required tools:
$ apt-get install -y curl wget nasm make autotools-dev gcc g++ build-essential
It is required to install the Rust toolchain. Please visit the Rust website and follow the installation instructions for your operating system. It is important that the nightly channel is used to install the toolchain. This is queried during installation and should be answered as appropriate.
Afterwards the installation of cargo-xbuild and the source code of Rust runtime are required to build the kernel:
$ cargo install cargo-xbuild
$ rustup component add rust-src
eduOS-rs is able to run within ehyve, which a specialized hypervisor for eduOS-rs. Therefore ehyve must be installed.
$ cargo install --git https://github.com/RWTH-OS/ehyve.git
Please check if your system fullfil ehyve's system requirements.
The final step is to create a copy of the repository and to build the kernel:
$ # Get our source code.
$ git clone https://github.com/RWTH-OS/eduOS-rs.git
$ cd eduOS-rs
$ # Build kernel
$ make
From here, we should be able to run the kernel in ehyve:
$ make run
Step by step (here branch by branch) the operating system design will be introduced. This tutorial shows the steps to develop from a minimal kernel to a Unix-like computer operating system. Currently, following stages of development are available:
-
stage0 - Smallest HelloWorld of the World
Description of loading a minimal 64bit kernel
-
stage1 - Cooperative/non-preemptive multitasking
Introduction into a simple form of multitasking, where no interrupts are required.
-
stage2 - Priority-based cooperative/non-preemptive multitasking
Introduction into a simple form of priority-based multitasking, where no interrupts are required.
-
stage3 - Synchronization primitives
Introduce basic synchronization primitives
-
stage 4 - Preemptive multitasking
Introduction into preemptive multitasking and interrupt handling
-
stage 5 - Support of user-level tasks
Add support of user-level tasks with an small interface for basic system calls
-
stage 6 - Support of paging
Add support of paging and a simple demo for process creation
-
stage 7 - Integration of an in-memory file system
Introduce a virtual file system with an in-memory file system as example file system.
-
stage8 - Run Linux application as common process
Start a simple Linux application (HelloWorld) on top of eduOS-rs. The application is a position-independent executable (PIE) and use musl-libc as standard C library.
- http://www.gnu.org/software/grub/manual/multiboot/
- http://www.osdever.net/tutorials/view/brans-kernel-development-tutorial
- http://www.jamesmolloy.co.uk/tutorial_html/index.html
- http://techblog.lankes.org/tutorials/
- http://www.os.rwth-aachen.de
- http://www.noteblok.net/2014/06/14/bachelor
- https://sourceware.org/newlib/
- http://rwth-os.github.io/eduOS/
- https://intermezzos.github.io
Licensed under either of
- Apache License, Version 2.0, (LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0)
- MIT license (LICENSE-MIT or http://opensource.org/licenses/MIT)
at your option.