-
Notifications
You must be signed in to change notification settings - Fork 2
/
win_intel_msmpi.cmake
33 lines (30 loc) · 1.88 KB
/
win_intel_msmpi.cmake
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
# Set the PDAF library name, it can be pdaf-var or pdaf-d
set(PDAF_NAME "pdaf-var")
# set MPI library information
set(MPI_NAME "msmpi;msmpifec")
set(MPI_Fortran_INCLUDE_PATH
"C:/Program Files (x86)/Microsoft SDKs/MPI/Include"
CACHE STRING "path to the MPI Fortran mpi.h include directory")
set(MPI_Fortran_MODULE_INCLUDE_PATH
"C:/Program Files (x86)/Microsoft SDKs/MPI/Include/x64"
CACHE STRING "path to the include directory to compile MPI Fortran module")
set(MPI_Fortran_MODULE_DIR
"C:/Users/cymji/Desktop/pyPDAF/PDAF_V2.2.1/mpi_include"
CACHE STRING "path to the installed module directory of MPI_Fortran")
# We have to compile MPI-MPI mod file ourselves in Windows
set(MPI_Fortran_MODULE_SRC_FILE "C:/Program Files (x86)/Microsoft SDKs/MPI/Include/mpi.f90"
CACHE STRING "path to the MPI Fortran module source file" )
# We have to compile MPI-MPI mod file ourselves in Windows
set(MPI_Fortran_LINK_DIR "C:/Program Files (x86)/Microsoft SDKs/MPI/Lib/x64"
CACHE STRING "path to the MPI Fortran libraries" )
# This overrides any language flags and must be given before add_library
set_source_files_properties(${MPI_Fortran_MODULE_SRC_FILE} PROPERTIES COMPILE_FLAGS "/O2 /Qdiag-disable:10448 /Qdiag-disable:10423")
# ideally, we should provide compiler options based on target or source files,
# but this will force us to use multiple config files or encode it in the CMakelist.txt file
set(CMAKE_Fortran_FLAGS_RELEASE "/O2 /4R8 /Qdiag-disable:10448 /Qdiag-disable:10423" CACHE STRING "RELEASE FLAGS" FORCE)
# Set compiler flags for Debug configurations
set(CMAKE_Fortran_FLAGS_DEBUG "/Od /debug:full /traceback /check:all /Qtrapuv /4R8 /Qdiag-disable:10448 /Qdiag-disable:10423" CACHE STRING "DEBUG FLAGS" FORCE)
# set BLAS information
set(BLAS_NAME "mkl_core;mkl_intel_lp64;mkl_sequential")
set(BLAS_INCLUDE_PATH "")
set(BLAS_LIB_PATH "C:/Program Files (x86)/Intel/oneAPI/mkl/2024.2/lib")