can not be used when making a shared object; recompile with -fPIC


relocation R_X86_64_32 against `a local symbol' can not be used when

making a shared object; recompile with -fPIC
/usr/local/lib/libz.a: could not read symbols: Bad value

解决办法 : 

vi Makefile
找到 CFLAGS=-O3 -DUSE_MMAP
在后面加入-fPIC,即变成CFLAGS=-O3 -DUSE_MMAP -fPIC
接下面步骤

make
      make install

你可能感兴趣的:(can not be used when making a shared object; recompile with -fPIC)