1,如果使用gcc-4.1编译的openmpi, 后面abinit在make时会出现编译问题:
error: bad value (native) for -mtune= switch
所以重新安装gcc-4.5.0.
2 安装gcc-4.5.0之前要安装三个程序包,分别为:gmp-4.3.2,mpfr-2.4.2,mpc-0.8.1。按顺序安装到自己目录中,
$ ../configure --prefix="/home/zjma/program/gmp-4.3.2"
$../configure --prefix="/home/zjma/program/mpfr-2.4.2" --with-gmp="/home/zjma/program/gmp-4.3.2/"
$../configure --prefix="/home/zjma/program/mpc-0.8.1" --with-gmp="/home/zjma/program/gmp-4.3.2/" --with-mpfr="/home/zjma/program/mpfr-2.4.2/"
3 安装gcc-4.5.0
$ ../configure --prefix="/home/zjma/program/gcc-4.5.0" --with-gmp="/home/zjma/program/gmp-4.3.2/" --with-mpfr="/home/zjma/program/mpfr-2.4.2/" --with-mpc="/home/zjma/program/mpc-0.8.1/"
$ make
$ make install
4 使用gcc-4.5.0重新编译openmpi-1.4
$ ../configure FC="/home/zjma/program/gcc-4.5.0/bin/gfortran" CC="/home/zjma/program/gcc-4.5.0/bin/gcc" CXX="/home/zjma/program/gcc-4.5.0/bin/g++" F77="/home/zjma/program/gcc-4.5.0/bin/gfortran" --prefix="/home/zjma/program/openmpi-1.4.2"
$ make
$ make install
5 下载abinit6.6.1的所有插件到~/.abinit/tarballs/下
地址:http://www.abinit.org/downloads/plug-in-sources
6 使用新编译的openmpi安装并行版abinit6.6.1
$ ../configure --prefix="/home/zjma/abinit-6.6.1" --with-mpi-prefix="/home/zjma/program/openmpi-1.4.2/" --enable-mpi="yes" | tee 1
$ make
$ make install
https://blog.sciencenet.cn/blog-90975-427216.html
上一篇:
程序使用:MS.CASTEP错误分析下一篇:
BRMIX: very serious problems the old and ……错误解决方案