forked from cp2k/cp2k
-
Notifications
You must be signed in to change notification settings - Fork 0
/
CRAY-XC40_gnu-mkl.psmp
92 lines (75 loc) · 2.76 KB
/
CRAY-XC40_gnu-mkl.psmp
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
# Tested with: GFortran 8.3.0, MPICH 3.2.1, MKL 19.1.1.217, Libint 2.6.0,
# LIBXC 5.1.5, LIBVORI 210412, ELPA 2020.11.001, PLUMED 2.6.2,
# SPGLIB 1.16.0
# Author: Matthias Krack ([email protected], PSI, July 2021)
# Cray XC40 (Piz Daint, CSCS, multi-core partition)
# Program environments:
# module add daint-mc
# module rm PrgEnv-cray
# module add PrgEnv-gnu
# module rm gcc/10.1.0
# module add gcc/8.3.0
# module rm cray-libsci/20.09.1
GNU_PATH = /store/psi/psi01/mkrack/daint/mc/gnu/8.3.0
MPI_PATH = $(GNU_PATH)/mpich
MKLROOT = /opt/intel/compilers_and_libraries_2020.1.217/linux/mkl
MKL_INC = $(MKLROOT)/include
MKL_LIB = $(MKLROOT)/lib/intel64
CC = cc
FC = ftn
LD = ftn
AR = ar -r
include $(MPI_PATH)/plumed2/2.6.2/lib/plumed/src/lib/Plumed.inc.static
ELPA_VER = 2020.11.001
ELPA_INC = $(MPI_PATH)/elpa/$(ELPA_VER)/include/elpa-$(ELPA_VER)
ELPA_LIB = $(MPI_PATH)/elpa/$(ELPA_VER)/lib
LIBINT_INC = $(GNU_PATH)/libint/2.6.0-lmax-6/include
LIBINT_LIB = $(GNU_PATH)/libint/2.6.0-lmax-6/lib
LIBVORI_LIB = $(GNU_PATH)/libvori/210412/lib
LIBXC_INC = $(GNU_PATH)/libxc/5.1.5/include
LIBXC_LIB = $(GNU_PATH)/libxc/5.1.5/lib
SPGLIB_INC = $(GNU_PATH)/spglib/1.16.0/include
SPGLIB_LIB = $(GNU_PATH)/spglib/1.16.0/lib
# cc, CC, and ftn include already the proper -march flag
CFLAGS = -O3 -fopenmp -fopenmp-simd -ftree-vectorize -funroll-loops -g
DFLAGS = -D__ELPA
DFLAGS += -D__FFTW3
DFLAGS += -D__LIBINT
DFLAGS += -D__LIBVORI
DFLAGS += -D__LIBXC
DFLAGS += -D__MAX_CONTR=4
DFLAGS += -D__MKL
DFLAGS += -D__MPI_VERSION=3
DFLAGS += -D__PLUMED2
DFLAGS += -D__SPGLIB
DFLAGS += -D__parallel
DFLAGS += -D__SCALAPACK
#DFLAGS += -D__CHECK_DIAG
CFLAGS += $(DFLAGS)
CFLAGS += -I$(ELPA_INC)/elpa -I$(ELPA_INC)/modules
CFLAGS += -I$(LIBINT_INC)
CFLAGS += -I$(LIBXC_INC)
CFLAGS += -I$(MKL_INC) -I$(MKL_INC)/fftw
CFLAGS += -I$(SPGLIB_INC)
FCFLAGS = $(CFLAGS)
FCFLAGS += -fbacktrace
FCFLAGS += -ffree-form
FCFLAGS += -ffree-line-length-none
FCFLAGS += -fno-omit-frame-pointer
FCFLAGS += -std=f2008
LDFLAGS = $(FCFLAGS) -static
LIBS = $(PLUMED_DEPENDENCIES) -lz
LIBS += $(ELPA_LIB)/libelpa.a
LIBS += $(LIBVORI_LIB)/libvori.a
LIBS += $(LIBXC_LIB)/libxcf03.a
LIBS += $(LIBXC_LIB)/libxc.a
LIBS += $(LIBINT_LIB)/libint2.a
LIBS += $(SPGLIB_LIB)/libsymspg.a
LIBS += $(MKL_LIB)/libmkl_scalapack_lp64.a
LIBS += -Wl,--start-group
LIBS += $(MKL_LIB)/libmkl_gf_lp64.a
LIBS += $(MKL_LIB)/libmkl_sequential.a
LIBS += $(MKL_LIB)/libmkl_core.a
LIBS += $(MKL_LIB)/libmkl_blacs_intelmpi_lp64.a
LIBS += -Wl,--end-group
LIBS += -ldl -lstdc++