安装openssl的时候出现了下面的问题,试了n种方法,还是有编译错误,有装成功过的朋友们,麻烦看一下,谢谢

燕赵一剑 2015-09-06 11:08:46
/usr/bin/ld: libcrypto.a(cbc128.o): relocation R_X86_64_32 against `a local symbol' can not be used when making a shared object; recompile with -fPIC
libcrypto.a(cbc128.o): could not read symbols: Bad value
collect2: ld 返回 1
make[4]: *** [link_a.gnu] 错误 1
make[4]: Leaving directory `/home/source/openssl-1.0.0s'
make[3]: *** [do_linux-shared] 错误 2
make[3]: Leaving directory `/home/source/openssl-1.0.0s'
make[2]: *** [libcrypto.so.1.0.0] 错误 2
make[2]: Leaving directory `/home/source/openssl-1.0.0s'
make[1]: *** [shared] 错误 2
make[1]: Leaving directory `/home/source/openssl-1.0.0s/crypto'
make: *** [build_crypto] 错误 1
上面是make以后出现的错误。
下面是执行时的命令:
./config --prefix=/home/openssl enable-shared
甚至执行的时候加上了CFLAGS="-O3 -fPIC"以后再make的时候还是会出现上面的错误。
...全文
586 1 打赏 收藏 转发到动态 举报
AI 作业
写回复
用AI写文章
1 条回复
切换为时间正序
请发表友善的回复…
发表回复
  • 打赏
  • 举报
回复
you might want to find out why openssl was linked with the static library: libcrypto.a, instead of libcrypto.so if the shared library is missing, get it installed. otherwise, recompile libcrypto with -fPIC

4,465

社区成员

发帖
与我相关
我的任务
社区描述
Linux/Unix社区 内核源代码研究区
社区管理员
  • 内核源代码研究区社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧