Copy Makefile (I attached) to lammps/src/MAKE/Makefile.ubuntu (make sure you change the name of file to Makefile.ubuntu)
compile: Make sure you are sitting in lammps-24Jan10/src (not the MAKE directory!). You’ll need the STUBS library if you’re making a serial binary
# for parallel binaries
make ubuntu
# for serial, make STUBS, then LAMMPS
cd STUBS ; make ; cd ..
make ubuntu
Try an example to verify it works
# change to the examples/crack directory
cd ../examples/crack
# for serial or parallel builds
../../lmp_ubuntu < in.crack
# for parallel builds only
mpiexec -np 2 ../../lmp_ubuntu < in.crack
The error is no mpi,h file. So you need to make
settings in the MPI section of the Makefile.g++.
The doc pages on building LAMMPS discuss this
the MPI settings in detail.
Thank you for your response.I am not using Ubuntu, it is RH Linux box, where I try to install Lammps .
By MPI settings , can you specify which you are referring to ,is it "Building LAMMPS as a library ".
I was able to compile and get my executable as lmp_serial.
The process was as :
cd src/STUBS
make
cd …
make serial
I used g++ as compiler in my Makefile.serial.
I am sorry to ask this , if someone can elaborate me on the compilation steps for the the parallel, where I need to make the changes in Makefile.linux.
John,
Yixin’s fix will work if you don’t (immediately) intend on using a kspace solver for long-range coulombic interactions.
If you do, you’ll need to properly link to your FFT library (i.e. edit the ‘FFT_PATH =’ line), since it looks like your compiler can’t find it. Do you happen to know where that is?
Tyler
As Yixin said , it fixed my error and I got the executable.
At present I do not intend to use kspace for long range columbic interactions. I am not sure on how to link it to the FFT library ( I will see the documentation).I will appreciate if you would like to suggest on this.
Hey John,
Section 2.2.4 deals specifically with FFT library linking. After reading that, I also realized that what I told you was wrong. You’ll only need to link to an FFT library for the PPPM kspace solver (but that one does happen to be fastest for most large systems).
The documentation is pretty straightforward from there, although you may need to lookup documentation for whichever FFT library you use to specficy FFT_PATH.