问题描述:
安装valgrind 时,./configure成功后,make时提示错误/usr/bin/ld: /usr/lib64/libmpi.a(laminit.o): relocation R_X86_64_32S against `lam_mpi_comm_world' can not be used when making a shared object; recompile with -fPIC
解决方案:
1、下载 lam-7.1.2.tar.bz2 ,解压缩后一路./configure --enable-shared && make && make install;
2、成功后,拷贝lam-7.1.2/share/liblam/.libs/liblam.a和lam-7.1.2/share/libmpi/.libs/libmpi.a到/usr/lib64/目录下,覆盖原文件;
3、再次进入valgrind文件夹,make成功。