From fa6630619259c5cd72e3a7e4248d151e6dbc5495 Mon Sep 17 00:00:00 2001 From: Timo Heister Date: Fri, 5 Oct 2018 18:25:43 +0200 Subject: [PATCH] export BLAS_LIB, fix petsc --- deal.II-toolchain/packages/openblas.package | 2 ++ deal.II-toolchain/packages/petsc.package | 5 +++++ 2 files changed, 7 insertions(+) diff --git a/deal.II-toolchain/packages/openblas.package b/deal.II-toolchain/packages/openblas.package index ee3837d..6623c1d 100644 --- a/deal.II-toolchain/packages/openblas.package +++ b/deal.II-toolchain/packages/openblas.package @@ -23,6 +23,7 @@ package_specific_build () { package_specific_register () { export LAPACK_DIR=${INSTALL_PATH}/lib export BLAS_DIR=${INSTALL_PATH}/lib + export BLAS_LIB=${INSTALL_PATH}/lib/libopenblas.so # older cmake (for example 3.5) does not detect openblas by default so # we force detection by adding to the deal.II configure line: export DEAL_CONFOPTS="-D LAPACK_FOUND=true -D LAPACK_LIBRARIES=${INSTALL_PATH}/lib/libopenblas.so ${DEAL_CONFOPTS}" @@ -35,5 +36,6 @@ package_specific_conf () { echo " export LAPACK_DIR=${INSTALL_PATH}/lib export BLAS_DIR=${INSTALL_PATH}/lib +export BLAS_LIB=${INSTALL_PATH}/lib/libopenblas.so " >> $CONFIG_FILE } diff --git a/deal.II-toolchain/packages/petsc.package b/deal.II-toolchain/packages/petsc.package index 2fcb24a..05c5582 100644 --- a/deal.II-toolchain/packages/petsc.package +++ b/deal.II-toolchain/packages/petsc.package @@ -65,6 +65,11 @@ if [ ! -z "${MKL_DIR}" ]; then cecho ${INFO} "petsc: configuration with MKL" cecho ${INFO} "petsc: configuration with blas-lapack-dir=${MKL_DIR}" CONFOPTS="${CONFOPTS} --with-blas-lapack-dir=${MKL_DIR}" +else + if [ ! -z "${BLAS_LIB}" ]; then + cecho ${INFO} "petsc: configuration with --with-blas-lapack-lib=${BLAS_LIB}" + CONFOPTS="${CONFOPTS} --with-blas-lapack-lib=${BLAS_LIB}" + fi fi # Add ParMETIS, if present -- 2.39.5