免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 27529 | 回复: 1
打印 上一主题 下一主题

[Linux] glib交叉编译问题 [复制链接]

论坛徽章:
1
2015亚冠之塔什干火车头
日期:2015-06-08 10:15:34
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2018-12-21 10:44 |只看该作者 |倒序浏览
我在交叉编译的时候出现如下问题
warning: libffi.so.6, needed by ./.libs/libgobject-2.0.so, not found (try using -rpath or -rpath-link)
./.libs/libgobject-2.0.so: undefined reference to `ffi_type_double'
./.libs/libgobject-2.0.so: undefined reference to `ffi_type_pointer'
./.libs/libgobject-2.0.so: undefined reference to `ffi_type_sint64'
./.libs/libgobject-2.0.so: undefined reference to `ffi_type_void'
./.libs/libgobject-2.0.so: undefined reference to `ffi_type_sint32'
./.libs/libgobject-2.0.so: undefined reference to `ffi_type_uint64'
./.libs/libgobject-2.0.so: undefined reference to `ffi_call'
./.libs/libgobject-2.0.so: undefined reference to `ffi_type_uint32'
./.libs/libgobject-2.0.so: undefined reference to `ffi_prep_cif'
./.libs/libgobject-2.0.so: undefined reference to `ffi_type_float'
collect2: error: ld returned 1 exit status
make[4]: *** [gobject-query] Error 1




遇到同样的问题,我把头文件和库路径都指定到了,
LIBFFI_LIBS=-L$CUR_PATH'/../libffi/usr/lib -lffi'
LIBFFI_CFLAGS=-I$CUR_PATH'/../libffi/usr/include'
我这样指定好的,但为什么还会出现这样的问题啊?
makefile中的LIBFFI_CFLAGS和LIBFFI_LIBS路径都指的路径是对的。网上搜了好多,但是还是没有解决问题。

论坛徽章:
0
2 [报告]
发表于 2019-01-08 23:51 |只看该作者
用命令行nm 所依赖的库:*.a 在用grap搜一搜ffi_type_double是否有,T表示有,U表示没有
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP