relocation R_X86_64_32 against `a local symbol'
2012-04-16 19:04
169 查看
/usr/bin/ld: /usr/local/lib/libbz2.a: relocation R_X86_64_32 against `a local symbol' can not be
used when making a shared object; recompile with -fPIC
解决办法
在CFLAGS上加入 -fPIC
# cd zlib-1.2.3
# CFLAGS="-O3 -fPIC" ./configure --prefix=/usr/local/zlib
# make && make install
注:这是在64位的主机上做时才需要的,32位的直接./configure --prefix=/usr/local/zlib 就行
used when making a shared object; recompile with -fPIC
解决办法
在CFLAGS上加入 -fPIC
# cd zlib-1.2.3
# CFLAGS="-O3 -fPIC" ./configure --prefix=/usr/local/zlib
# make && make install
注:这是在64位的主机上做时才需要的,32位的直接./configure --prefix=/usr/local/zlib 就行
相关文章推荐
- relocation R_X86_64_32 against `.rodata' can not be used when making a shared object; recom
- 编译程序遇到问题 relocation R_X86_64_32 against `.rodata' can not be used when making a shared object;
- 编译动态库出现问题relocation R_X86_64_32 against `a local symbol' can not be used when making a shared object
- jsoncpp relocation R_X86_64_32 against `.rodata' can not be used when making a shared object; ……
- php5.2.17安装libpng时报zlib的错误:libz.a(crc32.o): relocation R_X86_64_32 against `a local symbol' can not
- 学习笔记:relocation R_X86_64_32 against `.rodata' can not be used when making a shared object;
- .libs/alloc.o: relocation R_X86_64_32 against `.rodata.str1.8' can not be used when making a shared
- 编译动态库时遇到relocation R_X86_64_32 against `a local symbol'的错误
- relocation truncated to fit: R_X86_64_PC32错误排除
- live555 编译动态库时遇到relocation R_X86_64_32 against `a local symbol'的错误
- relocation R_X86_64_32 against `.rodata' can not be used when making a shared object;
- relocation truncated to fit: R_X86_64_32
- relocation R_X86_64_32 against XXXXX can not be used when making a shared object;recompile with -fPI
- relocation truncated to fit: R_X86_64_PC32 against symbolXXX
- Linux:编译动态库时遇到的错误relocation R_X86_64_32 against `a local symbol'
- linux 生成动态库时提示relocation R_X86_64_32 against `.rodata' can not be used when making a shared object;
- 解决方法/usr/bin/ld: /usr/local/lib/liblua.a(lapi.o): relocation R_X86_64_32 against `luaO_nilobject_'
- CentOS-6.3 编译erlang-otp 17.0 报relocation R_X86_64_32 against `OPENSSL_ia32cap_P' can not be used when making a shared object; recompile with -fPIC错误
- sqlite 动态库 relocation R_X86_64_32 against `.
- 关于/usr/local/lib/libz.a(zutil.o): relocation R_X86_64_32 against `.rodata.str1.1' can not be used when making a shared object; recompile with -fPIC解决办法