Native or cross compiling
Cross compiling means compiling applications on a standard PC (which for the purposes of this example is an x86 PC running Linux). The resulting application will of course run on the Zaurus.
Native Compiling means compiling the application on the Z itself.
Cross compiling is (normally) a lot faster than compiling on the Z. But Zaurus developers do not necessarily have developing on a PC in mind when they write their configure / makefile / build scripts. This means that it might not work out of the box when you try to compile the application on your PC.
When compiling natively you are not subject to cross compilation problems. But other problems can arise:
- compiling might require more ram than the Z has.
- compiling can create a large number of files which will need to be (at least temporarily) stored somewhere on the Zaurus. This can put a strain on an already full system.
- and most importantly, compiling might require some external tools that are normally found on a standard Linux distribution, but for space reasons aren't usually included with pdaXrom (or worse not yet compiled). For instance you might need to install perl just to be able to compile your application.
See the installation and tutorial section onhttp://www.pdaxrom.org.
Note that since RC5, the directory "/opt/arm/3.3.2" has been renamed to "/opt/arm/3.3.2-vfp". So if you use the latest sdk you will need to change "3.3.2" to "3.3.2-vfp" wherever you find "3.3.2".
The space problem can easily be solved by mounting an nfs partition on your unix server. That way you can have as much space for compiling as is available on the server.
Using a nfs or samba drive on MS windows server will probably NOT work because of the differences between the filesystems (no symbolic link etc..).
If you are forced to develop using a Windows PC, then you will need to do the following:
- create an image file with dd.
- format this image with ext2 format.
- mount the image.
This will not speed up the compiling.
The ram problem can be solved by creating a swap file (search on this subject). You can even create a swap file on an network drive if your are afraid of damaging your cards/internal flash.
This will definitely not make the build faster.
If you have a linux pc, you can use distcc to speed up the compiling a bit. Distcc allows you to distribute the work load between the Zaurus and the PC.
For more info see [