Building and Using the Fiasco µ-Kernel
To compile Fiasco, you need:
- The GNU C++ compiler, version 4.1, 4.2 or 4.3
GNU Binutils recent version.
The only compilation environment we've tested is Linux/ELF on x86.
- GNU Make. If GNU Make is not called
make' on your system, substitute its name in the
- Perl version 5.6 or higher, needed for preprocessing.
Flex and Byacc. (If you don't have Byacc, but Bison, try setting
"bison -y" in the L4 configuration menu under "Compilers and Tools".
Other Yacc implementations might do it as well.)
- Python2, needed for the configuration tool, available in the system
To run Fiasco, you need:
- A PC with an x86 CPU from i486 up. A Pentium-class CPU
is recommended. Fiasco doesn't yet support SMP.
- At least 2 MB of RAM. Fiasco currently can manage up to 1GB RAM.
The steps nessecary to build a Fiasco kernel are as follows:
Get Fiasco and needed modules from our read-only SVN.
How to get all the needed modules from our SVN is described
Checkout the hello module to get everything (Recommended):
The hello module contains more than what is actually needed, so
don't be scared!
If you're only interested in Fiasco itself (i.e. compile without
Roottask, Sigma0, etc.), the following suffices:
make in the l4/tool/preprocess
directory, it won't work because of the missing l4 checkout and it's NOT
necessary to build Fiasco!
- Check configuration.
(Only needed when choosing 1a))
Configure the L4 system libraries and support servers:
Most likely you do not need to change anything, so
make -C l4 O=/my-user-build-dir oldconfig
oldconfig is ok. If you want to change something you
may also take the
/my-user-build-dir is any directory you like. That's the location
where any generated file will be put in.
- Compile the L4 system libraries and support servers.
a) Compilation when you've checked out the whole L4 tree:
This will build all packages that you have checked out and that
are necessary to run Fiasco with some programs.
b) When building Fiasco only:
Nothing needs to be done here, proceed with the next point.
First, create a build directory using:
The path given to
make BUILDDIR= can either be absolute or
Now change to your build directory to configure the kernel.
make menuconfig the kernel configurator will be
started. You can now configure your kernel.
Use the 'h' key to get help, use the arrow
keys to navigate through the menus and space to switch the options, use
'x' to save and exit.
At this stage, your kernel should be properly configured, so you
can proceed to building it:
This should create a binary named `
fiasco pointing to
An even faster way to build a preconfigured fiasco kernel is to go
kernel/fiasco and call
This will build a fiasco kernel with the ia32-short template in the
If you're looking for Fiasco-UX (the Fiasco port to Linux User space),
you probably want to take a look at its own page.
To boot Fiasco, you need:
- The bootstrap binary can be found at
$(ARCH) is something like
$(L4API) is something like
- The Fiasco binary at
- The Sigma0 pager. It is the first user-level server started by
Fiasco. Sigma0 has been built in step 2 in the previous
section. Its binary can be found at
resource manager Roottask. Roottask is the second server
started by Fiasco.
Roottask also has been built in step 2 in the previous section. The
Roottask binary can be found at
- At least one L4 application program. For demonstration
purposes, we will use the Hello World server which also has
been built in step 2 in the previous section and can be found
server is another very popular Fiasco application program.
- The GRUB bootloader. I
won't discuss here how to build and install GRUB; for
information about that please visit the GRUB website.
For the examples below, I'll assume you use the courtesy GRUB
boot floppy we provide (see the download page for details).
- A typical
menu.lst file looks as follows:
title hello world
module (fd0)/fiasco -nokdb
When booted, you should see the hello word server repeatedly
printing its thread id.
- If you leave out the "
-nokdb" option for Fiasco
(see step 3 in the previous section), Fiasco would enter a
kernel breakpoint at startup and try to connect to a remote GDB
connected via a serial line (COM1).
- Other Fiasco command line options are documented in
the Fiasco online manual page.
Fiasco can be source-level-debugged using a remote debugger running on
a second machine via a serial connection: Just connect one of your
test machine's serial ports (default: COM1) to your development host
using a null-modem cable. Edit
match your host's serial port, add "
-wait" to the boot
option of your GRUB config file, reboot Fiasco, and start your GDB
(or your favorite GDB-based debugger) when the "KDB: init" message
appears. You can then set breakpoints, continue the execution, and
even interrupt Fiasco by typing Control-C in the debugger.
Another way to debug Fiasco is using Fiasco's built-in low-level
debugger. This debugger has its own manual, which you can find on the
Developing for Fiasco
To develop applications for Fiasco, you can use the L4 development
environment, including some libraries in
most important library is Libl4sys which provides C bindings for L4
For more information, please visit the L4/x86 Developer's
Resources page, and have a look at the Libl4sys manual
If you are developing for L4, we also suggest that you subscribe to the
L4-Hackers mailing list.
Reporting a bug in Fiasco
To report a bug in the Fiasco µ-kernel, please use
the l4-hackers mailing list.
If you have corrections or additions to this document, please send them to
its current maintainer Adam.
Last modified: Fri Mar 13 2009, 13.39:11 CET