]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
The rest of the blas and lapack configuration
authormaier <maier@0785d39b-7218-0410-832d-ea1e28bc413d>
Sun, 16 Sep 2012 20:41:25 +0000 (20:41 +0000)
committermaier <maier@0785d39b-7218-0410-832d-ea1e28bc413d>
Sun, 16 Sep 2012 20:41:25 +0000 (20:41 +0000)
git-svn-id: https://svn.dealii.org/branches/branch_cmake@26424 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/CMakeLists.txt
deal.II/cmake-TODO
deal.II/contrib/cmake/configure/configure_blas.cmake
deal.II/contrib/cmake/configure/configure_lapack.cmake
deal.II/include/deal.II/base/config.h.in
deal.II/include/deal.II/base/config.h.in.old

index 9a6228be65e8bb6d4223637cc7a7225178b0ac60..ce8128fd40cef2164c3ad17c8829d243dac9a8dc 100644 (file)
@@ -97,23 +97,23 @@ OPTION(DEAL_II_ALLOW_CONTRIB
 
 OPTION(DEAL_II_WITH_BLAS
   "Build deal.II with support for BLAS."
-  OFF)
+  ON)
 
 OPTION(DEAL_II_WITH_FUNCTIONPARSER
   "Build deal.II with support for functionparser."
   OFF)
 OPTION(DEAL_II_FORCE_CONTRIB_FUNCTIONPARSER
   "Always use the bundled functionparser library instead of an external one."
-  ON)
+  OFF)
 
 
 OPTION(DEAL_II_WITH_LAPACK
   "Build deal.II with support for LAPACK."
-  OFF)
+  ON)
 
 OPTION(DEAL_II_WITH_METIS
   "Build deal.II with support for Metis."
-  ON)
+  OFF)
 
 OPTION(DEAL_II_WITH_MPI
   "Build deal.II with support for mpi."
@@ -121,7 +121,7 @@ OPTION(DEAL_II_WITH_MPI
 
 OPTION(DEAL_II_WITH_NETCDF
   "Build deal.II with support for netcdf."
-  ON)
+  OFF)
 
 OPTION(DEAL_II_WITH_TBB
   "Build deal.II with support for tbb. This will enable thread support in deal.II."
index 403d508ae7f123b512cf43e4263420d0ac7157bd..ea79ebcbed8bb0ed6dfc24aa89bf6b871e598e61 100644 (file)
@@ -1,10 +1,6 @@
 Next steps:
 
-* Add the CFLAGS and CXXFLAGS magic. (With an option to overwrite for distribution packaging.)
-
-* DEAL_II_DEPRECATED is not used at all...
-
-* Migrate the build of TBB to cmake.
+* Add the compiler dependent CFLAGS and CXXFLAGS magic.
 
 * Add Bug tests
 
index f204114988ef7677702e0876a51be189897632b0..8dca2da1b6ba299b55675e9b1c9877c563ded2f7 100644 (file)
@@ -2,9 +2,7 @@
 # Configuration for the blas library:
 #
 
-# TODO:
-# - include dir?
-# - unit checks and definitions.
+INCLUDE(CheckFunctionExists)
 
 MACRO(FIND_FEATURE_BLAS_EXTERNAL var)
 
@@ -27,6 +25,33 @@ MACRO(CONFIGURE_FEATURE_BLAS_EXTERNAL var)
     ${BLAS_LIBRARIES}
     )
 
+  LIST(APPEND CMAKE_REQUIRED_LIBRARIES "${BLAS_LIBRARIES}")
+  LIST(APPEND CMAKE_REQUIRED_FLAGS "${BLAS_LINKER_FLAGS}")
+
+  #
+  # TODO: Reduce to the really necessary parts.
+  #
+  CHECK_FUNCTION_EXISTS(daxpy_ HAVE_DAXPY_)
+  CHECK_FUNCTION_EXISTS(dgeevx_ HAVE_DGEEVX_)
+  CHECK_FUNCTION_EXISTS(dgeev_ AVE_DGEEV_)
+  CHECK_FUNCTION_EXISTS(dgelsd_ HAVE_DGELSD_)
+  CHECK_FUNCTION_EXISTS(dgemm_ AVE_DGEMM_)
+  CHECK_FUNCTION_EXISTS(dgemv_ AVE_DGEMV_)
+  CHECK_FUNCTION_EXISTS(dgeqrf_ HAVE_DGEQRF_)
+  CHECK_FUNCTION_EXISTS(dgesdd_ HAVE_DGESDD_)
+  CHECK_FUNCTION_EXISTS(dgesvd_ HAVE_DGESVD_)
+  CHECK_FUNCTION_EXISTS(dgetrf_ HAVE_DGETRF_)
+  CHECK_FUNCTION_EXISTS(dgetri_ HAVE_DGETRI_)
+  CHECK_FUNCTION_EXISTS(dgetrs_ HAVE_DGETRS_)
+  CHECK_FUNCTION_EXISTS(dorgqr_ HAVE_DORGQR_)
+  CHECK_FUNCTION_EXISTS(dormqr_ HAVE_DORMQR_)
+  CHECK_FUNCTION_EXISTS(dstev_ AVE_DSTEV_)
+  CHECK_FUNCTION_EXISTS(dsyevx_ HAVE_DSYEVX_)
+  CHECK_FUNCTION_EXISTS(dsygvx_ HAVE_DSYGVX_)
+
+  LIST(REMOVE_ITEM CMAKE_REQUIRED_LIBRARIES "${BLAS_LIBRARIES}")
+  LIST(REMOVE_ITEM CMAKE_REQUIRED_FLAGS "${BLAS_LINKER_FLAGS}")
+
   SET(HAVE_LIBBLAS TRUE)
 
   SET(${var} TRUE)
index 7d022a8477d5bbc102f49de2e8b1f98fac818f67..b7507df24de125384b6558ae843edeeeffce61b1 100644 (file)
@@ -2,10 +2,6 @@
 # Configuration for the lapack library:
 #
 
-# TODO:
-# - include dir?
-# - unit checks and definitions.
-
 MACRO(FIND_FEATURE_LAPACK_EXTERNAL var)
 
   FIND_PACKAGE(LAPACK)
@@ -27,6 +23,34 @@ MACRO(CONFIGURE_FEATURE_LAPACK_EXTERNAL var)
     ${LAPACK_LIBRARIES}
     )
 
+  LIST(APPEND CMAKE_REQUIRED_LIBRARIES "${LAPACK_LIBRARIES}")
+  LIST(APPEND CMAKE_REQUIRED_FLAGS "${LAPACK_LINKER_FLAGS}")
+
+  #
+  # TODO: Reduce to the really necessary parts.
+  #
+  CHECK_FUNCTION_EXISTS(saxpy_ HAVE_SAXPY_)
+  CHECK_FUNCTION_EXISTS(sgeevx_ HAVE_SGEEVX_)
+  CHECK_FUNCTION_EXISTS(sgeev_ HAVE_SGEEV_)
+  CHECK_FUNCTION_EXISTS(sgelsd_ HAVE_SGELSD_)
+  CHECK_FUNCTION_EXISTS(sgemm_ HAVE_SGEMM_)
+  CHECK_FUNCTION_EXISTS(sgemv_ HAVE_SGEMV_)
+  CHECK_FUNCTION_EXISTS(sgeqrf_ HAVE_SGEQRF_)
+  CHECK_FUNCTION_EXISTS(sgesdd_ HAVE_SGESDD_)
+  CHECK_FUNCTION_EXISTS(sgesvd_ HAVE_SGESVD_)
+  CHECK_FUNCTION_EXISTS(sgetrf_ HAVE_SGETRF_)
+  CHECK_FUNCTION_EXISTS(sgetri_ HAVE_SGETRI_)
+  CHECK_FUNCTION_EXISTS(sgetrs_ HAVE_SGETRS_)
+  CHECK_FUNCTION_EXISTS(sorgqr_ HAVE_SORGQR_)
+  CHECK_FUNCTION_EXISTS(sormqr_ HAVE_SORMQR_)
+  CHECK_FUNCTION_EXISTS(sstev_ HAVE_SSTEV_)
+  CHECK_FUNCTION_EXISTS(ssyevx_ HAVE_SSYEVX_)
+  CHECK_FUNCTION_EXISTS(ssygvx_ HAVE_SSYGVX_)
+  CHECK_FUNCTION_EXISTS(strtrs_ HAVE_STRTRS_)
+
+  LIST(REMOVE_ITEM CMAKE_REQUIRED_LIBRARIES "${LAPACK_LIBRARIES}")
+  LIST(REMOVE_ITEM CMAKE_REQUIRED_FLAGS "${LAPACK_LINKER_FLAGS}")
+
   SET(HAVE_LIBLAPACK TRUE)
 
   SET(${var} TRUE)
index 459ada2fff2a09a9c28b994d0ba0e77387fa18ae..7067af9d67d0484272adf8460c8faf24523a3031 100644 (file)
@@ -64,6 +64,9 @@
  * Configured in configure_blas.cmake: *
  ***************************************/
 
+/* Defined if deal.II was configured with BLAS support */
+#cmakedefine HAVE_LIBBLAS
+
 /* Define to 1 if you have the `daxpy_' function. */
 #cmakedefine HAVE_DAXPY_
 
 /* Defined if you have the `functionparser' library */
 #cmakedefine HAVE_FUNCTIONPARSER
 
+
+/*****************************************
+ * Configured in configure_lapack.cmake: *
+ *****************************************/
+
+/* Defined if deal.II was configured with LAPACK support */
+#cmakedefine HAVE_LIBLAPACK
+
+/* Define to 1 if you have the `sgeevx_' function. */
+#cmakedefine HAVE_SGEEVX_
+
+/* Define to 1 if you have the `sgeev_' function. */
+#cmakedefine HAVE_SGEEV_
+
+/* Define to 1 if you have the `sgelsd_' function. */
+#cmakedefine HAVE_SGELSD_
+
+/* Define to 1 if you have the `sgemm_' function. */
+#cmakedefine HAVE_SGEMM_
+
+/* Define to 1 if you have the `sgemv_' function. */
+#cmakedefine HAVE_SGEMV_
+
+/* Define to 1 if you have the `sgeqrf_' function. */
+#cmakedefine HAVE_SGEQRF_
+
+/* Define to 1 if you have the `sgesdd_' function. */
+#cmakedefine HAVE_SGESDD_
+
+/* Define to 1 if you have the `sgesvd_' function. */
+#cmakedefine HAVE_SGESVD_
+
+/* Define to 1 if you have the `sgetrf_' function. */
+#cmakedefine HAVE_SGETRF_
+
+/* Define to 1 if you have the `sgetri_' function. */
+#cmakedefine HAVE_SGETRI_
+
+/* Define to 1 if you have the `sgetrs_' function. */
+#cmakedefine HAVE_SGETRS_
+
+/* Define to 1 if you have the `sorgqr_' function. */
+#cmakedefine HAVE_SORGQR_
+
+/* Define to 1 if you have the `sormqr_' function. */
+#cmakedefine HAVE_SORMQR_
+
+/* Define to 1 if you have the `sstev_' function. */
+#cmakedefine HAVE_SSTEV_
+
+/* Define to 1 if you have the `ssyevx_' function. */
+#cmakedefine HAVE_SSYEVX_
+
+/* Define to 1 if you have the `ssygvx_' function. */
+#cmakedefine HAVE_SSYGVX_
+
+/* Defined if you have the `strtrs_' function. */
+#cmakedefine HAVE_STRTRS_
+
+
+
 /****************************************
  * Configured in configure_metis.cmake: *
  ****************************************/
 /* Defined if deal.II was configured with UMFPACK support */
 #cmakedefine HAVE_LIBUMFPACK
 
-/* Defined if deal.II was configured with BLAS support */
-#cmakedefine HAVE_LIBBLAS
-
-/* Defined if deal.II was configured with LAPACK support */
-#cmakedefine HAVE_LIBLAPACK
-
 
 /***************************************
  * Configured in configure_zlib.cmake: *
index fd7b04580efdd4af44a27dbbf6ff829e385f02a3..eb582e9c1d188c14f24e6a0e099ee674aa0b16f6 100644 (file)
 /* Define to 1 if you have the <Sacado.hpp> header file. */
 #cmakedefine HAVE_SACADO_HPP
 
-/* Define to 1 if you have the `saxpy_' function. */
-#cmakedefine HAVE_SAXPY_
-
-/* Define to 1 if you have the `sgeevx_' function. */
-#cmakedefine HAVE_SGEEVX_
-
-/* Define to 1 if you have the `sgeev_' function. */
-#cmakedefine HAVE_SGEEV_
-
-/* Define to 1 if you have the `sgelsd_' function. */
-#cmakedefine HAVE_SGELSD_
-
-/* Define to 1 if you have the `sgemm_' function. */
-#cmakedefine HAVE_SGEMM_
-
-/* Define to 1 if you have the `sgemv_' function. */
-#cmakedefine HAVE_SGEMV_
-
-/* Define to 1 if you have the `sgeqrf_' function. */
-#cmakedefine HAVE_SGEQRF_
-
-/* Define to 1 if you have the `sgesdd_' function. */
-#cmakedefine HAVE_SGESDD_
-
-/* Define to 1 if you have the `sgesvd_' function. */
-#cmakedefine HAVE_SGESVD_
-
-/* Define to 1 if you have the `sgetrf_' function. */
-#cmakedefine HAVE_SGETRF_
-
-/* Define to 1 if you have the `sgetri_' function. */
-#cmakedefine HAVE_SGETRI_
-
-/* Define to 1 if you have the `sgetrs_' function. */
-#cmakedefine HAVE_SGETRS_
-
-/* Define to 1 if you have the `sorgqr_' function. */
-#cmakedefine HAVE_SORGQR_
-
-/* Define to 1 if you have the `sormqr_' function. */
-#cmakedefine HAVE_SORMQR_
-
-/* Define to 1 if you have the `sstev_' function. */
-#cmakedefine HAVE_SSTEV_
-
-/* Define to 1 if you have the `ssyevx_' function. */
-#cmakedefine HAVE_SSYEVX_
-
-/* Define to 1 if you have the `ssygvx_' function. */
-#cmakedefine HAVE_SSYGVX_
-
-/* Define to 1 if you have the `ssygv_' function. */
-#cmakedefine HAVE_SSYGV_
-
 /* Define to 1 if you have the <Teuchos_ParameterList.hpp> header file. */
 #cmakedefine HAVE_TEUCHOS_PARAMETERLIST_HPP
 
 #  pragma warning( disable : 4789 ) // destination of memory copy is too small
 #  pragma warning( disable : 4808 ) // case 'value' is not a valid value for switch condition of type 'bool
 #endif // DEAL_II_MSVC
-
-
-/* Defined if you have the `strtrs_' function. */
-#cmakedefine HAVE_STRTRS_ /* TODO */

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.