交叉编译libcurl库遇到的 Unable to link function recv 错误解决办法

版权声明:欢迎传播,请标明出处。 https://blog.csdn.net/u201011221/article/details/84134905

libcurl error: Unable to link function recv

最近在Android上交叉编译libcurl库, 遇到` Unable to link function recv `, 但是同样的脚本, 在同事电脑上跑的好好的, 尴尬...这种环境问题是最烦人的了....

搜了下, 找到如下sof, 说这个函数 `-lz , which is the flag to link the zlib`.

https://stackoverflow.com/questions/44343570/cross-compiling-libcurl-for-arm-linux-gnueabihf-unable-to-link-function-recv

忽然想到前两天编译android源码, 手动下载安装了zlib, 于是`./configure; make; make uninstall`卸载zlib, 在重新编译便ok了.

成功提示如下:

checking for recv... yes
checking types of args and return type for recv... int,void *,size_t,unsigned int,int

这里给两个排bug的小tip:

扫描二维码关注公众号,回复: 4558743 查看本文章

set -x 显示执行的bash命令.

出错后, 找到config.log, 查看详细错误信息.

猜你喜欢

转载自blog.csdn.net/u201011221/article/details/84134905