ARM交叉编译器安装

安装arm交叉编译器

zshh-shaohua:~/ARM/arm资料$ cd exynos4412_lzy1/
zshh@zshh-shaohua:~/ARM/arm资料/exynos4412_lzy1$ ls
cross_compile  datasheet  Doc  images  rootfs  schematic  src  tools  usb_to_uart
zshh@zshh-shaohua:~/ARM/arm资料/exynos4412_lzy1$ cd cross_compile/
zshh@zshh-shaohua:~/ARM/arm资料/exynos4412_lzy1/cross_compile$ ls
arm-2013.05-24-arm-none-linux-gnueabi.bin  arm-linux-gcc-4.5.1.tar.bz2  arm-linux-gcc-4.7.3.tar.bz2
zshh@zshh-shaohua:~/ARM/arm资料/exynos4412_lzy1/cross_compile$ mkdir /usr/local/arm^C
zshh@zshh-shaohua:~/ARM/arm资料/exynos4412_lzy1/cross_compile$ tar -xvf /usr/local/arm/
4.5.1/                       arm-linux-gcc-4.5.1.tar.bz2  
zshh@zshh-shaohua:~/ARM/arm资料/exynos4412_lzy1/cross_compile$ tar -xvf /usr/local/arm/arm-linux-gcc-4.5.1.tar.bz2
zshh@zshh-shaohua:~/ARM/arm资料/exynos4412_lzy1/cross_compile$ tar -xvf /usr/local/arm/arm-linux-gcc-4.5.1.tar.bz2 -C /usr/local/arm

vim ~/.bashrc

在最后一行加PATH=/usr/local/arm/4.5.1/bin:$PATH


测试一安装是成功:

使得配置文件立即生效:
zshh@zshh-shaohua:~/ARM/arm资料/exynos4412_lzy1/cross_compile$ source ~/.bashrc

查看linux文件得版本:
zshh@zshh-shaohua:~/ARM/arm资料/exynos4412_lzy1/cross_compile$ arm-linux-gcc -v
Using built-in specs.
COLLECT_GCC=arm-linux-gcc
COLLECT_LTO_WRAPPER=/usr/local/arm/4.5.1/bin/../libexec/gcc/arm-none-linux-gnueabi/4.5.1/lto-wrapper
Target: arm-none-linux-gnueabi
Configured with: /work/toolchain/build/src/gcc-4.5.1/configure --build=i686-build_pc-linux-gnu --host=i686-build_pc-linux-gnu --target=arm-none-linux-gnueabi --prefix=/opt/FriendlyARM/toolschain/4.5.1 --with-sysroot=/opt/FriendlyARM/toolschain/4.5.1/arm-none-linux-gnueabi/sys-root --enable-languages=c,c++ --disable-multilib --with-cpu=arm1176jzf-s --with-tune=arm1176jzf-s --with-fpu=vfp --with-float=softfp --with-pkgversion=ctng-1.8.1-FA --with-bugurl=http://www.arm9.net/ --disable-sjlj-exceptions --enable-__cxa_atexit --disable-libmudflap --with-host-libstdcxx='-static-libgcc -Wl,-Bstatic,-lstdc++,-Bdynamic -lm' --with-gmp=/work/toolchain/build/arm-none-linux-gnueabi/build/static --with-mpfr=/work/toolchain/build/arm-none-linux-gnueabi/build/static --with-ppl=/work/toolchain/build/arm-none-linux-gnueabi/build/static --with-cloog=/work/toolchain/build/arm-none-linux-gnueabi/build/static --with-mpc=/work/toolchain/build/arm-none-linux-gnueabi/build/static --with-libelf=/work/toolchain/build/arm-none-linux-gnueabi/build/static --enable-threads=posix --with-local-prefix=/opt/FriendlyARM/toolschain/4.5.1/arm-none-linux-gnueabi/sys-root --disable-nls --enable-symvers=gnu --enable-c99 --enable-long-long
Thread model: posix
gcc version 4.5.1 (ctng-1.8.1-FA) 


测试二安装是否成功:
	mkdir test
	cd test
	touch hello.c
	arm-linux-gcc hello.c -o hello


评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值