Cross Compilation Environment


dbzeag

Still Fresh
Joined
May 27, 2008
Messages
21
Hello. I am very new to Linux and compilation on Linux, so please be patient with me.

I am very interested in this project after UMPCPortal did an article about Pandora a little while back. I have been looking at Zaurus' for quite a while now and I see the Pandora as the inadvertent next generation Zaurus.

From the research I have found, I think I am going to get the Pandora and play around with it, but I need to get started first. From what I understand, if you have the source code available and all of the compilers with suitable libraries installed, one can recompile the code with the ARM or more exactly the Cortex A8 processor as the target. More exactly, some source will even let the graphic resolutions be built as well as using the graphics engine appropriately, if the compiler uses the graphics libraries properly.

I have also learned a very small bit about cross compilation. Basically this is the art of using a "3rd party" build machine that might be faster or has more resources and libraries to build the binaries to use on a different target machine. Rather than building the source on the Pandora directly, one can build the software on a desktop machine (running Linux or even Windows if properly setup). Then one can take this code and "copy" it over to the Pandora to run.

What I would like to know is how to set up the desktop machine for cross compilation with the Pandora as a target. I would assume libraries for the Power VR and Cortex A8 cores as well as USB, SD removable slot, and 800x480 and touchscreen libraries would need to be available for the compiler. Is there a Pandora SDK that can be “installed” to a development studio package or loaded/referenced in the compiler for the target build?

I am starting from scratch with this, but I have a blank desktop without OS, ready to get prepped for source compilation. Can anyone link me to places to help build up the build machine for Pandora targets? Or just setting up the build machine in general for cross compilation?

Thank you very much. I am getting very excited about this release!
 
Cross compilation is actually a very simple thing: configure your develop environment to use a special compiler instead of your normal compiler. Here you are. Most of the time you can compile and run exactly the same program for your PC using one compiler, and for other machine using the special cross-compiler. They even use the same libreries. Hey, this is all Linux here.

I do not know anything about the cross compiler toolchains for the Pandora. At the time being, just develop and compile for your platform using standard Linux/SDL/OpenGL libraries and don't bother about cross compilation... yet.
 
Unfortunately to build the toolchain, you need kernel headers for Pandora, which have yet to be made public. It is more then likely that Pandora devs will make a public tool chain.

For now, the best way to develop might actually be to use Maemo's Scratchbox, since I can't think of any mainstream linux based system that is closer in hardware compatability.
 
I am trying now to set up Scratchbox (or Scratchbox2) on Ubuntu with minimal success. From what I have read, this + the newest toolchain from Code Sourcery should give me support for Cortex A8 core. I am having difficulties setting it up, however.

How else are people setting up their dev systems?
 
For now you would probably be best to use the OGL ES2 emulation files and get you applications working with those. Then when a full devkit for Pandora is available it's only a case of a few tweaks that would be necessary.
 
Megamixman said:
Unfortunately to build the toolchain, you need kernel headers for Pandora, which have yet to be made public.
Kernel source for EVM and Beagle is available, Pandora just includes more drivers. The kernel headers will be the same.

However, it will be a lot easier to use Code Sourcery GCC 2007q1, which is compatible with both Linux and Windows. 2007q1 is recommended as its the one used the build the kernel. 2007q3 does not build a usable Kernel, so there's most likely something broke in that release. 2008q1 and onwards are not tested, but it has been noted that some of the 2008 releases are broken also.
 
Last edited by a moderator:
Back
Top