This commit is contained in:
Radovan Bast
2015-06-04 13:47:55 +02:00
parent 4755abbd31
commit 6c6f779b2d
16 changed files with 4 additions and 4 deletions

12
modules/mpi.cmake Normal file
View File

@ -0,0 +1,12 @@
option(ENABLE_MPI "Enable MPI parallelization" OFF)
# on Cray configure with -D MPI_FOUND=1
if(ENABLE_MPI AND NOT MPI_FOUND)
find_package(MPI)
if(MPI_FOUND)
set(CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} ${MPI_COMPILE_FLAGS}")
include_directories(${MPI_INCLUDE_PATH})
else()
message(FATAL_ERROR "-- You asked for MPI, but CMake could not find any MPI installation, check $PATH")
endif()
endif()