zoukankan      html  css  js  c++  java
  • CentOS6.5上给curl安装ssl时错误解决

    1 在CentOS上使用PHP的curl访问HTTPS页面时,出现错误“Protocol https not supported or disabled in libcurl”。

    表示curl未启用https,需要重新编译php所使用的curl库。

    cd curl-7.31.0
    ./configure --prefix=/home/www/thirdlib/curl --with-ssl=/ueidc/openssl

    出现错误提示:

    checking for SSL_connect in -lssl... no
    checking for ssl with RSAglue/rsaref libs in use... checking for SSL_connect in -lssl... (cached) no
    configure: error: OpenSSL libs and/or directories were not found where specified!

    是因为安装openssl时没启用shared选项,没有生成共享库

    2 问题:

    /usr/bin/ld: warning: libcrypto.so.1.0.0, needed by ../lib/.libs/libcurl.so, not found (try using -rpath or -rpath-link)

    解决方式:

    env LDFLAGS=-R/home/www/thirdlib/openssl/lib ./configure --prefix=/home/www/thirdlib/curl --with-ssl=/home/www/thirdlib/openssl

    3 ./configure --with-php-config=/home/www/php/bin/php-config --with-curl=/home/www/thirdlib/curl

  • 相关阅读:
    监控Nginx
    监控Tomcat
    监控memcache
    监控Redis
    14-SpringCloud Bus
    13-SpringCloud Config
    12-SpringCloud GateWay
    11-SpringCloud Hystrix
    10-SpringCloud OpenFeign
    09-SpringCloud Ribbon
  • 原文地址:https://www.cnblogs.com/thrillerz/p/3961660.html
Copyright © 2011-2022 走看看