Commit 5655ac46 authored by David Cole's avatar David Cole
Browse files

Add MPICH2 and Microsoft HPC paths, add paths to find mpiexec. Now it works...

Add MPICH2 and Microsoft HPC paths, add paths to find mpiexec. Now it works better automatically on Windows. Thanks to Dave Partyka for developing the patch.
parent cdb96653
......@@ -58,8 +58,14 @@ find_program(MPI_COMPILER
DOC "MPI compiler. Used only to detect MPI compilation flags.")
file(TO_CMAKE_PATH "$ENV{ProgramFiles}" ProgramFiles)
NAMES mpiexec mpirun lamexec
PATHS /usr/bin /usr/local/bin /usr/local/mpi/bin
"$ENV{SystemDrive}/Program Files/MPICH/SDK/Bin"
"$ENV{SystemDrive}/Program Files/Microsoft Compute Cluster Pack/Bin"
"$ENV{SystemDrive}/Program Files/Microsoft HPC Pack 2008 SDK/Bin"
DOC "Executable for running MPI programs.")
set(MPIEXEC_NUMPROC_FLAG "-np" CACHE STRING "Flag used by MPI to specify the number of processes for MPIEXEC; the next option will be the number of processes.")
......@@ -247,34 +253,36 @@ else (MPI_COMPILE_CMDLINE)
"C:/Program Files/MPICH/SDK/Include"
"$ENV{SystemDrive}/Program Files/MPICH2/include"
"$ENV{SystemDrive}/Program Files/MPICH/SDK/Include"
"$ENV{SystemDrive}/Program Files/Microsoft Compute Cluster Pack/Include"
"$ENV{SystemDrive}/Program Files/Microsoft HPC Pack 2008 SDK/Include"
# Decide between 32-bit and 64-bit libraries for Microsoft's MPI
if (CMAKE_CL_64)
set(MS_MPI_ARCH_DIR amd64)
else (CMAKE_CL_64)
set(MS_MPI_ARCH_DIR i386)
endif (CMAKE_CL_64)
NAMES mpi mpich msmpi
PATHS /usr/lib /usr/local/lib /usr/local/mpi/lib
"C:/Program Files/MPICH/SDK/Lib"
"$ENV{SystemDrive}/Program Files/MPICH/SDK/Lib"
"$ENV{SystemDrive}/Program Files/Microsoft Compute Cluster Pack/Lib/${MS_MPI_ARCH_DIR}"
"$ENV{SystemDrive}/Program Files/Microsoft HPC Pack 2008 SDK/Lib/${MS_MPI_ARCH_DIR}"
NAMES mpich2
"$ENV{SystemDrive}/Program Files/MPICH2/Lib")
NAMES mpi++
PATHS /usr/lib /usr/local/lib /usr/local/mpi/lib
"C:/Program Files/MPICH/SDK/Lib"
"$ENV{SystemDrive}/Program Files/MPICH/SDK/Lib"
DOC "Extra MPI libraries to link against.")
set(MPI_COMPILE_FLAGS "" CACHE STRING "MPI compilation flags")
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