Files
lammps/examples/COUPLE/lammps_spparks/Makefile.mpi
2023-04-14 12:11:09 -06:00

51 lines
883 B
Makefile

# Makefile for grain growth via LAMMPS <-> SPPARKS coupling
SHELL = /bin/sh
# Paths to your local LAMMPS and SPPARKS home directories
LAMMPS = /home/sjplimp/lammps/git
SPPARKS = /home/sjplimp/spparks/git
# System-specific settings
CC = mpicxx
CCFLAGS = -g -O -DMPICH_IGNORE_CXX_SEEK -I../library
DEPFLAGS = -M
LINK = mpicxx
LINKFLAGS = -g -O -L../library -L${LAMMPS}/src -L${SPPARKS}/src
USRLIB = -lcouple -llammps_mpi -lspparks_mpi
SYSLIB =
ARCHIVE = ar
ARFLAGS = -rc
SIZE = size
# Files
EXE = lmpspk
SRC = $(wildcard *.cpp)
INC = $(wildcard *.h)
OBJ = $(SRC:.cpp=.o)
# Targets
lmpspk: $(OBJ)
$(LINK) $(LINKFLAGS) $(OBJ) $(USRLIB) $(SYSLIB) -o $(EXE)
$(SIZE) $(EXE)
clean:
rm $(EXE) *.o
# Compilation rules
%.o:%.cpp
$(CC) $(CCFLAGS) -c $<
%.d:%.cpp
$(CC) $(CCFLAGS) $(DEPFLAGS) $< > $@
# Individual dependencies
DEPENDS = $(OBJ:.o=.d)
include $(DEPENDS)