ctest works with lam mpi
[unres.git] / source / wham / src-M / CMakeLists.txt
index 1a29d77..195e5df 100644 (file)
@@ -244,6 +244,15 @@ install(TARGETS UNRES_WHAM_M_BIN DESTINATION ${CMAKE_INSTALL_PREFIX}/wham)
 # TESTS 
 #=========================================
 
+#  MESSAGE (STATUS "${MPI_Fortran_LIBRARIES}")
+  if ("${MPI_Fortran_LIBRARIES}"  MATCHES "lam")
+     MESSAGE (STATUS "LAM MPI library detected")
+     set (boot_lam "-boot")
+  else()
+     set (boot_lam "")
+  endif()
+
+
 FILE(WRITE ${CMAKE_CURRENT_BINARY_DIR}/scripts/wham_mpi_E0LL2Y.sh
 "#!/bin/sh
 export POT=GB
@@ -270,7 +279,7 @@ export SIDEP=$DD/contact.3.parm
 export SCRATCHDIR=.
 #-----------------------------------------------------------------------------
 echo CTEST_FULL_OUTPUT
-mpiexec -np $2 $WHAM_BIN 
+mpiexec ${boot_lam} -np $2 $WHAM_BIN 
 ./wham_check.sh $1 
 ")