fedora安装busybox过程及出错处理


Linux fedora安装busybox过程及出错处理

[root@ARM busybox-1.16.0]# uname -r
2.6.35.14-106.fc14.i686

解压busybox:[root@**]# tar xvfj /mnt/hgfs/src-linux/2.6.30.4/busybox-1.16.0.tar.bz2 -C /

小Q截图-20120321100833

[root@ARM **]# cd /opt/EmbedSky/busybox-1.16.0/
编译:make menuconfig
===========================================================
出错处理:
[root@ARM busybox-1.16.0]# make menuconfig
Makefile:431: *** mixed implicit and normal rules.  Stop.

今天在编译busybox1.16的时候,执行make命令,报错,错误信息:437 “mixed implicit and normal rules”,翻译为中文:混合的和隐含普通规则。起初以为是busybox包的问题,从官网上下载了低版本1.13,报同样的错误,google后发现,是由于我的系统的make工具太新(系统:fedora14),make的旧版规则已经无法兼容新版。按照以下方式,问题得到解决:
cd /opt/EmbedSky/busybox-1.16.0/; vim Makefile;
busybox版本:busybox-1.16.0.tar.bz2,Linux版本不一致,错误行不太一样;
在makefile中将430行代码
config %config: scripts_basic outputmakefile FORCE改:
%config: scripts_basic outputmakefile FORCE
改后为:
 
430 #config %config: scripts_basic outputmakefile FORCE
431 %config: scripts_basic outputmakefile FORCE
将1279行代码:
/ %/: prepare scripts FORCE(错)
改为:%/: prepare scripts FORCE(对)
改后为:
1279 #/ %/: prepare scripts FORCE
1280 %/: prepare scripts FORCE
即可编译通过!

继续:
[root@ARM busybox-1.16.0]# make menuconfig
make[2]: *** [scripts/kconfig/lxdialog/checklist.o] Error 1
解决方法:
安装ncurses-devel,这个是红帽或者FC的安装程序,Ubuntu的需要安装libncurses5-dev
[root@ARM busybox-1.16.0]# yum install -y ncurses-devel

继续:
[root@ARM busybox-1.16.0]# make menuconfig
Your display is too small to run Menuconfig!
It must be at least 19 lines by 80 columns.
make[1]: *** [menuconfig] Error 1
如果是在终端窗口执行的话,要保证窗口的大小,如果窗口过小,则会显示出错信息:把你的终端最大化就行了。

继续:
[root@ARM busybox-1.16.0]# make menuconfig
打开终端配置窗口,
Load an Alternate Configration File导入配置,
Save Configration to an Alternate File保存配置(保存为.config后缀的);

继续:
[root@ARM busybox-1.16.0]# make
make编译;
  LINK    busybox_unstripped
Trying libraries: crypt m
Library crypt is not needed, excluding it
Library m is needed, can't exclude it (yet)
Final link with: m
  DOC     busybox.pod
  DOC     BusyBox.txt
  DOC     BusyBox.1
  DOC     BusyBox.html
[root@ARM busybox-1.16.0]# 编译完成;

继续:
[root@ARM busybox-1.16.0]# make install
安装刚刚编译好的busybox,安装后在busybox源码的根目录下会建立一个_install的目录,安装后的busybox就在该目录下。

--------------------------------------------------
You will probably need to make your busybox binary
setuid root to ensure all configured applets will
work properly.
--------------------------------------------------
安装完成。
查看_install目录下内容:
[root@ARM busybox-1.16.0]# ll _install/
total 12
drwxr-xr-x. 2 root root 4096 Mar 11 23:30 bin
lrwxrwxrwx. 1 root root   11 Mar 11 23:30 linuxrc -> bin/busybox
drwxr-xr-x. 2 root root 4096 Mar 11 23:30 sbin
drwxr-xr-x. 4 root root 4096 Mar 11 23:30 usr

转载: http://z515256164.blog.163.com/blog/static/324430292012212114228993/

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

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

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

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值