|
@@ -7,50 +7,52 @@ set(EMSCHUR3D_VERSION_NOQUOTES "${EMSCHUR3D_VERSION_MAJOR}.${EMSCHUR3D_VERSION_M
|
7
|
7
|
|
8
|
8
|
option ( LEMMA_MODULE_EMSCHUR3D TRUE )
|
9
|
9
|
|
10
|
|
-find_package( SuperLU )
|
11
|
|
-if (SUPERLU_FOUND)
|
12
|
|
- message( STATUS "SuperLU was found" )
|
13
|
|
- add_compile_options(-DHAVE_SUPERLU)
|
14
|
|
- INCLUDE_DIRECTORIES(${SUPERLU_INCLUDES})
|
|
10
|
+option ( LEMMA_USE_SUPERLU FALSE)
|
|
11
|
+if (LEMMA_USE_SUPERLU)
|
|
12
|
+ find_package( SuperLU )
|
|
13
|
+ if (SUPERLU_FOUND)
|
|
14
|
+ message( STATUS "SuperLU was found" )
|
|
15
|
+ add_compile_options(-DHAVE_SUPERLU)
|
|
16
|
+ INCLUDE_DIRECTORIES(${SUPERLU_INCLUDES})
|
|
17
|
+ endif()
|
15
|
18
|
endif()
|
16
|
19
|
|
17
|
20
|
#find_package( PaSTiX )
|
18
|
|
-find_package( PaSTiX COMPONENTS METIS SEQ )
|
19
|
|
-
|
20
|
|
-find_path(PASTIX_pastix_nompi.h_INCLUDE_DIRS
|
21
|
|
- #NAMES pastix/nompi.h
|
22
|
|
- NAMES pastix_nompi.h
|
23
|
|
- HINTS ${PASTIX_INCLUDE_DIRS}
|
24
|
|
-)
|
25
|
|
-if (NOT PASTIX_pastix_nompi.h_INCLUDE_DIRS)
|
26
|
|
- message(STATUS "A version of Pastix has been found but pastix_nompi.h does not exist in the include directory."
|
27
|
|
- " Because Eigen tests require a version without MPI, we disable the Pastix backend.")
|
28
|
|
-endif()
|
29
|
|
-if(PASTIX_FOUND AND PASTIX_pastix_nompi.h_INCLUDE_DIRS)
|
30
|
|
- add_definitions("-DEIGEN_PASTIX_SUPPORT")
|
31
|
|
- include_directories(${PASTIX_INCLUDE_DIRS_DEP})
|
32
|
|
- if(SCOTCH_FOUND)
|
33
|
|
- include_directories(${SCOTCH_INCLUDE_DIRS})
|
34
|
|
- set(PASTIX_LIBRARIES ${PASTIX_LIBRARIES} ${SCOTCH_LIBRARIES})
|
35
|
|
- elseif(METIS_FOUND)
|
36
|
|
- include_directories(${METIS_INCLUDE_DIRS})
|
37
|
|
- set(PASTIX_LIBRARIES ${PASTIX_LIBRARIES} ${METIS_LIBRARIES})
|
38
|
|
- else(SCOTCH_FOUND)
|
|
21
|
+#find_package( PaSTiX COMPONENTS METIS SEQ )
|
|
22
|
+
|
|
23
|
+#find_path(PASTIX_pastix_nompi.h_INCLUDE_DIRS
|
|
24
|
+# #NAMES pastix/nompi.h
|
|
25
|
+# NAMES pastix_nompi.h
|
|
26
|
+# HINTS ${PASTIX_INCLUDE_DIRS}
|
|
27
|
+#)
|
|
28
|
+#if (NOT PASTIX_pastix_nompi.h_INCLUDE_DIRS)
|
|
29
|
+# message(STATUS "A version of Pastix has been found but pastix_nompi.h does not exist in the include directory."
|
|
30
|
+# " Because Eigen tests require a version without MPI, we disable the Pastix backend.")
|
|
31
|
+#endif()
|
|
32
|
+#if(PASTIX_FOUND AND PASTIX_pastix_nompi.h_INCLUDE_DIRS)
|
|
33
|
+# add_definitions("-DEIGEN_PASTIX_SUPPORT")
|
|
34
|
+# include_directories(${PASTIX_INCLUDE_DIRS_DEP})
|
|
35
|
+# if(SCOTCH_FOUND)
|
|
36
|
+# include_directories(${SCOTCH_INCLUDE_DIRS})
|
|
37
|
+# set(PASTIX_LIBRARIES ${PASTIX_LIBRARIES} ${SCOTCH_LIBRARIES})
|
|
38
|
+# elseif(METIS_FOUND)
|
|
39
|
+# include_directories(${METIS_INCLUDE_DIRS})
|
|
40
|
+# set(PASTIX_LIBRARIES ${PASTIX_LIBRARIES} ${METIS_LIBRARIES})
|
|
41
|
+# else(SCOTCH_FOUND)
|
39
|
42
|
# ei_add_property(EIGEN_MISSING_BACKENDS "PaStiX, ")
|
40
|
|
- endif(SCOTCH_FOUND)
|
41
|
|
- set(SPARSE_LIBS ${SPARSE_LIBS} ${PASTIX_LIBRARIES_DEP} ${ORDERING_LIBRARIES})
|
42
|
|
- set(PASTIX_ALL_LIBS ${PASTIX_LIBRARIES_DEP})
|
|
43
|
+# endif(SCOTCH_FOUND)
|
|
44
|
+# set(SPARSE_LIBS ${SPARSE_LIBS} ${PASTIX_LIBRARIES_DEP} ${ORDERING_LIBRARIES})
|
|
45
|
+# set(PASTIX_ALL_LIBS ${PASTIX_LIBRARIES_DEP})
|
43
|
46
|
# ei_add_property(EIGEN_TESTED_BACKENDS "PaStiX, ")
|
44
|
|
-else()
|
|
47
|
+#else()
|
45
|
48
|
# ei_add_property(EIGEN_MISSING_BACKENDS "PaStiX, ")
|
46
|
|
-endif()
|
47
|
|
-
|
48
|
|
-if ( PASTIX_FOUND )
|
49
|
|
- message( STATUS "PaSTiX was found" )
|
50
|
|
- add_compile_options(-DHAVE_PASTIX)
|
51
|
|
- INCLUDE_DIRECTORIES(${PASTIX_INCLUDES})
|
52
|
|
-endif()
|
|
49
|
+#endif()
|
53
|
50
|
|
|
51
|
+#if ( PASTIX_FOUND )
|
|
52
|
+# message( STATUS "PaSTiX was found" )
|
|
53
|
+# add_compile_options(-DHAVE_PASTIX)
|
|
54
|
+# INCLUDE_DIRECTORIES(${PASTIX_INCLUDES})
|
|
55
|
+#endif()
|
54
|
56
|
|
55
|
57
|
|
56
|
58
|
find_package( Umfpack )
|
|
@@ -87,7 +89,18 @@ if ( LEMMA_VTK6_SUPPORT OR LEMMA_VTK7_SUPPORT OR LEMMA_VTK8_SUPPORT AND LEMMA_MO
|
87
|
89
|
#set (MKLLINK "-L$MKLROOT/lib/intel64 -lmkl_intel_lp64 -lmkl_sequential -lmkl_core -lpthread -Wl,-rpath=$MKLROOT/lib/intel64")
|
88
|
90
|
# OpenMP R3
|
89
|
91
|
set (MKLLINK "-L$MKLROOT/lib/intel64 -Wl,-rpath=$MKLROOT/lib/intel64 -lmkl_intel_lp64 -lmkl_intel_thread -lmkl_core -liomp5 -lpthread")
|
|
92
|
+ add_compile_options( -DEIGEN_USE_MKL_ALL )
|
90
|
93
|
target_link_libraries(emschur3d "lemmacore" ${MKLLINK})
|
|
94
|
+ else()
|
|
95
|
+ find_library( PARDISO600
|
|
96
|
+ NAMES pardiso600 libpardiso600.so libpardiso600-GNU800-X86-64.so
|
|
97
|
+ HINTS $(CMAKE_INSTALL_PREFIX)
|
|
98
|
+ PATH_SUFFIXES lib
|
|
99
|
+ )
|
|
100
|
+ if (PARDISO600)
|
|
101
|
+ add_compile_options(-DHAVE_PARDISO -mkl) # -mkl ONLY WORKS WITH INTEL, but academic pardiso doesn't include headers...
|
|
102
|
+ target_link_libraries( emschur3d "lemmacore" )
|
|
103
|
+ endif()
|
91
|
104
|
endif()
|
92
|
105
|
|
93
|
106
|
# Linking
|