Zeta is the name of a virtual platform, or architecture.

There are specifications (see the handbook), and a basic, not-yet-optimised emulator (cpu, ram, clock, mainboard). The architecture is simple, barely having the minimum needed to run linux with MMU.

The purpose is to play with the toolchain and the linux kernel, to learn more about those core technologies. Binutils and gcc are already ported at 80%. (No static lib nor PIC code yet, userland compilation untested.) Using those tools (as "cross-compilers"), the real work can now begin : porting linux to Zeta. This is still work in progress. This kernel is called ZetaLinux.

Zeta is designed and written by Thomas Capricelli


Zeta 0.7 was released in late november 2009. This release is based on:

Version of external tools used:

binutils 2.20
gcc 4.4.0
linux kernel 2.6.32-rc8

The whole toolchain was tested on i386 and amd64 host platforms.

Very quick start

You can download the kernel (vmlinux-zeta-0.x.raw) and the main tarball (zeta-0.x.tar.bz2) from the file tab, compile the emulator from the 'emulator' directory by doing :

orzel@berlioz zeta% make ramdisk.romfs
orzel@berlioz zeta% cd emulator
orzel@berlioz zeta/emulator% make

And then start the kernel:

orzel@berlioz zeta/emulator% ./load_kernel <path to your vmlinux-zeta-0.x.raw>

I'll let you find out from the quickstart how to use the gui emulator to do the same.

Get the code

There are four components:
  • Zeta-binutils is a port of binutils to Zeta
  • Zeta-gcc is a port of gcc to Zeta
  • Zeta-linux is a port of the linux kernel to Zeta
  • Zeta is the main repository, with specification, documentation, test cases and the emulator.

The last releases are available from the file tab at the top of this page.

If you feel like using the bleeding edge development, you can also fetch the very latest code from our source control. I use mercurial (homepage) for this, and highly recommend it. The repositories are available from http://sources.freehackers.org


We will describe here a kind of '''Zeta Demonstration'''. The aim is for you to have a zeta kernel booting on your computer starting from nothing. This is the quickstart for Zeta 0.7, it will probably not apply "as-is" to other versions.

What you need :
  • Zeta source code for the four components (see at the beginning of this page).
  • 250 Mb of free space on you hard disk.
  • /opt/zeta writable by your user account.

(You can edit the top of zeta.binutils/Makefile and zeta.gcc/Makefile if you want to use something else than /opt/zeta)

From the Zeta repository, check your environment:

orzel@berlioz zeta% make check
Host tools checked :
        genromfs :  genromfs 0.5.2
        gmake    :  GNU Make 3.81
        Binutils :  GNU ld (GNU Binutils) 2.20
        GCC      :  gcc (Gentoo 4.4.2 p1.0) 4.4.2 
(Everything seems ok)

Install the binutils from your checkout of zeta.binutils

orzel@berlioz zeta.binutils% make install

That should end with something like

gmake[4]: Leaving directory `/home/orzel/hg/zeta.binutils/build/libiberty/testsuite'
gmake[3]: Leaving directory `/home/orzel/hg/zeta.binutils/build/libiberty'
gmake[2]: Nothing to be done for `install-target'.
gmake[2]: Leaving directory `/home/orzel/hg/zeta.binutils/build'
gmake[1]: Leaving directory `/home/orzel/hg/zeta.binutils/build'
orzel@berlioz zeta.binutils%

Install gcc from your checkout of zeta.gcc

orzel@berlioz zeta.gcc% make install

That should end with something like

gmake[4]: Leaving directory `/home/orzel/hg/zeta.gcc/build/zeta-unknown-linux/libgcc'
gmake[3]: Leaving directory `/home/orzel/hg/zeta.gcc/build/zeta-unknown-linux/libgcc'
gmake[2]: Leaving directory `/home/orzel/hg/zeta.gcc/build'
gmake[1]: Leaving directory `/home/orzel/hg/zeta.gcc/build'
orzel@berlioz zeta.gcc%

The next step is to check your toolchain. You do so by following the description on global tests.

We can now cross compile the zeta kernel, from your checkout of zeta.linux:

orzel@berlioz zeta.linux% make oldconfig # just in case
orzel@berlioz zeta.linux% make clean     # just in case
orzel@berlioz zeta.linux% make
  AS      .tmp_kallsyms2.o
  LD      vmlinux
  SYSMAP  System.map
  SYSMAP  .tmp_System.map
/opt/zeta/bin/zeta-unknown-linux-objcopy -O binary -R .note -R .comment -R .stab -R .stabstr -S vmlinux vmlinux.raw
orzel@berioz zeta.linux%

Now we compile the emulator, from the main 'zeta' repository/checkout. You need to give the path to the 'vmlinux.raw' file in your zeta.linux checkout, which, on my computer is ~/hg/zeta.linux/vmlinux.raw:

orzel@berlioz zeta% cd emulator
orzel@berlioz zeta/emulator% make
orzel@berlioz zeta/emulator% ./load_kernel ~/hg/zeta.linux/vmlinux.raw

        Zeta Emulator (C) Copyright 2000-2009 Thomas Capricelli
  /     \                                                      
 |  ***  |    Loading kernel  = /home/orzel/hg/zeta.linux/vmlinux.raw
 |    *  |    at 0x0, size = 1206002 = 0x1266f2                      
 |   *   |    Loading ramdisk = ../ramdisk.romfs                     
 |  *    |    at 0x200000, size = 0 = 0x0                            
 |  ***  |    Execution begins at 0x0                                
  \     /     Loading Symbols : ../linux/System.map                  

If you have Qt-4 installed, you can use the Graphical user interface :

orzel@berlioz zeta/emulator> cd gui
orzel@berlioz zeta/emulator/gui> qmake # be sure it is qmake from qt4
orzel@berlioz zeta/emulator/gui> make
orzel@berlioz zeta/emulator/gui> ./zeg ~/hg/zeta.linux &

Then click on this icon to have the kernel booting :

Developer information

The handbook describes tests further.


The whole code of the Zeta project is released under the GNU General Public License version 2 (GPL).

Future goals, ideas

  • use t2-project to create the first distribution ?
  • there are lot of testing suites over there..
  • even benchmarks, such as nbench
  • documentation for tests in the handbook
  • uclib
  • busybox
  • framebuffer
  • qtopia
  • opie, etc..

Zeta_header.png (19.5 KB) Thomas Capricelli, 06/23/2009 08:30 PM

screenshots.png (12.1 KB) Thomas Capricelli, 06/23/2009 10:24 PM

Quickstart-zeg.png (12.6 KB) Thomas Capricelli, 11/29/2009 06:41 AM