]> https://gitweb.dealii.org/ - dealii.git/commitdiff
CMake: Let FindMETIS search for libparmetis as well
authorMatthias Maier <tamiko@kyomu.43-1.org>
Thu, 11 Jul 2013 17:44:31 +0000 (17:44 +0000)
committerMatthias Maier <tamiko@kyomu.43-1.org>
Thu, 11 Jul 2013 17:44:31 +0000 (17:44 +0000)
git-svn-id: https://svn.dealii.org/trunk@29976 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/cmake/modules/FindMETIS.cmake

index c6a5949ea585816e1a991a7d6e7821083b889035..634d82d462fa947844f29d87f4f3ef31765d4582 100644 (file)
@@ -49,13 +49,28 @@ FIND_LIBRARY(METIS_LIBRARY
     build/${CMAKE_CXX_PLATFORM_ID}-${CMAKE_SYSTEM_PROCESSOR}/libmetis
   )
 
+FIND_LIBRARY(PARMETIS_LIBRARY
+  NAMES parmetis
+  HINTS
+    ${METIS_DIR}
+  PATH_SUFFIXES
+    lib${LIB_SUFFIX} lib64 lib
+    # This is a hint, isn't it?
+    build/${CMAKE_CXX_PLATFORM_ID}-${CMAKE_SYSTEM_PROCESSOR}/libmetis
+  )
+
 FIND_PACKAGE_HANDLE_STANDARD_ARGS(METIS DEFAULT_MSG
   METIS_LIBRARY
   METIS_INCLUDE_DIR
   )
 
 IF(METIS_FOUND)
-  SET(METIS_LIBRARIES
+
+  IF(NOT PARMETIS_LIBRARY MATCHES "-NOTFOUND")
+    SET(METIS_LIBRARIES ${PARMETIS_LIBRARY})
+  ENDIF()
+
+  LIST(APPEND METIS_LIBRARIES
     ${METIS_LIBRARY}
     ${MPI_C_LIBRARIES} # for good measure
     )

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.