summaryrefslogtreecommitdiffstats
path: root/Modules/FindMPI.cmake
diff options
context:
space:
mode:
authorDave Partyka <dave.partyka@kitware.com>2009-10-27 17:10:01 (GMT)
committerDave Partyka <dave.partyka@kitware.com>2009-10-27 17:10:01 (GMT)
commit39e88bbe99ed608e8bfc73f8f7314640dd41e874 (patch)
tree956831f0340a57be96f73a5e972e5da71ba3faa9 /Modules/FindMPI.cmake
parentc283fe2d26f2b0a908ea544edaf87d91138cd77f (diff)
downloadCMake-39e88bbe99ed608e8bfc73f8f7314640dd41e874.zip
CMake-39e88bbe99ed608e8bfc73f8f7314640dd41e874.tar.gz
CMake-39e88bbe99ed608e8bfc73f8f7314640dd41e874.tar.bz2
COMP: need to add quotes when using get_filename_component otherwise it will try to process NOT FOUND rather than an empty string when MPIEXEC is not found.
Diffstat (limited to 'Modules/FindMPI.cmake')
-rw-r--r--Modules/FindMPI.cmake4
1 files changed, 2 insertions, 2 deletions
diff --git a/Modules/FindMPI.cmake b/Modules/FindMPI.cmake
index 18a8752..e945ec5 100644
--- a/Modules/FindMPI.cmake
+++ b/Modules/FindMPI.cmake
@@ -106,8 +106,8 @@ find_program(MPIEXEC
# call get_filename_component twice to remove mpiexec and the directory it exists in (typically bin).
# This gives us a fairly reliable base directory to search for /bin /lib and /include from.
-get_filename_component(MPI_BASE_DIR ${MPIEXEC} PATH)
-get_filename_component(MPI_BASE_DIR ${MPI_BASE_DIR} PATH)
+get_filename_component(MPI_BASE_DIR "${MPIEXEC}" PATH)
+get_filename_component(MPI_BASE_DIR "${MPI_BASE_DIR}" PATH)
# If there is an mpi compiler find it and interogate (farther below) it for the include
# and lib dirs otherwise we will continue to search from ${MPI_BASE_DIR}.