Ubuntu 7.04 on Zaurus 
Okay, so here it is then, version 0.3 of Frisky-Firedrake for the Zaurus, the Ubuntu 7.04 "Feisy Fawn" release for Zaurus.

It is first of all a work in progress copy of my most minimal installation, based on the excellent work done by the people of the Mojo project. I want to thank Paul aka speculatrix for hosting the image files.

I messed up a lot of times now by installing far too much packages, ending up with a mess most of the times. I tried to keep in mind that the targeted Zaurus is a small device without unlimited amounts of memory and disk space. That's why I thought maybe a full blown (gnome) desktop is a bit too heavy. I tried several alternatives, like icewm and enlightenment. They all work, but I decided to install none of them on default. Since this is a matter of taste, I leave these kind of choices for you to make. It's simply a matter of running 'apt-get install whatever-package' most of the time actually.

For starters, you may be best of using icewm by running 'apt-get install icewm'. The Xserver is installed already on default. I've created a /root/.xinitrc file and added a line 'exec icewm-session'. Don't forget to edit this file (using nano or mc) when you install any other window manager (for instance, exec enligthenment for e17).

This root filesystem is a version 0.1. Why? because it's not ready for prime time yet, and needs lots of tweaking and fiddling. It can be set up to run on your Zaurus of course, but I prefer to use it in Qemu for the time being.

If you really want to install the image onto your Zaurus already, simply use the Android installation files, and copy and rename the zubuntu-minimal-rootfs.tar.gz into android-rootfs.tar.gz. Then install as if it were Android (use the instructions in the menu on the left). A Zaurus keymap can be found in /etc/keymap-2.6.map. Install console-tools first so you'll be able to run 'loadkeys /etc/keymap-2.6.map'. See for yourself what works and what doesn't work, or wait for a next version that is tested ok by me and others for the Zaurus. I've already spotted quite some Ubuntu 7.10 "Grumpy Griffin" packages, so...

For the time being, I will stick with Qemu for a while, until I'm satisfied with the setup. To set this up for use in Qemu, perform the following steps.

1. Making preparations for running Zubuntu in Qemu


a. Install (or build) Qemu on your host. Google for a howto if you need. You can even use Qemu for Windows to configure your zaurus-ubuntu in Windows if you like! Just make sure qemu-system-arm is included.

b. Create an installation directory
host$ mkdir -p ~/src/ubuntu
b. Download zubuntu-minimal-rootfs.tar.gz into ~/src/ubuntu
c. Download zImage-versatile-2.6.24-rc7.armv5tel into ~/src/ubuntu

2. Creating the file system on loopback device


You can make it any size of course, but 4Gb matches the internal Zaurus disk of my SL-C3100, so it's kind of representative. I've tested this with a 1Gb filesystem, and never ran out of diskspace (so far).
host$ cd ~/src/ubuntu
host$ dd if=/dev/zero of=ubuntu-qemu bs=1MB count=4096
host$ sudo mke2fs -F -m 0 -b 1024 ubuntu-qemu

3. Installation of the root filesystem

host$ cd ~/src/ubuntu
host$ mkdir qemu
host$ sudo mount -t ext2 -o loop ubuntu-qemu qemu
host$ cd qemu
host$ sudo tar -zxpf ../zubuntu-minimal-rootfs.tar.gz
host$ cd ..
host$ sudo umount qemu

4. Start Zubuntu in Qemu


I've struggled quite some time to get a working network connection in Qemu, and ended up with this (for me working) setup. No bridging required!
host$ sudo qemu-system-arm \
-M versatilepb -kernel zImage-versatile-2.6.24-rc7.armv5tel \
-append "root=/dev/sda ip=bootp" \
-hda ubuntu-qemu \
-net nic -net user,script=/etc/qemu-ifup
After Qemu boots, login with root and enter a new root password twice. After that, lets see if it works
host$ date -s "05/07/2008"
host$ apt-get install icewm
host$ startx
IceWM should start now.

5. Making adjustments, fixing, patching etc


At this point you're running Zubuntu in an ARM emulator, roughly comparable to the Zaurus. You'll find that by doing this, fixing stuff, experimenting with packages, trying different configurations or setups is much, much easier than doing this on your Zaurus. There is of course Zaurus-specific stuff (like the keyboard mapping), but most stuff can be done from the emulator.

6. Creating a new root filesystem


If you're finally happy with your setup, and think it's time to try it out on your Zaurus, you can easily (re)create a root filesystem to be flashed on your Zaurus. It is important that you exit the emulator first.

Create a new root filesystem by simply doing
host$ cd ~/src/ubuntu
host$ sudo mount -t ext2 -o loop ubuntu-qemu qemu
host$ cd qemu
host$ sudo tar -czpf ../zubuntu-custom-rootfs.tar.gz .
host$ cd ..
host$ sudo umount qemu

As said before, copy and rename the zubuntu-minimal-rootfs.tar.gz into android-rootfs.tar.gz. Then install onto your Zaurus as if it were Android (use the instructions in the menu on the left).

7. Known errors


Most errors should be easy to fix. If you find other errors, or better, if you have any solutions to these problems, please share them here!

Known errors are currently:
* perl keeps complaining about missing locale information
* apt-get update complains about a GPG Error
* lots of initscript errors during boot
* ucf install error
* Hardware clock problem
* Sound is not working (forgot to install alsa)
* Automatic rotation not working

So far, I ignored these without any problem, but it doesn't mean they don't need to be fixed of course.

Again, if you have any fixes, scripts, enhancements etc, please share them here!