From 867bedf737f1295c92de2eeb9bb9acca15d1eb94 Mon Sep 17 00:00:00 2001 From: Bruno Turcksin Date: Tue, 14 Jul 2015 16:51:42 -0500 Subject: [PATCH] Add support for MKL. --- deal.II/packages/dealii.package | 16 +++++++++++++ project-deal.II.cfg | 42 +++++++++++++++++++++++++-------- 2 files changed, 48 insertions(+), 10 deletions(-) diff --git a/deal.II/packages/dealii.package b/deal.II/packages/dealii.package index 164305a..01fa582 100644 --- a/deal.II/packages/dealii.package +++ b/deal.II/packages/dealii.package @@ -9,6 +9,22 @@ CONFOPTS=" \ ${DEAL_CONFOPTS} \ " +CONFOPTS="${CONFOPTS} \ +-D ARPACK_DIR=${ARPACK_DIR}\ +" + +CONFOPTS="${CONFOPTS} \ +-D METIS_DIR=${METIS_DIR} \ +" + +CONFOPTS="${CONFOPTS} \ +-D MUMPS_DIR=${MUMPS_DIR} \ +" + +CONFOPTS="${CONFOPTS} \ +-D P4EST_DIR=${P4EST_DIR} \ +" + CONFOPTS="${CONFOPTS} \ -D HDF5_DIR=${HDF5_DIR} \ " diff --git a/project-deal.II.cfg b/project-deal.II.cfg index 6ce9e48..61ebf32 100644 --- a/project-deal.II.cfg +++ b/project-deal.II.cfg @@ -34,9 +34,8 @@ DEAL_CONFOPTS=" \ -D DEAL_II_COMPONENT_PARAMETER_GUI=ON \ " -# Please add the following path(es) to DEAL_CONFOPTS ahead, -# if you wish to use (self-compiled) versions of them together -# with deal.II. +# Please add the following path(es) if you wish to use +# (self-compiled) versions of them together with deal.II. # Make sure, that the coinciding option is setted to "ON". # If you want to use the packages from your system, you # may not set the variables (usually deal.II is smart enough @@ -45,12 +44,20 @@ DEAL_CONFOPTS=" \ # simply set the option to ON and do NOT specify the path, # this will be done automatically elsewhere. # -#-D ARPACK_DIR= \ -#-D METIS_DIR= \ -#-D MUMPS_DIR= \ -#-D P4EST_DIR= \ -#-D TRILINOS_DIR= \ -#-D HDF5_DIR= \ +# ARPACK_DIR= +# METIS_DIR= +# MUMPS_DIR= +# P4EST_DIR= +# TRILINOS_DIR= +# HDF5_DIR= +# PETSC_DIR= +# SLEPC_DIR= +# BLAS_DIR= +# LAPACK_DIR= + +######################################################################### +# Do you want to use MKL? +MKL=OFF ######################################################################### # How many processes would you like to build using? @@ -96,6 +103,7 @@ STABLE_BUILD=true ### DO NOT MODIFY THE CODE BELOW ### #################################### +######################################################################### # Loop over the options in DEAL_CONFOPTS and if the package is turned off, add # it to the PACKAGES_OFF list. for PACKAGE in ${DEAL_CONFOPTS[@]}; do @@ -117,5 +125,19 @@ if [[ ${PACKAGES_OFF} =~ 'TRILINOS' ]]; then PACKAGES_OFF=${PACKAGES_OFF}' SUPERLU_DIST'; fi -# Transorm upper case to lower case. +# Transform upper case to lower case. PACKAGES_OFF=${PACKAGES_OFF,,} + +######################################################################### +TRILINOS_CONFOPTS=" \ +-D BLAS_LIBRARY_DIRS:STRING=${BLAS_DIR} \ +-D LAPACK_LIBRARY_DIRS:STRING=${LAPACK_LIBRARY_DIRS} \ +" + +if [[ ${MKL} == ON ]]; then + TRILINOS_CONFOPTS=" \ + ${TRILINOS_CONFOPTS} \ + -D BLAS_LIBRARY_NAMES:STRING='mkl_core;mkl_sequential' \ + -D LAPACK_LIBRARY_NAMES:STRING=mkl_intel_lp64 \ + " +fi -- 2.39.5