aboutsummaryrefslogtreecommitdiffhomepage
path: root/cmake
diff options
context:
space:
mode:
authorGravatar Desire NUENTSA <desire.nuentsa_wakam@inria.fr>2012-03-08 18:59:08 +0100
committerGravatar Desire NUENTSA <desire.nuentsa_wakam@inria.fr>2012-03-08 18:59:08 +0100
commit0d8466d3178f8dc42d2bf7c55667468b94680864 (patch)
tree8f5e9a29c9395e0a81da4ad2f7a881055ee93b11 /cmake
parent37d2efd4f6a5efe5d0a15c6386aef8225ba3f27c (diff)
Adding an interface to PaStiX, the multithreaded and distributed linear solver
Diffstat (limited to 'cmake')
-rw-r--r--cmake/FindMetis.cmake24
-rw-r--r--cmake/FindPastix.cmake25
-rw-r--r--cmake/FindScotch.cmake24
3 files changed, 73 insertions, 0 deletions
diff --git a/cmake/FindMetis.cmake b/cmake/FindMetis.cmake
new file mode 100644
index 000000000..e4d6ef258
--- /dev/null
+++ b/cmake/FindMetis.cmake
@@ -0,0 +1,24 @@
+# Pastix requires METIS or METIS (partitioning and reordering tools)
+
+if (METIS_INCLUDES AND METIS_LIBRARIES)
+ set(METIS_FIND_QUIETLY TRUE)
+endif (METIS_INCLUDES AND METIS_LIBRARIES)
+
+find_path(METIS_INCLUDES
+ NAMES
+ metis.h
+ PATHS
+ $ENV{METISDIR}
+ ${INCLUDE_INSTALL_DIR}
+ PATH_SUFFIXES
+ metis
+)
+
+
+find_library(METIS_LIBRARIES metis PATHS $ENV{METISDIR} ${LIB_INSTALL_DIR})
+
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(METIS DEFAULT_MSG
+ METIS_INCLUDES METIS_LIBRARIES)
+
+mark_as_advanced(METIS_INCLUDES METIS_LIBRARIES)
diff --git a/cmake/FindPastix.cmake b/cmake/FindPastix.cmake
new file mode 100644
index 000000000..e2e6c810d
--- /dev/null
+++ b/cmake/FindPastix.cmake
@@ -0,0 +1,25 @@
+# Pastix lib requires linking to a blas library.
+# It is up to the user of this module to find a BLAS and link to it.
+# Pastix requires SCOTCH or METIS (partitioning and reordering tools) as well
+
+if (PASTIX_INCLUDES AND PASTIX_LIBRARIES)
+ set(PASTIX_FIND_QUIETLY TRUE)
+endif (PASTIX_INCLUDES AND PASTIX_LIBRARIES)
+
+find_path(PASTIX_INCLUDES
+ NAMES
+ pastix_nompi.h
+ PATHS
+ $ENV{PASTIXDIR}
+ ${INCLUDE_INSTALL_DIR}
+)
+
+find_library(PASTIX_LIBRARIES pastix PATHS $ENV{PASTIXDIR} ${LIB_INSTALL_DIR})
+
+
+
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(PASTIX DEFAULT_MSG
+ PASTIX_INCLUDES PASTIX_LIBRARIES)
+
+mark_as_advanced(PASTIX_INCLUDES PASTIX_LIBRARIES)
diff --git a/cmake/FindScotch.cmake b/cmake/FindScotch.cmake
new file mode 100644
index 000000000..530340b16
--- /dev/null
+++ b/cmake/FindScotch.cmake
@@ -0,0 +1,24 @@
+# Pastix requires SCOTCH or METIS (partitioning and reordering tools)
+
+if (SCOTCH_INCLUDES AND SCOTCH_LIBRARIES)
+ set(SCOTCH_FIND_QUIETLY TRUE)
+endif (SCOTCH_INCLUDES AND SCOTCH_LIBRARIES)
+
+find_path(SCOTCH_INCLUDES
+ NAMES
+ scotch.h
+ PATHS
+ $ENV{SCOTCHDIR}
+ ${INCLUDE_INSTALL_DIR}
+ PATH_SUFFIXES
+ scotch
+)
+
+
+find_library(SCOTCH_LIBRARIES scotch PATHS $ENV{SCOTCHDIR} ${LIB_INSTALL_DIR})
+
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(SCOTCH DEFAULT_MSG
+ SCOTCH_INCLUDES SCOTCH_LIBRARIES)
+
+mark_as_advanced(SCOTCH_INCLUDES SCOTCH_LIBRARIES)