【发布时间】:2015-03-29 20:02:18
【问题描述】:
所以在今晚对这个问题进行了详尽的研究之后,我仍然感到困惑。我正在运行 Debian Wheezy,我正在尝试让 curl 支持 ssl,但它显然拒绝这样做。我试图删除 OpenSSL 和 Curl 的所有痕迹。然后使用 apt-get install OpenSSL,它会安装“OpenSSL 1.0.1e”。然后我去尝试从源代码编译curl,认为apt-get可能只是安装curl很傻。我尝试使用它进行配置。
./configure --with-ssl LDFLAGS="-ldl"
因为否则它会传递一些错误。如果没有 LDFLAGS,我会在我的日志中得到这个。 config.log 但正如我所说,在开启 LDFLAGS 的情况下,我可以实际创建配置,但是当我开始制作时……嗯……那是一切似乎都崩溃了,她不会安装的时候。
/usr/bin/ld: /usr/local/ssl/lib/libcrypto.a(ecp_nistz256.o): relocation R_X86_64_32 against `.rodata.str1.1' can not be used when making a shared object; recompile with -fPIC
/usr/local/ssl/lib/libcrypto.a: could not read symbols: Bad value
collect2: error: ld returned 1 exit status
make[2]: *** [libcurl.la] Error 1
make[2]: Leaving directory `/home/openssl/curl-7.27.0/lib'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/openssl/curl-7.27.0/lib'
make: *** [all-recursive] Error 1
经过一番研究,有人建议使用 -fPIC 构建 OpenSSL。所以我从系统中清除了 OpenSSL 并尝试从源代码安装,选择安装版本,1.0.2 从这个链接https://www.openssl.org/source/openssl-1.0.2.tar.gz
这实际上进行得很好,我确保包含 -fPIC 标志。然后我又去安装Curl,但最终还是出现了这个错误..这很奇怪..所以现在我坐在这里摸不着头脑。我已经卸载、重新安装、重新编译和安装,做了所有我能想到的事情,但我仍然非常难过。
对不起,如果我今晚的格式很糟糕,对我来说已经很晚了。但如果有人能帮我一把,将不胜感激。
【问题讨论】:
标签: linux ssl curl openssl debian