I’ve read the directions several times, and I have been very careful while building the libraries as indicated in the documentation. When I do make package-status I have this list:
Installed YES: package ASPHERE
Installed YES: package BODY
Installed YES: package CLASS2
Installed YES: package COLLOID
Installed YES: package DIPOLE
Installed YES: package FLD
Installed YES: package GPU
Installed YES: package GRANULAR
Installed YES: package KIM
Installed YES: package KSPACE
Installed YES: package MANYBODY
Installed YES: package MC
Installed YES: package MEAM
Installed YES: package MISC
Installed YES: package MOLECULE
Installed YES: package MPIIO
Installed YES: package OPT
Installed YES: package PERI
Installed YES: package POEMS
Installed YES: package REAX
Installed YES: package REPLICA
Installed YES: package RIGID
Installed YES: package SHOCK
Installed YES: package SRD
Installed YES: package VORONOI
Installed YES: package XTC
Installed YES: package USER-ATC
Installed YES: package USER-AWPMD
Installed YES: package USER-CG-CMM
Installed YES: package USER-COLVARS
Installed YES: package USER-CUDA
Installed YES: package USER-EFF
Installed YES: package USER-LB
Installed YES: package USER-MISC
Installed YES: package USER-OMP
Installed NO: package USER-MOLFILE
Installed YES: package USER-PHONON
Installed YES: package USER-REAXC
Installed YES: package USER-SPH
My make file is adaptation of the one of the stock openmpi files provided. It looks like this:
openmpi = CentOS 6.5, mpic++ openmpi 1.6.5, adapted from original openmpi makefile
SHELL = /bin/sh
---------------------------------------------------------------------
compiler/linker settings
specify flags and libraries needed for your compiler
CC = mpic++
CCFLAGS = -O2 \
-funroll-loops -fstrict-aliasing -Wall -W -Wno-uninitialized
SHFLAGS = -fPIC
DEPFLAGS = -M
LINK = mpic++
LINKFLAGS = -O
LIB = -lstdc++
SIZE = size
ARCHIVE = ar
ARFLAGS = -rcsv
SHLIBFLAGS = -shared
---------------------------------------------------------------------
LAMMPS-specific settings
specify settings for LAMMPS features you will use
if you change any -D setting, do full re-compile after “make clean”
LAMMPS ifdef settings, OPTIONAL
see possible settings in doc/Section_start.html#2_2 (step 4)
LMP_INC = -DLAMMPS_GZIP -DLAMMPS_JPEG
MPI library, REQUIRED
see discussion in doc/Section_start.html#2_2 (step 5)
can point to dummy MPI library in src/STUBS as in Makefile.serial
INC = path for mpi.h, MPI compiler settings
PATH = path for MPI library
LIB = name of MPI library
MPI_INC =
MPI_PATH =
MPI_LIB =
FFT library, OPTIONAL
see discussion in doc/Section_start.html#2_2 (step 6)
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 =
FFT_PATH =
FFT_LIB =
JPEG and/or PNG library, OPTIONAL
see discussion in doc/Section_start.html#2_2 (step 7)
only needed if -DLAMMPS_JPEG or -DLAMMPS_PNG listed with LMP_INC
INC = path(s) for jpeglib.h and/or png.h
PATH = path(s) for JPEG library and/or PNG library
LIB = name(s) of JPEG library and/or PNG library
JPG_INC = -I/usr/local/include
JPG_PATH =
JPG_LIB = -L/usr/local/lib
---------------------------------------------------------------------
build rules and dependencies
no need to edit this section
include Makefile.package.settings
include Makefile.package
EXTRA_INC = (LMP_INC) (PKG_INC) (MPI_INC) (FFT_INC) (JPG_INC) (PKG_SYSINC)
EXTRA_PATH = (PKG_PATH) (MPI_PATH) (FFT_PATH) (JPG_PATH) $(PKG_SYSPATH)
EXTRA_LIB = (PKG_LIB) (MPI_LIB) (FFT_LIB) (JPG_LIB) $(PKG_SYSLIB)
Path to src files
vpath %.cpp …
vpath %.h …
Link target
(EXE): (OBJ)
(LINK) (LINKFLAGS) (EXTRA_PATH) (OBJ) (EXTRA_LIB) (LIB) -o $(EXE)
(SIZE) (EXE)
Library targets
lib: $(OBJ)
(ARCHIVE) (ARFLAGS) (EXE) (OBJ)
shlib: $(OBJ)
(CC) (CCFLAGS) (SHFLAGS) (SHLIBFLAGS) (EXTRA_PATH) -o (EXE) \
(OBJ) (EXTRA_LIB) $(LIB)
Compilation rules
.o:.cpp
(CC) (CCFLAGS) (SHFLAGS) (EXTRA_INC) -c $<
.d:.cpp
(CC) (CCFLAGS) (EXTRA_INC) (DEPFLAGS) < > @
Individual dependencies
DEPENDS = $(OBJ:.o=.d)
sinclude $(DEPENDS)
I’m using cuda55 toolkit, openmpi 1.6.5, and gcc 4.8.1
I see a lot warnings and then these errors.
mpic++ -O2 -funroll-loops -fstrict-aliasing -Wall -W -Wno-uninitialized -DLAMMPS_GZIP -DLAMMPS_JPEG -DLMP_USER_OMP -I…/…/lib/cuda -DLMP_USER_CUDA -I…/…/lib/colvars -I…/…/lib/awpmd/i
vutils/include -I…/…/lib/awpmd/systems/interact -I…/…/lib/atc -I…/…/src -I…/…/lib/reax -I…/…/lib/poems -DLMP_MPIIO -I…/…/lib/meam -I/usr/local/include -I/usr/local/inc
lude/voro++ -I/cm/shared/apps/openkim-api-v1.4.0/KIM_API -I/cm/shared/apps/cuda55/toolkit/5.5.22/include -DUNIX -DNO_PREC_TIMING -DFFT_CUFFT -DCUDA_PRECISION=2 -DCUDA_ARCH=20 -c …
/pair_gran_hooke_history.cpp
…/pair_gran_hooke.cpp: In member function ‘virtual void LAMMPS_NS::PairGranHooke::compute(int, int)’:
…/pair_gran_hooke.cpp:44:27: warning: unused variable ‘itype’ [-Wunused-variable]
int i,j,ii,jj,inum,jnum,itype,jtype;
^
…/pair_gran_hooke.cpp:44:33: warning: unused variable ‘jtype’ [-Wunused-variable]
int i,j,ii,jj,inum,jnum,itype,jtype;
^
…/pair_gran_hooke.cpp: In member function ‘virtual double LAMMPS_NS::PairGranHooke::single(int, int, int, int, double, double, double, double&)’:
…/pair_gran_hooke.cpp:238:19: warning: unused variable ‘fs1’ [-Wunused-variable]
double fn,fs,ft,fs1,fs2,fs3;
^
…/pair_gran_hooke.cpp:238:23: warning: unused variable ‘fs2’ [-Wunused-variable]
double fn,fs,ft,fs1,fs2,fs3;
^
…/pair_gran_hooke.cpp:238:27: warning: unused variable ‘fs3’ [-Wunused-variable]
double fn,fs,ft,fs1,fs2,fs3;
^
…/pair_gran_hooke.cpp: At global scope:
…/pair_gran_hooke.cpp:229:8: warning: unused parameter ‘itype’ [-Wunused-parameter]
double PairGranHooke::single(int i, int j, int itype, int jtype, double rsq,
^
…/pair_gran_hooke.cpp:229:8: warning: unused parameter ‘jtype’ [-Wunused-parameter]
…/pair_gran_hooke.cpp:229:8: warning: unused parameter ‘factor_coul’ [-Wunused-parameter]
…/pair_gran_hooke.cpp:229:8: warning: unused parameter ‘factor_lj’ [-Wunused-parameter]
mpic++ -O2 -funroll-loops -fstrict-aliasing -Wall -W -Wno-uninitialized -DLAMMPS_GZIP -DLAMMPS_JPEG -DLMP_USER_OMP -I…/…/lib/cuda -DLMP_USER_CUDA -I…/…/lib/colvars -I…/…/lib/awpmd/i
vutils/include -I…/…/lib/awpmd/systems/interact -I…/…/lib/atc -I…/…/src -I…/…/lib/reax -I…/…/lib/poems -DLMP_MPIIO -I…/…/lib/meam -I/usr/local/include -I/usr/local/inc
lude/voro++ -I/cm/shared/apps/openkim-api-v1.4.0/KIM_API -I/cm/shared/apps/cuda55/toolkit/5.5.22/include -DUNIX -DNO_PREC_TIMING -DFFT_CUFFT -DCUDA_PRECISION=2 -DCUDA_ARCH=20 -c …
/pair_gran_hooke_history_omp.cpp
In file included from …/pair_gran_hooke_cuda.cpp:55:0:
…/fix_pour.h: In member function ‘virtual void LAMMPS_NS::PairGranHookeCuda::init_style()’:
…/fix_pour.h:38:15: error: ‘int LAMMPS_NS::FixPour::ntype’ is private
int ninsert,ntype,seed;
^
…/pair_gran_hooke_cuda.cpp:188:47: error: within this context
pour_type = ((FixPour *) modify->fix[i])->ntype;
^
In file included from …/pair_gran_hooke_cuda.cpp:55:0:
…/fix_pour.h:40:21: error: ‘double LAMMPS_NS::FixPour::radius_max’ is private
double radius_one,radius_max;
^
…/pair_gran_hooke_cuda.cpp:189:49: error: within this context
pour_maxrad = ((FixPour *) modify->fix[i])->radius_max;
^
make[1]: *** [pair_gran_hooke_cuda.o] Error 1
make[1]: *** Waiting for unfinished jobs…
…/pair_gran_hooke_history.cpp: In member function ‘virtual void LAMMPS_NS::PairGranHookeHistory::compute(int, int)’:
…/pair_gran_hooke_history.cpp:89:27: warning: unused variable ‘itype’ [-Wunused-variable]
int i,j,ii,jj,inum,jnum,itype,jtype;
^
…/pair_gran_hooke_history.cpp:89:33: warning: unused variable ‘jtype’ [-Wunused-variable]
int i,j,ii,jj,inum,jnum,itype,jtype;
^
…/pair_gran_hooke_history.cpp: In member function ‘virtual double LAMMPS_NS::PairGranHookeHistory::single(int, int, int, int, double, double, double, double&)’:
…/pair_gran_hooke_history.cpp:619:31: warning: unused variable ‘polyhertz’ [-Wunused-variable]
double mi,mj,meff,damp,ccel,polyhertz;
Then make fails altogether with . . .
^
…/pair_gran_hooke_history_omp.cpp:102:28: warning: unused variable ‘jtype’ [-Wunused-variable]
int i,j,ii,jj,jnum,itype,jtype;
^
…/pair_gran_hooke_history_omp.cpp: In instantiation of ‘void LAMMPS_NS::PairGranHookeHistoryOMP::eval(int, int, LAMMPS_NS::ThrData*) [with int EVFLAG = 1; int SHEARUPDATE = 0]’:
…/pair_gran_hooke_history_omp.cpp:90:37: required from here
…/pair_gran_hooke_history_omp.cpp:102:22: warning: unused variable ‘itype’ [-Wunused-variable]
int i,j,ii,jj,jnum,itype,jtype;
^
…/pair_gran_hooke_history_omp.cpp:102:28: warning: unused variable ‘jtype’ [-Wunused-variable]
int i,j,ii,jj,jnum,itype,jtype;
^
…/pair_gran_hooke_history_omp.cpp: In instantiation of ‘void LAMMPS_NS::PairGranHookeHistoryOMP::eval(int, int, LAMMPS_NS::ThrData*) [with int EVFLAG = 0; int SHEARUPDATE = 1]’:
…/pair_gran_hooke_history_omp.cpp:92:49: required from here
…/pair_gran_hooke_history_omp.cpp:102:22: warning: unused variable ‘itype’ [-Wunused-variable]
int i,j,ii,jj,jnum,itype,jtype;
^
…/pair_gran_hooke_history_omp.cpp:102:28: warning: unused variable ‘jtype’ [-Wunused-variable]
int i,j,ii,jj,jnum,itype,jtype;
^
…/pair_gran_hooke_history_omp.cpp: In instantiation of ‘void LAMMPS_NS::PairGranHookeHistoryOMP::eval(int, int, LAMMPS_NS::ThrData*) [with int EVFLAG = 0; int SHEARUPDATE = 0]’:
…/pair_gran_hooke_history_omp.cpp:93:37: required from here
…/pair_gran_hooke_history_omp.cpp:102:22: warning: unused variable ‘itype’ [-Wunused-variable]
int i,j,ii,jj,jnum,itype,jtype;
^
…/pair_gran_hooke_history_omp.cpp:102:28: warning: unused variable ‘jtype’ [-Wunused-variable]
int i,j,ii,jj,jnum,itype,jtype;
^
make[1]: Leaving directory `/cm/shared/apps/lammps/gcc/64/lammps-1Feb14/src/Obj_openmpi’
make: *** [openmpi] Error 2