From 87737e62e0e6f1bb3c54ea0052f2fc19ded16c15 Mon Sep 17 00:00:00 2001 From: Brad King Date: Mon, 16 Jan 2012 09:03:08 -0500 Subject: [PATCH] FindMPI: Append MPI C++ library correctly in non-compiler case (#12874) When we have no MPI compiler wrapper and search explicitly for the MPI C++ library append it correctly to the list of libraries instead of using a space. Suggested-by: Mourad Boufarguine --- Modules/FindMPI.cmake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Modules/FindMPI.cmake b/Modules/FindMPI.cmake index 250d8a6b3c..1be4ccfa7f 100644 --- a/Modules/FindMPI.cmake +++ b/Modules/FindMPI.cmake @@ -413,7 +413,7 @@ function (interrogate_mpi_compiler lang try_libs) HINTS ${_MPI_BASE_DIR} ${_MPI_PREFIX_PATH} PATH_SUFFIXES lib) if (MPI_LIBRARIES_WORK AND MPI_LIB) - set(MPI_LIBRARIES_WORK "${MPI_LIBRARIES_WORK} ${MPI_LIB}") + list(APPEND MPI_LIBRARIES_WORK ${MPI_LIB}) endif() endif()