ctest works with lam mpi
[unres.git] / source / cluster / wham / src / CMakeLists.txt
index 8669d33..49068c4 100644 (file)
@@ -176,6 +176,15 @@ install(TARGETS UNRES_CLUSTER_WHAM_BIN DESTINATION ${CMAKE_INSTALL_PREFIX}/clust
 # 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/cluster_wham_mpi_E0LL2Y.sh
 "#!/bin/sh
 export POT=GB
@@ -207,7 +216,7 @@ export SIDEP=$DD/contact.3.parm
 export SCRATCHDIR=.
 #-----------------------------------------------------------------------------
 echo CTEST_FULL_OUTPUT
-mpiexec -np $2 $CLUSTER_WHAM_BIN 
+mpiexec ${boot_lam} -np $2 $CLUSTER_WHAM_BIN 
 ./cluster_wham_check.sh $1 
 ")