1. Download and unzip tool
Download path http://www.arm9.net/download.asp
The arm-linux-gcc-4.5.1-v6-vfp-20120301.tgz copied to Linux, and extract the root directory:
sudo tar -zxvf arm-linux-gcc-4.5.1-v6-vfp-20120301.tgz -C /
Such codecs to the opt / root directory.
2, configure the environment variables
vim ~/.bashrc
shift + g (i.e. G) jumps to the end of the file is added:
export PATH=/opt/FriendlyARM/toolschain/4.5.1/bin:$PATH
export or not can be.
After editing save and exit.
So that the environment variables to take effect in three ways:
1) a terminal Reopen
When you re-open a terminal, .bashrc under the current path will be executed once, to take effect.
2) . ~/.bashrc
3)source ~/.bashrc
3, to test whether the installation is successful
Enter the arm-linux-gcc -v, if you see gcc version 4.5.1 installation is successful.
If you can not find a command error occurs, because Ubuntu is using a 64-bit, while the cross compiler tools we are installing a 32-bit, the lack of 32-bit libraries:
sudo apt-get install lsb-core
sudo apt-get install lib32z1
that's it.