交叉编译器制作

先安装以下软件包


gcc
gcc-c++
flex
ncurses
bison
texinfo


# yum install -y gcc gcc-c++ flex ncurses bison texinfo


我的交叉编译器安装在/opt 目录下


# chmod 777 /opt/
$ cd /opt/


下载源码包,这里是2012.08版本


# wget http://buildroot.uclibc.org/downloads/buildroot-2012.08-rc2.tar.gz

$ mv buildroot-2012.08 dl

$ tar -xjf dl/buildroot-2012.08.tar.bz2
$ ls buildroot-2012.08
$ mv dl/ buildroot-2012.08
$ cd buildroot-2012.08


配置编译选项

$ make menuconfig

buildroot-2012.08 make menuconfig 选项配置说明

Target Architecture (ARM (little endian)) --->
Target Architecture Variant (arm920t) ---> 根据自己的 CPU 来选择
Target ABI (EABI) --->
Build options --->
($(TOPDIR)/dl) Download dir
($(TOPDIR)/arm920t) Host dir
[*] prefer static libraries
其它选项都不要选,如果是要设置值的地方就使用默认值
Toolchain --->
Kernel Headers (Linux 2.6 (manually specified version)) --->
(2.6.37) linux version 选定内核版本为 2.6.37
... ...
[*] Enable compiler tls support
[*] Enable MMU support
[*] Use software floating point by default
[*] Enable large file (files > 2 GB) support
[*] Enable IPv6 support
[*] Enable RPC support
[*] Enable WCHAR support
[*] Enable C++ support
其它选项都不要选,如果是要设置值的地方就使用默认值
System configuration --->
Init system (None) ---> Busbyox 编译去掉
这里面所有的都不要选,如果是要设置值的地方就使用默认值
Package Selection for the target --->
这里面所有的选项都不要选,除了:
Libraries --->
Compression and decompression --->
[*] gzip
[*]lzop
Host utilities --->
这里面所有的选项都不要选
Filesystem images --->
这里面所有的选项都不要选
Bootloaders --->
这里面所有的选项都不要选
Kernel ---

这里面所有的选项都不要选


配置完后

$ make

ok,完工


  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值