I want to add new gcc cross compiler to my Linux mint. I need this compiler to compile codes that should run on a Khepera III Robot. I have searched a round but I didn't find any clear answer to my question. I'm about to graduate so I can't afford trying and ruining my current OS. I would appreciate it if anyone can help me to add this new compiler.

This is what's written on the Khepera III website.

The GCC cross compiler, combined with the libKorebot API, and any standard library available for the Linux operating system, provide a powerful standard development environment. An application running on KoreBot can use all the POSIX functions from the standard C library as well as many other libraries (such as libjpeg, libpthread, libcrypto, etc...).

More Information about Korebot of the robot: Processor : Marvell PXA270 with XScale @ 600MHz OS : Linux OS, Angström distribution (OpenEmbedded tools), kernel 2.6.24 Memory : 128MB RAM/32MB Flash


You should first try one available from K-team.

If that does not work, your distro may have an ARM cross-compiler package available; since the debian wiki makes mention of the PXA270, these presumably work. I notice looking around people using this chip and gcc with -march=armv5te and/or -mabi=iwmmxt; iwmmxt is also available as a -mcpu and -march, but a combination of these may not work. iwmmxt is the most specific; it refers to Intel's MMX extensions for their implementation of ARM (which is what the PXA270's CPU is).

You could also grapple with crosstool-ng. What I strongly recommend against is trying to build a toolchain yourself from scratch.

  • I downloaded the package from the link, but I don't know what to do next, can you suggest some steps? – Alaa Feb 24 '14 at 22:09
  • Have you looked inside by unpacking it? tar -xjf blah-blah.tar.bz2 – goldilocks Feb 24 '14 at 22:31
  • yes I did, I found a lot of .h files and other files. I have no idea what I'm supposed to do with it – Alaa Feb 25 '14 at 17:41
  • I'd go for the distro one then. It will almost certainly work; the disadvantage is won't come bundled with specific libraries, but OTOH the distro's official cross-compiler package should have better documentation. You can easily test by writing programs that rely only on the standard C library -- presumably you can log into the robot and access some kind of shell where you could run a "hello world". The trick is to get the -march and/or -mcpu and -mabi switches to the cross-compiler correct. Search online for other people doing things with gcc and the PXA270 and experiment. – goldilocks Feb 25 '14 at 17:49

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.