Merge release-4-6 into master
[alexxy/gromacs.git] / cmake / gmxManageMPI.cmake
index 36defad2f52a8c919f629596f61aa5dde0d4006e..279397d74a73233e6d25a2d4292cc91f2eba60a5 100644 (file)
@@ -109,6 +109,14 @@ if(GMX_MPI)
     endif()
     unset(MPINAME_BIN CACHE)
 
+    # Using find_file() runs the CMake standard module
+    # GetPrerequisites.cmake, which adds the file_cmd
+    # variable to the top-level CMake namespace. This is
+    # fixed in CMake 2.8.10. Meanwhile, clean up for it.
+    if(CMAKE_VERSION VERSION_LESS "2.8.10")
+        mark_as_advanced(file_cmd)
+    endif()
+
   else(MPI_FOUND)
     if (CMAKE_VERSION VERSION_LESS "2.8.5")
       message(FATAL_ERROR