From d4dd50be8081847e20df7d3b185783c63945342e Mon Sep 17 00:00:00 2001 From: Fabian Castelli Date: Mon, 7 Jun 2021 11:17:10 +0200 Subject: [PATCH] Add ginkgo package --- candi.cfg | 1 + deal.II-toolchain/packages/dealii.package | 16 +++++++ deal.II-toolchain/packages/ginkgo.package | 52 +++++++++++++++++++++++ 3 files changed, 69 insertions(+) create mode 100644 deal.II-toolchain/packages/ginkgo.package diff --git a/candi.cfg b/candi.cfg index 9244c8d..5de3961 100644 --- a/candi.cfg +++ b/candi.cfg @@ -64,6 +64,7 @@ PACKAGES="load:dealii-prepare" #PACKAGES="${PACKAGES} once:adolc" #PACKAGES="${PACKAGES} once:arpack-ng" #PACKAGES="${PACKAGES} once:assimp" +#PACKAGES="${PACKAGES} once:ginkgo" #PACKAGES="${PACKAGES} once:gsl" PACKAGES="${PACKAGES} once:opencascade" PACKAGES="${PACKAGES} once:parmetis" diff --git a/deal.II-toolchain/packages/dealii.package b/deal.II-toolchain/packages/dealii.package index 227308c..761370f 100644 --- a/deal.II-toolchain/packages/dealii.package +++ b/deal.II-toolchain/packages/dealii.package @@ -225,6 +225,22 @@ if [ ! -z "${OPENCASCADE_DIR}" ]; then -D DEAL_II_WITH_OPENCASCADE:BOOL=ON" fi +######################################## +# GINKGO +if [[ ${PACKAGES_OFF} =~ 'ginkgo' ]]; then + if [ ! -z "${GINKGO_DIR}" ]; then + cecho ${INFO} "deal.II: unset GINKGO_DIR due to forced DEAL_II_WITH_GINKGO:BOOL=OFF option" + unset GINKGO_DIR + fi +fi + +if [ ! -z "${GINKGO_DIR}" ]; then + cecho ${INFO} "deal.II: configuration with GINKGO" + CONFOPTS="${CONFOPTS} \ + -D DEAL_II_WITH_GINKGO:BOOL=ON \ + -D GINKGO_DIR=${GINKGO_DIR}" +fi + ################################################################################ package_specific_install() { diff --git a/deal.II-toolchain/packages/ginkgo.package b/deal.II-toolchain/packages/ginkgo.package new file mode 100644 index 0000000..17bf71c --- /dev/null +++ b/deal.II-toolchain/packages/ginkgo.package @@ -0,0 +1,52 @@ +################################################################################ +## GINKGO ## +################################################################################ + +VERSION=develop +NAME=ginkgo.git +SOURCE=https://github.com/ginkgo-project/ +EXTRACTSTO=ginkgo-${VERSION} +PACKING=git + +BUILDCHAIN=cmake + +BUILDDIR=${BUILD_PATH}/ginkgo-${VERSION} +INSTALL_PATH=${INSTALL_PATH}/ginkgo-${VERSION} + +CONFOPTS="\ + -G 'Unix Makefiles' \ + -D CMAKE_BUILD_TYPE=Release \ + -D BUILD_SHARED_LIBS:BOOL=ON \ + -D GINKGO_BUILD_TESTS:BOOL=OFF \ + -D GINKGO_FAST_TESTS:BOOL=OFF \ + -D GINKGO_BUILD_EXAMPLES:BOOL=OFF \ + -D GINKGO_BUILD_BENCHMARKS:BOOL=OFF \ + -D GINKGO_BENCHMARK_ENABLE_TUNING:BOOL=OFF \ + -D GINKGO_BUILD_DOC:BOOL=OFF \ + -D GINKGO_VERBOSE_LEVEL=1 \ + -D GINKGO_DEVEL_TOOLS:BOOL=OFF \ + -D GINKGO_WITH_CLANG_TIDY:BOOL=OFF \ + -D GINKGO_WITH_IWYU:BOOL=OFF \ + -D GINKGO_CHECK_CIRCULAR_DEPS:BOOL=OFF \ + -D GINKGO_WITH_CCACHE:BOOL=OFF \ + -D GINKGO_BUILD_HWLOC:BOOL=OFF" + +# Autodetected ginkgo options +# -D GINKGO_BUILD_OMP:BOOL=ON \ +# -D GINKGO_BUILD_REFERENCE:BOOL=ON \ +# -D GINKGO_BUILD_CUDA:BOOL=OFF \ +# -D GINKGO_BUILD_HIP:BOOL=OFF \ +# -D GINKGO_BUILD_DPCPP:BOOL=OFF \ + +package_specific_register () { + export GINKGO_DIR=${INSTALL_PATH} +} + +package_specific_conf () { + # Generate configuration file + CONFIG_FILE=${CONFIGURATION_PATH}/${NAME} + rm -f $CONFIG_FILE + echo " +export GINKGO_DIR=${INSTALL_PATH} +" >> $CONFIG_FILE +} -- 2.39.5