configure: error: zlib library and headers are required

(1)直接看是zlib没安装导致的,yum list |grep zlib* 看到的是全部都安装好的;

(2)直接打开configure,这个是一个shell脚本,找到报错的这一行;设置set -x结果发现一大串的日志输出,并没有什么有效的信息;

(3)打开config.log,里面有报错的,原来这里有报错

configure:35519: result: no
configure:35524: checking whether zlib support suffices
configure:35527: error: zlib library and headers are required

  具体的命令

gcc -std=gnu99 -o conftest -g -O2 -I/usr/local/include -L/usr/local/lib64 conftest.c -lrt -ldl -lm

  单独看到这里测试的是zlib的版本,必须是高于1.2.5

 

相关文章:

  • 2021-05-15
  • 2021-12-09
  • 2022-12-23
  • 2022-12-23
  • 2021-08-19
  • 2021-12-29
  • 2022-12-23
猜你喜欢
  • 2021-06-30
  • 2021-07-19
  • 2022-12-23
  • 2022-01-24
  • 2021-06-09
  • 2021-11-11
相关资源
相似解决方案