ARM Cross Compilation Toolchain on x86 machine
Dear All, We are unable to build the ARM cross compilation tools for arm-elf-gcc-3.4.3 on my x86 machine on which we installed the Ubuntu 9.10 distribution OS with 2.6.35 kernel version. The gcc version on x86 machine is 4.3.3. We need to compile some sources on my x86 machine for our target machine which is based on ARM architecture. We have gone through following links to build the cross compilation tools for arm-elf-gcc 3.4.3 on my x86 machine. http://www.ailis.de/~k/archives/19-ARM-cross-compiling-howto.html http://www.kegel.com/crosstool/current/doc/crosstool-howto.html http://www.kegel.com/crosstool/ Unfortunately we end up with different types of errors. When we fix one error then we get another new error. We tried in different ways to build the tools on my x86 machine. There is no luck at all. We also gone through the http://www.gnuarm.com/ site and downloaded the binaries for gcc 3.4. toolchain. However, we did not find any README for how to use these binaries. Please let us know if there is any clean procedure/document/link for building/using the arm-elf-gcc 3.4.3 toolchain on my x86 machine. Any help would be greatly appreciated and help us a lot. Thanks and Regards, Madhavi M.
try this... its a different toolchain based on GCC http://www.codesourcery.com/sgpp/lite/arm --Vinit On Thu, Jan 6, 2011 at 9:08 PM, Madhavi Manchala <madhavi.linux@gmail.com>wrote:
Dear All,
We are unable to build the ARM cross compilation tools for arm-elf-gcc-3.4.3 on my x86 machine on which we installed the Ubuntu 9.10 distribution OS with 2.6.35 kernel version. The gcc version on x86 machine is 4.3.3. We need to compile some sources on my x86 machine for our target machine which is based on ARM architecture. We have gone through following links to build the cross compilation tools for arm-elf-gcc 3.4.3 on my x86 machine.
http://www.ailis.de/~k/archives/19-ARM-cross-compiling-howto.html http://www.kegel.com/crosstool/current/doc/crosstool-howto.html http://www.kegel.com/crosstool/
Unfortunately we end up with different types of errors. When we fix one error then we get another new error. We tried in different ways to build the tools on my x86 machine. There is no luck at all. We also gone through the http://www.gnuarm.com/ site and downloaded the binaries for gcc 3.4. toolchain. However, we did not find any README for how to use these binaries.
Please let us know if there is any clean procedure/document/link for building/using the arm-elf-gcc 3.4.3 toolchain on my x86 machine.
Any help would be greatly appreciated and help us a lot.
Thanks and Regards, Madhavi M.
_______________________________________________ Kernelnewbies mailing list Kernelnewbies@kernelnewbies.org http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
try this... its a different toolchain based on GCC http://www.codesourcery.com/sgpp/lite/arm
Or if you need something more specific, try Buildroot to built your own cross-compilation environment. But Vinit's solution should be simpler to install and adequate in most cases. Alex.
On Thu, Jan 6, 2011 at 9:18 PM, vinit agrawal <vender007@gmail.com> wrote:
try this... its a different toolchain based on GCC http://www.codesourcery.com/sgpp/lite/arm
Thanks for the link. However, you are saying that it is a different toolchain based on GCC. I did not understand this sentence correctly. Actually, I want to compile the sources using arm-elf-gcc command. Is this supported by this codesourcery tool? If you have already used, please let me know. Thanks and Regards, Madhavi M.
--Vinit On Thu, Jan 6, 2011 at 9:08 PM, Madhavi Manchala <madhavi.linux@gmail.com> wrote:
Dear All,
We are unable to build the ARM cross compilation tools for arm-elf-gcc-3.4.3 on my x86 machine on which we installed the Ubuntu 9.10 distribution OS with 2.6.35 kernel version. The gcc version on x86 machine is 4.3.3. We need to compile some sources on my x86 machine for our target machine which is based on ARM architecture. We have gone through following links to build the cross compilation tools for arm-elf-gcc 3.4.3 on my x86 machine.
http://www.ailis.de/~k/archives/19-ARM-cross-compiling-howto.html http://www.kegel.com/crosstool/current/doc/crosstool-howto.html http://www.kegel.com/crosstool/
Unfortunately we end up with different types of errors. When we fix one error then we get another new error. We tried in different ways to build the tools on my x86 machine. There is no luck at all. We also gone through the http://www.gnuarm.com/ site and downloaded the binaries for gcc 3.4. toolchain. However, we did not find any README for how to use these binaries.
Please let us know if there is any clean procedure/document/link for building/using the arm-elf-gcc 3.4.3 toolchain on my x86 machine.
Any help would be greatly appreciated and help us a lot.
Thanks and Regards, Madhavi M.
_______________________________________________ Kernelnewbies mailing list Kernelnewbies@kernelnewbies.org http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
Thanks for the link. However, you are saying that it is a different toolchain based on GCC. I did not understand this sentence correctly. Actually, I want to compile the sources using arm-elf-gcc command. Is this supported by this codesourcery tool? If you have already used, please let me know.
The name of the compiler will maybe be different, but yes, you will be able to cross-compile sources using it. Alex.
Hi, I would suggest using ELDK. I have had an easy time setting it up in the past. $ wget ftp://ftp.denx.de/pub/eldk/4.2/arm-linux-x86/iso/arm-2008-11-24.iso $ mount -o loop arm-2008-11-24.iso /mnt $ cd /mnt $ sudo ./install -d /opt/eldk-4.2 Now add "/opt/eldk-4.2/usr/bin/" to your PATH. My preferred method is to instead do $ export CROSS_COMPILE=/opt/eldk-4.2/usr/bin/arm-linux- and use the $CROSS_COMPILE variable when setting the toolchains in my Makefiles. Hope this helps :-) -- /manohar
On Fri, Jan 7, 2011 at 6:44 AM, Manohar Vanga <manohar.vanga@gmail.com> wrote:
Hi, I would suggest using ELDK. I have had an easy time setting it up in the past. $ wget ftp://ftp.denx.de/pub/eldk/4.2/arm-linux-x86/iso/arm-2008-11-24.iso $ mount -o loop arm-2008-11-24.iso /mnt $ cd /mnt $ sudo ./install -d /opt/eldk-4.2 Now add "/opt/eldk-4.2/usr/bin/" to your PATH. My preferred method is to instead do $ export CROSS_COMPILE=/opt/eldk-4.2/usr/bin/arm-linux- and use the $CROSS_COMPILE variable when setting the toolchains in my Makefiles. Hope this helps :-)
Thanks Manohar. Where can I get the list of supported CPU family types for ARM architecture like ARM5, ARM7, ARM926EJ etc. In case of Power Architecture (PPC) there is a list as shown in the below link at ELDK site http://www.denx.de/wiki/view/DULG/ELDKSupportedTargetArchitectures The same is also mentioned in the table at 3.6.A Table of possible values for $CROSS_COMPILE section of the ELDK at http://www.denx.de/wiki/view/DULG/ELDKUsage For us, ARM9 is suitable. Thanks and Regards, Madhavi M.
Hi Madhavi, On Fri, Jan 7, 2011 at 1:30 AM, Madhavi Manchala <madhavi.linux@gmail.com> wrote: ...snip...
Where can I get the list of supported CPU family types for ARM architecture like ARM5, ARM7, ARM926EJ etc. In case of Power Architecture (PPC) there is a list as shown in the below link at ELDK site http://www.denx.de/wiki/view/DULG/ELDKSupportedTargetArchitectures
The same is also mentioned in the table at 3.6.A Table of possible values for $CROSS_COMPILE section of the ELDK at http://www.denx.de/wiki/view/DULG/ELDKUsage
For us, ARM9 is suitable.
You can try using arm-xxx-gcc --target-help (replace xxx appropriately). This should list the targets which are supported by that particular compiler. For example, when I use my gumstix cross compiler, I get the following output: Known ARM CPUs (for use with the -mcpu= and -mtune= options): cortex-m3, cortex-r4, cortex-a8, arm1156t2-s, mpcore, mpcorenovfp, arm1176jzf-s, arm1176jz-s, arm1136jf-s, arm1136j-s, arm1026ej-s, arm926ej-s, iwmmxt, xscale, arm1022e, arm1020e, arm10e, arm968e-s, arm966e-s, arm946e-s, arm9e, arm1020t, arm10tdmi, ep9312, arm940t, arm922t, arm920t, arm920, arm9tdmi, arm9, arm740t, arm720t, arm710t, arm7tdmi-s, arm7tdmi, strongarm1110, strongarm1100, strongarm110, strongarm, arm810, arm8, arm7dmi, arm7dm, arm7m, arm7500fe, arm7500, arm7100, arm710c, arm720, arm710, arm700i, arm700, arm70, arm7di, arm7d, arm7, arm620, arm610, arm600, arm60, arm6, arm3, arm250, arm2 Known ARM architectures (for use with the -march= option): iwmmxt, ep9312, armv7-m, armv7-r, armv7-a, armv7, armv6t2, armv6zk, armv6z, armv6k, armv6j, armv6, armv5te, armv5e, armv5t, armv5, armv4t, armv4, armv3m, armv3, armv2a, armv2 Dave Hylands
likes for the end note ... :) On Tue, Feb 1, 2011 at 10:04 PM, Chaitannya Mahatme <chaitannya@gmail.com>wrote:
On Friday 07 January 2011 09:56 PM, Dave Hylands wrote:
Hi Madhavi,
On Fri, Jan 7, 2011 at 1:30 AM, Madhavi Manchala<madhavi.linux@gmail.com> <madhavi.linux@gmail.com> wrote: ...snip...
Where can I get the list of supported CPU family types for ARM architecture like ARM5, ARM7, ARM926EJ etc. In case of Power Architecture (PPC) there is a list as shown in the below link at ELDK sitehttp://www.denx.de/wiki/view/DULG/ELDKSupportedTargetArchitectures
The same is also mentioned in the table at 3.6.A Table of possible values for $CROSS_COMPILE section of the ELDK athttp://www.denx.de/wiki/view/DULG/ELDKUsage
For us, ARM9 is suitable.
You can try using
arm-xxx-gcc --target-help
(replace xxx appropriately). This should list the targets which are supported by that particular compiler. For example, when I use my gumstix cross compiler, I get the following output:
Known ARM CPUs (for use with the -mcpu= and -mtune= options): cortex-m3, cortex-r4, cortex-a8, arm1156t2-s, mpcore, mpcorenovfp, arm1176jzf-s, arm1176jz-s, arm1136jf-s, arm1136j-s, arm1026ej-s, arm926ej-s, iwmmxt, xscale, arm1022e, arm1020e, arm10e, arm968e-s, arm966e-s, arm946e-s, arm9e, arm1020t, arm10tdmi, ep9312, arm940t, arm922t, arm920t, arm920, arm9tdmi, arm9, arm740t, arm720t, arm710t, arm7tdmi-s, arm7tdmi, strongarm1110, strongarm1100, strongarm110, strongarm, arm810, arm8, arm7dmi, arm7dm, arm7m, arm7500fe, arm7500, arm7100, arm710c, arm720, arm710, arm700i, arm700, arm70, arm7di, arm7d, arm7, arm620, arm610, arm600, arm60, arm6, arm3, arm250, arm2
Known ARM architectures (for use with the -march= option): iwmmxt, ep9312, armv7-m, armv7-r, armv7-a, armv7, armv6t2, armv6zk, armv6z, armv6k, armv6j, armv6, armv5te, armv5e, armv5t, armv5, armv4t, armv4, armv3m, armv3, armv2a, armv2
Dave Hylands
_______________________________________________ Kernelnewbies mailing listKernelnewbies@kernelnewbies.orghttp://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
Hi Madhavi,
Read this article http://wiki.embeddednirvana.org/Building_your_own_toolchain. A brief given a brief about explanation on instruction set and cross compile target is given. It is highly recommended that you use the toolchain supplied from the chip manufacturer since it would be optimised for the chip you are using. A program compiled for ARM7 can run perfectly well on arm11 arch, but then you won't be able to utilize h/w features of the arm11 arch.
As for the complete list, it's available on gcc's site http://gcc.gnu.org/onlinedocs/gcc/ARM-Options.html -- Cheers !!! Chaitannya
follow me on twitter http://twitter.com/chaitannya
I believe there's a hero in all of us who keeps us honest, gives us strength, makes us noble, and finally allows us to die with pride, even though sometimes we have to be steady, and give up the thing we want the most... even our dreams. - Spider Man 2
_______________________________________________ Kernelnewbies mailing list Kernelnewbies@kernelnewbies.org http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
participants (6)
-
Alexandre Courbot -
Chaitannya Mahatme -
Dave Hylands -
Madhavi Manchala -
Manohar Vanga -
vinit agrawal