美文网首页
No package 'libcares' found

No package 'libcares' found

作者: 不做秃顶的程序猿 | 来源:发表于2020-07-07 20:37 被阅读0次

    centos7 编译 grpc 时报错:

    Package libcares was not found in the pkg-config search path.
    Perhaps you should add the directory containing `libcares.pc'
    to the PKG_CONFIG_PATH environment variable
    No package 'libcares' found
    Package libcares was not found in the pkg-config search path.
    Perhaps you should add the directory containing `libcares.pc'
    to the PKG_CONFIG_PATH environment variable
    No package 'libcares' found
    

    原因

    缺少 c-ares

    解决方案

    tar -zxvf c-ares-xxxx.tar.gz
    cd c-ares-xxxx
    ./configure
    make &&make install
    
    • 修改环境变量
      • /etc/profile 中增加 export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig:$PKG_CONFIG_PATH
      • source /etc/profile

    相关文章

      网友评论

          本文标题:No package 'libcares' found

          本文链接:https://www.haomeiwen.com/subject/mqgzqktx.html