Commit 9f2b6f4d authored by Marcus D. Hanwell's avatar Marcus D. Hanwell Committed by Chris Harris
Browse files

Test the variable MPIEXEC (not its value)

Also, made the else a fatal error as nothing will work as expected if
the Find MPI call failed.

Change-Id: I9e524beb208bb3928656c85fcefc2442f1fd7a43
parent 8dd98b6a
......@@ -14,7 +14,7 @@ include_directories(${MPI_INCLUDE_PATH})
# ${VTK_MPIRUN_EXE} ${VTK_MPI_PRENUMPROC_FLAGS} ${VTK_MPI_NUMPROC_FLAG} 2 ${VTK_MPI_PREFLAGS} executable ${VTK_MPI_POSTFLAGS}
#
# Use MPI variables defined in the CMake (2.8) FindMPI module.
if(${MPIEXEC})
if(MPIEXEC)
set(VTK_MPIRUN_EXE CACHE FILEPATH ${MPIEXEC} FORCE)
set(VTK_MPI_PRENUMPROC_FLAGS ${MPIEXEC_PREFLAGS} CACHE STRING
"These flags will be directly before the number of processess flag (see ${CMAKE_CURRENT_SOURCE_DIR}/CMakeLists.txt for more info.)" FORCE)
......@@ -32,7 +32,7 @@ if(${MPIEXEC})
set(VTK_MPI_MAX_NUMPROCS ${MPIEXEC_MAX_NUMPROCS} CACHE STRING
"Maximum number of processors available to run parallel applications. (see ${CMAKE_CURRENT_SOURCE_DIR}/CMakeLists.txt for more info.)" FORCE)
else()
message(WARNING "MPIEXEC was empty.")
message(FATAL_ERROR "MPIEXEC was empty.")
endif()
mark_as_advanced(
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment