forked from mnottoli/ddPCM
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathMakefile
38 lines (34 loc) · 945 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#
# Makefile for ddCOSMO
#
#RunF77 = ifort
#FFLAGS = -O3 -xHost -qopenmp
RunF77 = gfortran
#FFLAGS = -O3 -march=native -llapack -lblas
FFLAGS = -O3 -march=native ${MKLROOT}/lib/libmkl_intel_lp64.a \
${MKLROOT}/lib/libmkl_sequential.a ${MKLROOT}/lib/libmkl_core.a \
-lpthread -lm -ldl -ftree-vectorize -finline-functions
#RunF77 = pgfortran
#FFLAGS = -O3 -mp
MODS = ddcosmo.o pcm_fmm.o ddpcm_lib.o
OBJS = ${MODS} mkrhs.o llgnew.o forces_dd.o efld.o\
matvec.o cosmo.o jacobi_diis.o
#
all: main.exe main_fmm.exe
main.exe: $(MODS) $(OBJS)
$(RunF77) $(FFLAGS) main.f90 -o main.exe $(OBJS)
main_fmm.exe: $(MODS) $(OBJS)
$(RunF77) $(FFLAGS) main_fmm.f90 -o main_fmm.exe $(OBJS)
#
%.o: %.f
$(RunF77) $(FFLAGS) -c $*.f
%.o: %.f90
$(RunF77) $(FFLAGS) -c $*.f90
#
clean:
rm -fr $(OBJS) *.exe *.mod *.so
#
test_pcm_fmm: pcm_fmm.f90 llgnew.o
f2py -m test_pcm_fmm -c pcm_fmm.f90 llgnew.o --opt="${FFLAGS}"
#
.PHONY: all clean pcm_fmm