当我使用命令安装 openssl、curl 和 PHP 时,我的 64 位 Ubuntu 没有任何问题
OpenSSL
./configure enable-shared
curl
./configure --with-ssl=/usr/local/ssl --with-zlib
PHP
./configure .... --with-openssl --with-curl ....
但是在我的 32 位 Ubuntu 中,当我运行时,安装停止在 cURL 级别
make
命令
这是我得到的错误
/usr/bin/ld: warning: libssl.so.1.0.0, needed by ../lib/.libs/libcurl.so, not found (try using -rpath or -rpath-link)
/usr/bin/ld: warning: libcrypto.so.1.0.0, needed by ../lib/.libs/libcurl.so, not found (try using -rpath or -rpath-link)
我浏览了/usr/local/ssl 目录,确实找到了据称丢失的两个文件。我不知道这里发生了什么事。救命!
最佳答案
我发现了这个问题,我太愚蠢了,竟然忽略了 cURL 的网站文档。 我所要做的就是在配置之前传递运行时链接器的环境变量以使用共享库。
env LDFLAGS=-R/usr/local/ssl/lib ./configure --with-ssl --with-zlib
..它工作没有任何问题。我现在甚至在 Ubuntu 32 位中也支持 https。 这是文档链接 http://curl.haxx.se/docs/install.html
关于php - cURL 出现 SSL 依赖错误 libssl.so Ubuntu 32 位中需要 libcrypto.so,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/18124658/