Skip to main content

Install a GNU Arm toolchain under Linux

Posted in

 

This tutorial was realized and tested under a distribution Ubuntu 10.04.
 
The installation of a GNU Arm Toolchain is necessary to recompile the firmware of the robot and so take into account the modifications which you would have bring to the virtual machine (choice of the Slack Stealer algorithm, personal modifications...).

Prerequisites
 
 
Package dependencies
You will need to ensure that the packages that the GNU Arm toolchain is dependent on are on your system. You need all following packages (with their dependencies) :
  • curl
  • gcc
  • libmpfr-dev
  • Texinfo
  • make
  • gnustep-make
  • libgmp3-dev
  • libmpfr1ldbl
  • libncurses5-dev
  • libncurses5

 


Installation

 

Download packages

Download packages and the script below :

 

Build Arm toolchain

Create a directory of your choice where the GNU Arm toolchain will be installed, for example : /home/user/GNU-arm-toolchain. Extract build_arm_toolchain.zip in this directory and create an other directory called "src" in the last one. (/home/user/GNU-arm-toolchain/src).

Copy in the directory "src" binutils-2.19.1.tar.bz2, gcc-core-4.4.0.tar.bz2, gdb-6.8.tar.bz2 and newlib-1.17.0.tar.gz without extracting them. 

Start a shell session, and go to the first directory you have created (/home/user/GNU-arm-toolchain in our example). Then tape : ./build_arm_toolchain.sh to execute the script and to install the arm toolchain. The installation is made in 5 stages.

 

Use Arm toolchain

You need to set up environment variables like this :

export PATH=/home/user/GNU-arm-toolchain/install/bin:$PATH

You need to restart your session.

You can check that you have successfully installed GNU Arm toolchain on your PC by starting a shell session and taping "arm-elf-gcc".