/usr/bin/ld: /usr/local/lib/libjemalloc.a(jemalloc.o): relocation R_X86_64_32S against `je_index2size_tab' can not be used when making a shared object; recompile with -fPIC
则将修改MakeFile
vim MakeFile
条加加黑字体
CPPFLAGS := -D_GNU_SOURCE -D_REENTRANT -I$(srcroot)include -I$(objroot)include –fPIC
6.重新编译文件
make &&make install_lib_static
本文详细介绍了如何解决在编译过程中遇到的jemalloc链接错误,特别是针对‘relocation R_X86_64_32S against `je_index2size_tab' cannot be used when making a shared object; recompile with -fPIC’这一错误。通过修改MakeFile,加入-fPIC选项,最终成功解决了问题。
722

被折叠的 条评论
为什么被折叠?



