Main » History » Version 12
Thomas Capricelli, 11/29/2009 06:30 AM
1 | 4 | Thomas Capricelli | !=Zeta_header.png! |
---|---|---|---|
2 | |||
3 | 9 | Thomas Capricelli | {{toc}} |
4 | 3 | Thomas Capricelli | |
5 | Zeta is the name of a virtual platform, or architecture. |
||
6 | 1 | Thomas Capricelli | |
7 | 10 | Thomas Capricelli | !>screenshots.png!:/projects/zeta/wiki/screenshots |
8 | 6 | Thomas Capricelli | |
9 | 3 | Thomas Capricelli | 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. |
10 | |||
11 | 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%25. (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. |
||
12 | |||
13 | 1 | Thomas Capricelli | Zeta is designed and written by "Thomas Capricelli":http://www.freehackers.org/thomas/free-software/ |
14 | 3 | Thomas Capricelli | |
15 | 9 | Thomas Capricelli | h1. Status |
16 | 3 | Thomas Capricelli | |
17 | 1 | Thomas Capricelli | Zeta 0.6 was released in july 2007. The toolchain and the kernel were updated to latest version, and the handbook has been improved. |
18 | 3 | Thomas Capricelli | |
19 | 6 | Thomas Capricelli | Version of external tools used: |
20 | 3 | Thomas Capricelli | <pre> |
21 | BINUTILS_VERSION = 2.17 |
||
22 | GCC_VERSION = 4.1.2 |
||
23 | KERNEL_VERSION = 2.6.22 |
||
24 | </pre> |
||
25 | 1 | Thomas Capricelli | |
26 | 3 | Thomas Capricelli | The whole chain was tested on i386 and amd64 host platforms. |
27 | |||
28 | 9 | Thomas Capricelli | h1. Get the code |
29 | 3 | Thomas Capricelli | |
30 | All the code can be found on http://sources.freehackers.org/ : you can either download tarballs or clone the repositories using "mercurial":http://en.wikipedia.org/wiki/Mercurial_(software) ("homepage":http://mercurial.selenic.com/wiki) if you know what this is. |
||
31 | |||
32 | There are 4 repositories: |
||
33 | * Zeta-binutils is a port of binutils to Zeta |
||
34 | 1 | Thomas Capricelli | * Zeta-gcc is a port of gcc to Zeta |
35 | 3 | Thomas Capricelli | * Zeta-linux is a port of the linux kernel to Zeta |
36 | * Zeta is the main repository, with specification, documentation, test cases and the emulator. |
||
37 | 1 | Thomas Capricelli | |
38 | 11 | Thomas Capricelli | h1. Quickstart |
39 | |||
40 | 12 | Thomas Capricelli | 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. |
41 | 1 | Thomas Capricelli | |
42 | 12 | Thomas Capricelli | What you need : |
43 | * Zeta source code for the four repositories (see the [[Main]] page) |
||
44 | * 250 Mb of free space on you hard disk. |
||
45 | * /opt/zeta writable by your user account |
||
46 | |||
47 | (You can edit the top of zeta.binutils/Makefile and zeta.gcc/Makefile if you want to use something else than /opt/zeta) |
||
48 | |||
49 | From the Zeta repository, check your environment: |
||
50 | 1 | Thomas Capricelli | <pre> |
51 | 12 | Thomas Capricelli | orzel@berlioz zeta%25 make check |
52 | Host tools checked : |
||
53 | genromfs : genromfs 0.5.2 |
||
54 | gmake : GNU Make 3.81 |
||
55 | Binutils : GNU ld (GNU Binutils) 2.20 |
||
56 | GCC : gcc (Gentoo 4.4.2 p1.0) 4.4.2 |
||
57 | (Everything seems ok) |
||
58 | 1 | Thomas Capricelli | </pre> |
59 | |||
60 | 12 | Thomas Capricelli | Install the binutils from your checkout of zeta.binutils |
61 | 1 | Thomas Capricelli | |
62 | <pre> |
||
63 | 12 | Thomas Capricelli | orzel@berlioz zeta.binutils%25 make install |
64 | 11 | Thomas Capricelli | </pre> |
65 | 1 | Thomas Capricelli | |
66 | 12 | Thomas Capricelli | That should end with something like |
67 | 1 | Thomas Capricelli | |
68 | <pre> |
||
69 | 12 | Thomas Capricelli | ... |
70 | gmake[4]: Leaving directory `/home/orzel/hg/zeta.binutils/build/libiberty/testsuite' |
||
71 | gmake[3]: Leaving directory `/home/orzel/hg/zeta.binutils/build/libiberty' |
||
72 | gmake[2]: Nothing to be done for `install-target'. |
||
73 | gmake[2]: Leaving directory `/home/orzel/hg/zeta.binutils/build' |
||
74 | gmake[1]: Leaving directory `/home/orzel/hg/zeta.binutils/build' |
||
75 | orzel@berlioz zeta.binutils%25 |
||
76 | 1 | Thomas Capricelli | </pre> |
77 | |||
78 | |||
79 | 12 | Thomas Capricelli | Install gcc from your checkout of zeta.gcc |
80 | |||
81 | 1 | Thomas Capricelli | <pre> |
82 | 12 | Thomas Capricelli | orzel@berlioz zeta.gcc%25 make install |
83 | 1 | Thomas Capricelli | </pre> |
84 | |||
85 | 12 | Thomas Capricelli | That should end with something like |
86 | |||
87 | 1 | Thomas Capricelli | <pre> |
88 | 12 | Thomas Capricelli | ... |
89 | gmake[4]: Leaving directory `/home/orzel/hg/zeta.gcc/build/zeta-unknown-linux/libgcc' |
||
90 | gmake[3]: Leaving directory `/home/orzel/hg/zeta.gcc/build/zeta-unknown-linux/libgcc' |
||
91 | gmake[2]: Leaving directory `/home/orzel/hg/zeta.gcc/build' |
||
92 | gmake[1]: Leaving directory `/home/orzel/hg/zeta.gcc/build' |
||
93 | orzel@berlioz zeta.gcc%25 |
||
94 | 1 | Thomas Capricelli | </pre> |
95 | |||
96 | 12 | Thomas Capricelli | The next step is to check your toolchain. You do so by following the description on [[tests_zeta|global tests]]. |
97 | |||
98 | We can now cross compile the zeta kernel, from your checkout of zeta.linux: |
||
99 | |||
100 | 1 | Thomas Capricelli | <pre> |
101 | 12 | Thomas Capricelli | orzel@berlioz zeta.linux%25 make oldconfig # just in case |
102 | orzel@berlioz zeta.linux%25 make clean # just in case |
||
103 | orzel@berlioz zeta.linux%25 make |
||
104 | (...) |
||
105 | AS .tmp_kallsyms2.o |
||
106 | LD vmlinux |
||
107 | SYSMAP System.map |
||
108 | SYSMAP .tmp_System.map |
||
109 | /opt/zeta/bin/zeta-unknown-linux-objcopy -O binary -R .note -R .comment -R .stab -R .stabstr -S vmlinux vmlinux.raw |
||
110 | orzel@berioz zeta.linux%25 |
||
111 | 1 | Thomas Capricelli | </pre> |
112 | 12 | Thomas Capricelli | |
113 | 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: |
||
114 | <pre> |
||
115 | orzel@berlioz zeta%25 cd emulator |
||
116 | orzel@berlioz zeta/emulator%25 make |
||
117 | orzel@berlioz zeta/emulator%25 ./load_kernel ~/hg/zeta.linux/vmlinux.raw |
||
118 | |||
119 | Zeta Emulator (C) Copyright 2000-2009 Thomas Capricelli |
||
120 | / \ |
||
121 | | *** | Loading kernel = /home/orzel/hg/zeta.linux/vmlinux.raw |
||
122 | | * | at 0x0, size = 1206002 = 0x1266f2 |
||
123 | | * | Loading ramdisk = ../ramdisk.romfs |
||
124 | | * | at 0x200000, size = 0 = 0x0 |
||
125 | | *** | Execution begins at 0x0 |
||
126 | \ / Loading Symbols : ../linux/System.map |
||
127 | ... |
||
128 | </pre> |
||
129 | |||
130 | |||
131 | If you have Qt-4 installed, you can use the Graphical user interface : |
||
132 | |||
133 | <pre> |
||
134 | orzel@berlioz zeta/emulator> cd gui |
||
135 | orzel@berlioz zeta/emulator/gui> qmake # be sure it is qmake from qt4 |
||
136 | orzel@berlioz zeta/emulator/gui> make |
||
137 | orzel@berlioz zeta/emulator/gui> ./zeg ~/hg/zeta.linux & |
||
138 | </pre> |
||
139 | |||
140 | Then click on this icon to have the kernel booting : |
||
141 | !Quickstart-zeg.png! |
||
142 | 1 | Thomas Capricelli | |
143 | 5 | Thomas Capricelli | |
144 | 1 | Thomas Capricelli | h1. Developer information |
145 | |||
146 | * [[FAQ]] |
||
147 | 9 | Thomas Capricelli | * Tests |
148 | 2 | Thomas Capricelli | ** [[tests_zeta|global tests]] : tests the whole Zeta toolchain |
149 | 5 | Thomas Capricelli | ** [[tests_binutils|binutils]] : binutils upstream tests on Zeta |
150 | 2 | Thomas Capricelli | ** [[tests_gcc|gcc]] : gcc upstream tests on Zeta |
151 | 9 | Thomas Capricelli | ** [[tests_platforms|host platforms]] : checks that Zeta can be compiled/used on different platforms |
152 | 1 | Thomas Capricelli | * [[release checklist]] |
153 | 7 | Thomas Capricelli | |
154 | The handbook describes tests further. |
||
155 | |||
156 | h1. Licencing |
||
157 | |||
158 | The whole code of the Zeta project is released under the GNU General Public License version 2 (GPL). |
||
159 | |||
160 | h1. Future goals, ideas |
||
161 | |||
162 | 1 | Thomas Capricelli | * use "t2-project":http://www.t2-project.org to create the first distribution ? |
163 | * there are lot of testing suites over there.. |
||
164 | * even benchmarks, such as "nbench":http://www.tux.org/~mayer/linux/bmark.html |
||
165 | * documentation for tests in the handbook |
||
166 | * uclib |
||
167 | * busybox |
||
168 | * framebuffer |
||
169 | * qtopia |
||
170 | * opie, etc.. |