Author Topic: Pdaxrom Builder Setup Guide On Windows Host  (Read 3720 times)

cortez

  • Sr. Member
  • ****
  • Posts: 375
    • View Profile
    • http://www.omegamoon.com
Pdaxrom Builder Setup Guide On Windows Host
« on: July 09, 2007, 07:26:21 am »
I've struggled quite a long time setting up the pdaXrom builder. Since building from within other distributions (I've tried Ununtu and Redhat) didn't work, I started a while back with pdaX86. I'm now finally able to build a complete personalised ROM. It's much easier to cross-compile software from pdaX86 because all host libraries are compatible with the target-Zaurus libraries.

In the good tradition of open source hereby my findings and detailed documentation written down along the way. Hopefully this helps others to setup a development environment quickly, being able to build an even better pdaXrom  

I use Windows XP as my host system, and the VirtualBox virtual machine running pdaX86 as guest.

1. Setup VirtualBox in combination with pdaX86
Code: [Select]
- Create 2(!) virtual harddisks with 25Gb space each (dynamically expanding)
 - Mount pdaXrom.iso as CD-ROM
 - Start virtual machine and login to pdaXrom with 'root'

   # fdisk /dev/hda -> Create new partition
   # fdisk /dev/hdb -> Create new partition
   # mkfs.ext3 /dev/hda1
   # mkswap /dev/hdb1
   # mount /dev/hda1 /mnt/hd
2. pdaX86 harddisk installation
Code: [Select]
# setup-hd /mnt/hd
 # reboot

IMPORTANT: unmount CD before reboot (in VirtualBox)
* On error: "Warning: unable to open an initial console." reboot with CD (mount in VirtualBox)
* Using Midnight Commander (mc from console), copy /dev into /mnt/hd/dev
* Reboot without CD (unmount in VirtualBox)

3. Initial setup
Code: [Select]
  # mkdir ~/zip
   # mkdir ~/src
   # mkdir ~/pdaXrom-builder
   # mkdir ~/work
   # startx
Now download some source packages to build the Subversion client, which we'll need to get the latest pdaXrom-builder.
 - Download Apache httpd-2.2.4 in ~/zip
 - Download openssl.org in ~/zip
 - Download Subversion and the dependencies package (subversion-deps) in ~/zip

Extract the source code as follows:
Code: [Select]
  # cd ~/src
   # tar xjf ~/zip/httpd-2.2.4
   # tar xzf ~/zip/openssl-0.9.8e.tar.gz
   # tar xjf ~/zip/subversion-1.4.4.tar.bz2
   # cd ~/src/subversion-1.4.4
   # tar xjf ~/zip/subversion-deps-1.4.4.tar.bz2
4. Build OpenSSL
Code: [Select]
  # cd ~/src/openssl-0.9.8e
   # ./config
   # make
   # make test
   # make install
5. Build Apache
Code: [Select]
  # cd ~/src/httpd-2.2.4
   # ./configure --enable-ssl --with-ssl=/usr/local/ssl
   # make
   # make install
6. Build Subversion
Code: [Select]
  # cd ~/src/subversion-1.4.4
   # ./configure --with-ssl
   # make
   # make install
   # make clean
   # ./configure --with-neon=/usr/local
   # make
   # make install
7. Preparing the PdaXrom-builder environment
 
Code: [Select]
  # cd ~/pdaXrom-builder
   # svn co https://pdaxrom.svn.sourceforge.net/svnroot/pdaxrom/trunk
8. Preparations for building the VirtualBox Linux Additions
Code: [Select]
  # cd ~/pdaXrom-builder/trunk
   # ./configure i686-livecd-bootstrap ~/work http://distro.ibiblio.org/pub/linux/distributions/pdaxrom/src

The building system is now setup for pdaXrom livecd, target bootstrap

   # cd ~/work
   # uname -a

- Write down the exact kernel version
- Edit ~/work/.config
- Mark out the current kernel (in my case 2.6.17=y) and select the kernel version you just wrote down (in my case 2.6.15=y)

   # make kernel_prepare

Answer all questions with the default option (just press Enter)
   Select only drivers expected to compile cleanly (CLEAN_COMPILE) [Y/n/?] (NEW)
   Legacy /proc/pci interface (PCI_LEGACY_PROC) [N/y/?] (NEW)
   IP tables support (required for filtering/masq/NAT) (IP_NF_IPTABLES) [N/y/?] (NEW)
   ARP tables support (IP_NF_ARPTABLES) [N/m/y/?] (NEW)
   ... lots more ...

   # cd /opt/native/i686/3.4.6-2.2.5/bin
   # ln -s ld i686-cacko-linux-gnu-ld
   # ln -s as i686-cacko-linux-gnu-as
   # ln -s ar i686-cacko-linux-gnu-ar
   # ln -s nm i686-cacko-linux-gnu-nm
   # ln -s objcopy i686-cacko-linux-gnu-objcopy
   # cd ~/work
   # make kernel_compile (on error try again)
   # cd /usr
   # mkdir src
   # cd src
   # ln -s ~/local/work/build/linux-2.6.15 linux
9. Install VirtualBox Guest Additions
9a. Mount VBoxGuestAdditions.iso (in VirtualBox)
9b. Create file /etc/debian_verion which contains the text "4.0" (without parenthesis)
Code: [Select]
  # mount /dev/cdroms/cdrom0 /mnt/cdrom
   # cp /mnt/cdrom/VBoxLinuxAdditions.run ~/zip
   # ~/zip/VBoxLinuxAdditions.run
Strangely enough,  at this point I had to run following command manually, I don't know if this is normally needed:
Code: [Select]
  # ~/zip/vboxadd.sh10. Building the Cross Compile Toolchain
Code: [Select]
  # cd ~/pdaXrom-builder/trunk
   # ./configure corgi-kernel-2.6-xtools ~/work http://distro.ibiblio.org/pub/linux/distributions/pdaxrom/src

The building system is now Setup for SHARP ZAURUS SL-C7x0/7500/860 pdaXrom, target xtools

   # cd ~/work
   # make virtual-xchain_install
   # make archive-toolchain
   # make clean
11. Building the ROM and all packages
Code: [Select]
  # ./configure corgi-kernel-2.6-rom

The building system is now Setup for SHARP ZAURUS SL-C7x0/7500/860 pdaXrom, target rom

   # make world

  Answer all questions with the default option
   Support long options (--hctosys,...) (CONFIG_FEATURE_HWCLOCK_LONGOPTIONS) [N/y/?] (NEW) -> N
   ... lots more ...

   # make image

That's all folks, have fun   ...
[div align=\"center\"]== == == == == == == == == == == == == ==
www.omegamoon.com
Zaurus SL-C750 - Died in a dreadful coffee experiment, has a second life somewhere in the Czech Republic
Zaurus SL-C1000 - Multiboot Zubuntu, Debian, Fedora, Poky, Android and others
Zaurus SL-C3100 - Development device, currently Zubuntu 2.0
Zaurus SL-6000L - The fridge is running Zubuntu 1.0
Zaurus SL-C860 - Cacko, untouched since kindly donated, waiting for Zubuntu
== == == == == == == == == == == == == ==[/div]

pelrun

  • Sr. Member
  • ****
  • Posts: 366
    • View Profile
    • http://
Pdaxrom Builder Setup Guide On Windows Host
« Reply #1 on: July 09, 2007, 09:01:04 am »
I used the beta4 pdaX86 iso at: ftp://ftp.ibiblio.org/pub/Linux/distribut...aXrom-nosmp.iso

No need to go through all that hassle (building Apache? Seriously?) to get svn, it's included. Still has that /dev bug though...

(It's also fine for the 2.4 toolchains too, that's what I'm using it for)
SL-C3100 with usb power mod running debian eabi
pdaXii13 still on the NAND for dualbooting
16GB SDHC! (a new one, after I sat on the old one and it went kaput)
D-Link 660 wifi, Socket Bluetooth rev H
External 9800mAh LiIon battery and slimline dvd drive
Homebrew microphone and remote

kkazakov13

  • Sr. Member
  • ****
  • Posts: 408
    • View Profile
Pdaxrom Builder Setup Guide On Windows Host
« Reply #2 on: July 09, 2007, 09:59:51 am »
Building was always so painfully slow on my system ... now that I upgraded to core2duo + 2gb ram ... soon i might reserve some time to install the builder again.
SL-C3200 ** FOR SALE :( **
https://www.oesf.org/forum/index.php?showtopic=25969

Canon K30225 CF wireless card
Taxan iTax-LAN10 wired card
My packages for customized pdaXrom beta 3

shula

  • Jr. Member
  • **
  • Posts: 95
    • View Profile
Pdaxrom Builder Setup Guide On Windows Host
« Reply #3 on: July 09, 2007, 05:28:45 pm »
I remember running a Zaurus real ARM virtual-machine on QEMU or on VirtualBox, but i might as well just dreamt it :-) as i sometimes dream of technical desires.

Is there such thing as virtual zaurus machine running in x86 host?
C860, pdaxrom rc8,
with Gnumeric as the perfect PIM :-)

Meanie

  • Hero Member
  • *****
  • Posts: 2803
    • View Profile
    • http://www.users.on.net/~hluc/myZaurus/
Pdaxrom Builder Setup Guide On Windows Host
« Reply #4 on: July 10, 2007, 04:31:10 am »
when I get time, I will build a vmware image with pdaXrom builder and cross-compilers ready to go.
my company just bought me a Toshiba Tecra M5 with Centrino Duo processor, 4GB RAM and 100GB HDD, etc...
damn thing is so heavy compared to my Z, but it got lots of RAM and other useful features...not sure what I am gonna do with it. maybe just leave it at under my bed or carry it around everywhere...
SL-C3000 - pdaXii13 build5.4.9 (based on pdaXrom beta3) / SL-C3100 - Sharp ROM 1.02 JP (heavily customised)
Netgear MA701 CF, SanDisk ConnectPlus CF, Socket Bluetooth CF, 4GB Kingston CF,  4GB pqi SD, 4GB ChoiceOnly SD, 2GB SanDisk SD USB Plus, 1GB SanDisk USB Plus, 1GB Transcend SD, 2GB SanDisk MicroSD with SD adaptor, Piel Frama Leather Case, GoldX 5-in-1 USB cable, USB hub, USB mouse, USB keyboard, USB ethernet, USB HDD, many other USB accessories...
(Zaurus SL-C3000 owner since March 14. 2005, Zaurus SL-C3100 owner since September 21. 2005)
http://members.iinet.net.au/~wyso/myZaurus - zBook3K

desertrat

  • Hero Member
  • *****
  • Posts: 743
    • View Profile
    • http://
Pdaxrom Builder Setup Guide On Windows Host
« Reply #5 on: July 11, 2007, 05:22:24 am »
Quote from: cortez,Jul 9 2007, 11:26 AM
1. Setup VirtualBox in combination with pdaX86
Code: [Select]
- Create 2(!) virtual harddisks with 25Gb space each (dynamically expanding)Presumably you've used this setup for a little while now, how much space does it actually use? I want to setup something similar but can only spare about 10GB of space.
SL-C3100 / Ambicon WL1100C-CF / pdaXrom 1.1.0beta3 / IceWM

cortez

  • Sr. Member
  • ****
  • Posts: 375
    • View Profile
    • http://www.omegamoon.com
Pdaxrom Builder Setup Guide On Windows Host
« Reply #6 on: July 11, 2007, 05:37:04 am »
Quote
Presumably you've used this setup for a little while now, how much space does it actually use? I want to setup something similar but can only spare about 10GB of space.

Currently roughly 1Gb for the first partition and 1Mb for the swap partition. Make sure you reserve enough space, because there's nothing more frustrating than a "no space left on device" error  
« Last Edit: July 11, 2007, 05:38:02 am by cortez »
[div align=\"center\"]== == == == == == == == == == == == == ==
www.omegamoon.com
Zaurus SL-C750 - Died in a dreadful coffee experiment, has a second life somewhere in the Czech Republic
Zaurus SL-C1000 - Multiboot Zubuntu, Debian, Fedora, Poky, Android and others
Zaurus SL-C3100 - Development device, currently Zubuntu 2.0
Zaurus SL-6000L - The fridge is running Zubuntu 1.0
Zaurus SL-C860 - Cacko, untouched since kindly donated, waiting for Zubuntu
== == == == == == == == == == == == == ==[/div]

cortez

  • Sr. Member
  • ****
  • Posts: 375
    • View Profile
    • http://www.omegamoon.com
Pdaxrom Builder Setup Guide On Windows Host
« Reply #7 on: July 12, 2007, 04:44:29 am »
Just to make sure we understand each other correctly:
In Windows the virtual image file currently is rougly 1.5Gb in size
The Virtual machine (linux) reports a disksize of 25Gb, from which 10Gb is in use.
[div align=\"center\"]== == == == == == == == == == == == == ==
www.omegamoon.com
Zaurus SL-C750 - Died in a dreadful coffee experiment, has a second life somewhere in the Czech Republic
Zaurus SL-C1000 - Multiboot Zubuntu, Debian, Fedora, Poky, Android and others
Zaurus SL-C3100 - Development device, currently Zubuntu 2.0
Zaurus SL-6000L - The fridge is running Zubuntu 1.0
Zaurus SL-C860 - Cacko, untouched since kindly donated, waiting for Zubuntu
== == == == == == == == == == == == == ==[/div]

desertrat

  • Hero Member
  • *****
  • Posts: 743
    • View Profile
    • http://
Pdaxrom Builder Setup Guide On Windows Host
« Reply #8 on: July 12, 2007, 05:07:30 am »
Quote
Just to make sure we understand each other correctly:
In Windows the virtual image file currently is rougly 1.5Gb in size
The Virtual machine (linux) reports a disksize of 25Gb, from which 10Gb is in use.
Does that mean the virtual image file is compressed? Anyway I've setup a vmware virtual machine with 4GB virtual drive - 3.5GB for the system and 500MB for swap. I've just completed the "setup-hd" part and rebooted, df inside the newly booted pdaxrom shows 613MB being used. I'll post an update when I've progressed further.
SL-C3100 / Ambicon WL1100C-CF / pdaXrom 1.1.0beta3 / IceWM

Meanie

  • Hero Member
  • *****
  • Posts: 2803
    • View Profile
    • http://www.users.on.net/~hluc/myZaurus/
Pdaxrom Builder Setup Guide On Windows Host
« Reply #9 on: July 12, 2007, 08:50:16 am »
Quote
Quote
Just to make sure we understand each other correctly:
In Windows the virtual image file currently is rougly 1.5Gb in size
The Virtual machine (linux) reports a disksize of 25Gb, from which 10Gb is in use.
Does that mean the virtual image file is compressed? Anyway I've setup a vmware virtual machine with 4GB virtual drive - 3.5GB for the system and 500MB for swap. I've just completed the "setup-hd" part and rebooted, df inside the newly booted pdaxrom shows 613MB being used. I'll post an update when I've progressed further.
[div align=\"right\"][a href=\"index.php?act=findpost&pid=164764\"][{POST_SNAPBACK}][/a][/div]

usually there are two modes, one the space for the virtual disk is preallocated at creation time, ie if you create a 10GB virtual disk, that much space is used to create it from your HDD. alternatively, a virtual disk can also dynamically allocate the space and only does so when it is needed. in this mode, a 10GB virtual disk will only consume as much from the real HDD as is actually used by the files on it and when it needs more space, it is dynamically allocated, so if you create a 10GB virtual disk and put 1GB of files onto it, only 1GB is allocated to it from the physical disk. the os in the virtual machine will always say that the disk is has is 10GB in size.
SL-C3000 - pdaXii13 build5.4.9 (based on pdaXrom beta3) / SL-C3100 - Sharp ROM 1.02 JP (heavily customised)
Netgear MA701 CF, SanDisk ConnectPlus CF, Socket Bluetooth CF, 4GB Kingston CF,  4GB pqi SD, 4GB ChoiceOnly SD, 2GB SanDisk SD USB Plus, 1GB SanDisk USB Plus, 1GB Transcend SD, 2GB SanDisk MicroSD with SD adaptor, Piel Frama Leather Case, GoldX 5-in-1 USB cable, USB hub, USB mouse, USB keyboard, USB ethernet, USB HDD, many other USB accessories...
(Zaurus SL-C3000 owner since March 14. 2005, Zaurus SL-C3100 owner since September 21. 2005)
http://members.iinet.net.au/~wyso/myZaurus - zBook3K

desertrat

  • Hero Member
  • *****
  • Posts: 743
    • View Profile
    • http://
Pdaxrom Builder Setup Guide On Windows Host
« Reply #10 on: July 12, 2007, 11:40:57 am »
Quote
... a 10GB virtual disk will only consume as much from the real HDD as is actually used by the files on it and when it needs more space, it is dynamically allocated ...
I knew all that  But my reading of this:
Quote
The Virtual machine (linux) reports a disksize of 25Gb, from which 10Gb is in use.
Is that the guest OS, ie inside pdaxrom, it is already using 10GB out of the allocated/pre-allocated 25GB. However the host OS is reporting that only 1.5GB of real disk space is being used:
Quote
In Windows the virtual image file currently is rougly 1.5Gb in size
Which implies some real heavy duty compression is taking place or something. But that's not important right now, since I already installed it I'm going to play around with it and see if I eventually run out of space

But my immediate concerns right now is that pdaxrom under vmware has a tendency to lose my mouse pointer. I've got a Win98 and WinXP running under vmware and have tried loads of different linux distros using it and have never come across a disappearing mouse pointer before  I think I'll just stick to the console for the moment - no scratch that, I'll use ssh.

Meanie, when you get round to making an updated pdaxrom ISO, could you please add some essential utils to it? At least add less and vim. Using more is a pita, and all versions of vi that I've used on practically all manners of systems suffer from corrupt display - after a little bit of editing the display does not reflect the actual contents of the file.
« Last Edit: July 12, 2007, 11:48:57 am by desertrat »
SL-C3100 / Ambicon WL1100C-CF / pdaXrom 1.1.0beta3 / IceWM