Build an embedded development environment-install the cross-compilation tool chain and embedded compilation tools
If the development environment is Linux, the cross-compilation tool chain is required. The installation process is as follows:
cd work/toolchaintar
xjf arm-linux-gcc-3.4.5-glibc-2.3.6.tar.bz2
After decompression, you need to set the environment variables. Do not set them manually every time you use them. You can modify the PATH value in/etc/environment, as shown below:
PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/home/haley/work/toolchain/gcc-3.4.5-glibc-2.3.6/bin"
Save and take effect immediately
source /etc/environment
Open a new terminal
haley@ubuntu:~$ arm-linux-gcc -v
Reading specs from /home/haley/work/toolchain/gcc-3.4.5-glibc-2.3.6/bin/../lib/gcc/arm-linux/3.4.5/specsConfigured with: /work/tools/create_crosstools/crosstool-0.43/build/arm-linux/gcc-3.4.5-glibc-2.3.6/gcc-3.4.5/configure --target=arm-linux --host=i686-host_pc-linux-gnu --prefix=/work/tools/gcc-3.4.5-glibc-2.3.6 --with-float=soft --with-headers=/work/tools/gcc-3.4.5-glibc-2.3.6/arm-linux/include --with-local-prefix=/work/tools/gcc-3.4.5-glibc-2.3.6/arm-linux --disable-nls --enable-threads=posix --enable-symvers=gnu --enable-__cxa_atexit --enable-languages=c,c++ --enable-shared --enable-c99 --enable-long-longThread model: posixgcc version 3.4.5
The installation is successful.