有关用crosstool-ng编译交叉工具链出现找不到expat的问题的解决办法

最近在编一个针对loongson的编译链,用的是crosstool-ng提供的工具,在编译的gdb模块时,出现如下错误:

[ERROR]    configure: error: expat is missing or unusable

[ERROR]    make[2]: *** [configure-gdb] Error 1
[ALL  ]    make[2]: Leaving directory `/home/andy/crosstool-ng/build13/.build/mipsel-ls2f-linux-gnu/build/build-gdb-cross'
[ERROR]    make[1]: *** [all] Error 2
[ALL  ]    make[1]: Leaving directory `/home/andy/crosstool-ng/build13/.build/mipsel-ls2f-linux-gnu/build/build-gdb-cross'
[ERROR]    
[ERROR]    >>
[ERROR]    >>  Error happened in: main[scripts/crosstool-NG.sh]
[ERROR]    >>
[ERROR]    >>  For more info on this error, look at the file: 'build.log'
[ERROR]    >>  There is a list of known issues, some with workarounds, in:
[ERROR]    >>      '/home/andy/crosstool-ng/install/share/doc/ct-ng-1.13.0/B - Known issues.txt'
[ERROR]    

[ERROR]    Build failed in step 'Extracting and patching toolchain components'


一开始以为是没有装expat,sudo apt-get install expat后发现该软件已经装好,到/usr/lib目录下并没有发现libexpat.so文件,到网上查了下也没有相关的信息。因为之前在编译android文件系统的机器上用crosstool-ng编译成功过一个交叉编译链,所以觉得应该是没有安装相关包,所以在本机器上直接将编译android文件系统需要的相关包安装上(详见没博客上得编译android文件系统有关文章),并sudo apt-get install libexpat-dev后再次编译,最后成功编译出需要的工具链。


  • 1
    点赞
  • 3
    收藏
    觉得还不错? 一键收藏
  • 3
    评论
评论 3
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值