添加完环境变量后,输入arm-gcc-linux -v 
报错:arm-gcc-linux:command not found
解决办法:apt-get install lsb-core



参考:

安装基本开发包 
root@ubuntu:~# apt-get update && apt-get install -y build-essential bison flex manpages-dev 
root@ubuntu:~# echo $? 
0

安装 arm-linux-gcc 
解压 arm-linux-gcc-3.4.5-glibc-2.3.6.tar.bz2 来自韦东山教学光盘 
tar xf arm-linux-gcc-3.4.5-glibc-2.3.6.tar.bz2

安装 sudo apt-get install lsb-core 
否则可能出现No such file or directory 
root@ubuntu:~/leds# arm-linux-objcopy 
bash: /home/username/gcc-3.4.5-glibc-2.3.6/bin/arm-linux-objcopy: No such file or directory

更改系统PATH 
username@ubuntu:~PATH::/home/username/gcc-3.4.5-glibc-2.3.6/bin/

看看我的系统 编译环境搭建好了 
username@ubuntu:~$ arm-linux-gcc -v 
Reading specs from /home/username/gcc-3.4.5-glibc-2.3.6/bin/../lib/gcc/arm-linux/3.4.5/specs 
Configured 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-long 
Thread model: posix 
gcc version 3.4.5





相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-05-22
  • 2021-12-10
  • 2021-06-25
  • 2021-11-26
  • 2022-01-08
  • 2022-12-23
猜你喜欢
  • 2021-07-03
  • 2021-12-09
  • 2021-05-02
  • 2021-07-17
  • 2021-12-16
相关资源
相似解决方案