Re: How to start porting to a new ARCHITECTURE?
-----BEGIN PGP SIGNED MESSAGE-----
Michelle Konzack wrote:
> since 2007-08-01 I am now jobless (yeah, the new French GOV do not like
> that I stay in the army as PMC) and today (Saturday) I was asked by an
> owner of a german Enterprise whether it is possibel to port GNU/Linux,
> specialy Debian to this new ARCHITECTURE.
> Now I need to ask you, how one should start this?
You've got two major tasks ahead of you:
- - port gcc
- - port the kernel
- - cross-compile a basic userland
For the former, you'll need to write a new gcc backend targeting your
architecture, and then add support to binutils to allow programs to be linked.
This is not easy. gcc's innards tend to drive people mad.
Once you have a compiler, you can then port the kernel --- this will require
development hardware with a good debugger (or, preferably, a reliable emulator
with built-in debugger support). You'll be wading neck-deep in the inside of
the kernel, although I gather it's not as bad as it used to be these days.
Now you have both a compiler and a kernel, you can use your compiler to
generate a userland --- as set of basic binaries to get your system up and
running --- and then boot your new system. This isn't too difficult, although
cross-compiling on gcc has its own horrors.
Once you've got it reliably self-hosted, you're most of the way there ---
setting up a basic Debian port is relatively straightforward.
I'd suggest looking up a gcc and linux-kernel mailing list and asking there
for more detailed info.
┌── ｄｇ＠ｃｏｗｌａｒｋ．ｃｏｍ ─── http://www.cowlark.com ───────────────────
│ "There does not now, nor will there ever, exist a programming language in
│ which it is the least bit hard to write bad programs." --- Flon's Axiom
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
-----END PGP SIGNATURE-----