unset MPI detection leftover cache variables
[alexxy/gromacs.git] / cmake / gmxManageMPI.cmake
index 49868cb4672d24e29bec5993d41f6c039d77ddaa..c025192465f43c60edc2e57bce696b8d6bb0c6a6 100644 (file)
@@ -74,7 +74,7 @@ if(GMX_MPI)
         unset(OPENMPI_EXEC_RETURN)
       endif()
     endif()
-    unset(MPI_INFO_BIN)
+    unset(MPI_INFO_BIN CACHE)
 
     # Execute the mpiname binary with the full path of the compiler wrapper
     # found, otherwise we run the risk of false positives.
@@ -107,7 +107,7 @@ if(GMX_MPI)
        unset(MVAPICH2_EXEC_RETURN)
       endif()
     endif()
-    unset(MPINAME_BIN)
+    unset(MPINAME_BIN CACHE)
 
   else(MPI_FOUND)
     if (CMAKE_VERSION VERSION_LESS "2.8.5")