diff --git a/examples/COUPLE/fortran2/LAMMPS-wrapper.cpp b/examples/COUPLE/fortran2/LAMMPS-wrapper.cpp index b5b265b4dd..1301bfe348 100644 --- a/examples/COUPLE/fortran2/LAMMPS-wrapper.cpp +++ b/examples/COUPLE/fortran2/LAMMPS-wrapper.cpp @@ -23,6 +23,7 @@ #include #include "LAMMPS-wrapper.h" +#define LAMMPS_LIB_MPI 1 #include #include #include diff --git a/examples/COUPLE/fortran2/Makefile b/examples/COUPLE/fortran2/Makefile index fe66914892..f8a2126233 100644 --- a/examples/COUPLE/fortran2/Makefile +++ b/examples/COUPLE/fortran2/Makefile @@ -14,7 +14,7 @@ CXXLIB = -lstdc++ # replace with your C++ runtime libs # Flags for Fortran compiler, C++ compiler, and C preprocessor, respectively FFLAGS = -O2 -fPIC CXXFLAGS = -O2 -fPIC -CPPFLAGS = -DOMPI_SKIP_MPICXX=1 -DMPICH_SKIP_MPICXX -DLAMMPS_LIB_MPI +CPPFLAGS = -DOMPI_SKIP_MPICXX=1 -DMPICH_SKIP_MPICXX all : liblammps_fortran.a liblammps_fortran.so diff --git a/examples/COUPLE/fortran_dftb/LAMMPS-wrapper.cpp b/examples/COUPLE/fortran_dftb/LAMMPS-wrapper.cpp index b5b265b4dd..1301bfe348 100644 --- a/examples/COUPLE/fortran_dftb/LAMMPS-wrapper.cpp +++ b/examples/COUPLE/fortran_dftb/LAMMPS-wrapper.cpp @@ -23,6 +23,7 @@ #include #include "LAMMPS-wrapper.h" +#define LAMMPS_LIB_MPI 1 #include #include #include