LAMMPS compilation on cluster

I have made cluster using openmpi-1.4.1-2 instead of mpich1 using the procedure as mentioned at using ubuntu 10.04
http://www.linux.com/community/blogs/Building-a-Beowulf-Cluster-in-just-13-steps-.html

I have not included LD_LIBRARY_PATH as mentioned as mentioned there (let me know how to do that also )

I am trying to compile lammps on the cluster

After uncompressing lammps.tar.gz,(actually, libs for LAMMPS is part of lammps.tar.gz)

cd lib/reax
Change gfortran to mpif77 in Makefile.gfortran
sudo make -f Makefile.gfortran`

cd lib/meam
Change gfortran to mpif77 in Makefile.gfortran
sudo make -f Makefile.gfortran

cd lib/poems
Change g++ to mpicxx in Makefile.g++
sudo make -f Makefile.g++

LAMMPS
cd src

Check which packages are included
sudo make package-status

Choose all standard packages to be included
sudo make yes-standard

If you don’t have GPU, then exclude gpu package. Otherwise, you will see tons of error message when you compile it.
sudo make no-gpu

Edit MAKE/Makefile.linux

CC = mpicxx
CCFLAGS = -g –O
DEPFLAGS = -M
LINK = mpicxx
LINKFLAGS = -g –O
LIB =
FFT_INC = -I/application/fftw-2.1.5-gnu/
include -DFFT_FFTW
FFT_PATH = -L/application/fftw-2.1.5-gnu/lib
FFT_LIB = -lfftw

MPI_INC = -I/application/openmpi-1.4.2-gnu/include -DMPICH_IGNORE_CXX_SEEK
MPI_PATH = -L/application/openmpi-1.4.2-gnu/lib
MPI_LIB = -lpthread –lmpi

Build LAMMPS as an executable and library as well

sudo make linux

then i get the following error (last few lines)

Makefile:96: temper.d: No such file or directory
Makefile:96: thermo.d: No such file or directory
Makefile:96: timer.d: No such file or directory
Makefile:96: universe.d: No such file or directory
mpicxx -g –O -DLAMMPS_GZIP -I…/…/lib/reax -I…/…/lib/poems -I…/…/lib/meam -I/application/openmpi-1.4.1-2-gnu/include -DMPICH_IGNORE_CXX_SEEK -I/application/fftw-2.1.5-gnu/include -DFFT_FFTW -M universe.cpp > universe.d
g++: –O: No such file or directory
make[1]: *** [universe.d] Error 1
make[1]: Leaving directory `/home/mpiuser/lammps-15Mar11/src/Obj_linux’
make: *** [linux] Error 2

Please let me know how to make LAMMPS executable

There is no reason to use sudo to build LAMMPS as root:

sudo make linux

The error you get is that it can't find g++, which means
you have bigger problems than building LAMMPS.

Steve

Dear Karan and Steve,

mpicxx -g –O -DLAMMPS_GZIP -I../../lib/reax -I../../lib/poems -I../../lib/meam -I/application/openmpi-1.4.1-2-gnu/include -DMPICH_IGNORE_CXX_SEEK -I/application/fftw-2.1.5-gnu/include -DFFT_FFTW -M universe.cpp > universe.d

g++: –O: No such file or directory

I think the error comes from a typo: the minus before O is not
standard, so you should replace "–O" by "-O" in your Makefile flags.
The question is, how did this strange minus appeared in your Makefile?

Best,
Laurent