Are you using some CentOS Makefile?
I would not use the CentOS repository of LAMMPS or the Makefile therein.
Download LAMMPS from the LAMMPS website, and use their Makefile.mpi.
If you don’t need QUIP, then you just need to make minor modifications for your compiler libraries if they aren’t in your PATH, etc.
I’m not familiar with compiling with QUIP, but LAMMPS appears to have instructions in …/lib/quip
The rest of your procedure looks more or less correct to me, assuming the libraries are in your PATH or pointed to correctly in the Makefile.
I using Makefile.mpi in MAKE dir
SHELL = /bin/sh
---------------------------------------------------------------------
compiler/linker settings
specify flags and libraries needed for your compiler
CC = /opt/openmpi-1.4.5/bin/mpicxx
CCFLAGS = -O3 -fPIC -align -Zp8 -axP -unroll -xP -ip
SHFLAGS = -fPIC
DEPFLAGS = -M
LINK = mpicxx
LINKFLAGS = -g -O
LIB = /opt/openmpi-1.4.5/lib
SIZE = size
ARCHIVE = ar
ARFLAGS = -rc
SHLIBFLAGS = -shared
---------------------------------------------------------------------
LAMMPS-specific settings, all OPTIONAL
specify settings for LAMMPS features you will use
if you change any -D setting, do full re-compile after “make clean”
LAMMPS ifdef settings
see possible settings in Section 2.2 (step 4) of manual
LMP_INC = -DLAMMPS_GZIP -DLAMMPS_MEMALIGN=64
MPI library
see discussion in Section 2.2 (step 5) of manual
MPI wrapper compiler/linker can provide this info
can point to dummy MPI library in src/STUBS as in Makefile.serial
use -D MPICH and OMPI settings in INC to avoid C++ lib conflicts
INC = path for mpi.h, MPI compiler settings
PATH = path for MPI library
LIB = name of MPI library
MPI_INC = -DMPICH_SKIP_MPICXX -DOMPI_SKIP_MPICXX=1 -I/opt/openmpi-1.4.5/include
MPI_PATH = -L/opt/openmpi-1.4.5/lib
MPI_LIB = -lmpich -lpthread
FFT library
see discussion in Section 2.2 (step 6) of manual
can be left blank to use provided KISS FFT library
INC = -DFFT setting, e.g. -DFFT_FFTW, FFT compiler settings
PATH = path for FFT library
LIB = name of FFT library
FFT_INC = -DFFT_FFTW -I/usr/local/fftw-3.3.6-pl2/iclude
FFT_PATH = -L/usr/local/fftw-3.3.6-pl2/lib
FFT_LIB = -lfftw
Your Open MPI Wrapper is looking for an intel compiler, icpc. Do you have intel compilers?
If so, make sure it is in your PATH.
That is the error message you are showing. The OpenMPI wrapper is looking for icpc presumably because that is what you configured it with. It can’t find it.
"The Open MPI wrapper compiler was unable to find the specified compiler
icpc in your PATH.
Note that this compiler was either specified at configure time or in
one of several possible environment variables."
I’m trying to
source /opt/intel/bin/ifortvars.sh intel 64
but return always the message error
The Open MPI wrapper compiler was unable to find the specified compiler
icpc in your PATH.
peraphs it’s a problem with flag
compiler/linker settings
specify flags and libraries needed for your compiler
CC = /opt/openmpi-1.4.5/bin/mpicxx
CCFLAGS = -g -O3
SHFLAGS = -fPIC
DEPFLAGS = -M
LINK = /opt/openmpi-1.4.5/bin/mpicxx
LINKFLAGS = -g -O
LIB = -L/opt/openmpi-1.4.5/lib
SIZE = size
ARCHIVE = ar
ARFLAGS = -rc
SHLIBFLAGS = -shared
---------------------------------------------------------------------
LAMMPS-specific settings, all OPTIONAL
specify settings for LAMMPS features you will use
if you change any -D setting, do full re-compile after “make clean”
LAMMPS ifdef settings
see possible settings in Section 2.2 (step 4) of manual
LMP_INC = -DLAMMPS_GZIP -DLAMMPS_MEMALIGN=64
MPI library
see discussion in Section 2.2 (step 5) of manual
MPI wrapper compiler/linker can provide this info
can point to dummy MPI library in src/STUBS as in Makefile.serial
use -D MPICH and OMPI settings in INC to avoid C++ lib conflicts
INC = path for mpi.h, MPI compiler settings
PATH = path for MPI library
LIB = name of MPI library
MPI_INC = -I/opt/openmpi-1.4.5/include -DMPICH_SKIP_MPICXX -DOMPI_SKIP_MPICXX=1
MPI_PATH = -L/opt/openmpi-1.4.5/lib
MPI_LIB = -lpthread
FFT library
see discussion in Section 2.2 (step 6) of manual
can be left blank to use provided KISS FFT library
INC = -DFFT setting, e.g. -DFFT_FFTW, FFT compiler settings
PATH = path for FFT library
LIB = name of FFT library
FFT_INC = -I/usr/local/fftw-3.3.6-pl2/include -DFFT_FFTW
FFT_PATH = -L/usr/local/fftw-3.3.6-pl2/lib
FFT_LIB = -lfftw
regards
Al