CONFIG: improve handling of in-source PETSC installations

- when installed in-source, use PETSC_ARCH to find additional include
  directory and the correct library directory

CONFIG: bump to new hypre version

- add -hint option for have_adios2, have_hypre, have_petsc
This commit is contained in:
Mark Olesen
2020-06-18 16:35:19 +02:00
parent 6194548871
commit 420be3f9ab
7 changed files with 130 additions and 54 deletions

View File

@ -5,11 +5,10 @@
# \\ / A nd | www.openfoam.com
# \\/ M anipulation |
#------------------------------------------------------------------------------
# Copyright (C) 2017-2018 OpenCFD Ltd.
# Copyright (C) 2017-2020 OpenCFD Ltd.
#------------------------------------------------------------------------------
# License
# This file is part of OpenFOAM, licensed under GNU General Public License
# <http://www.gnu.org/licenses/>.
# This file is part of OpenFOAM, distributed under GPL-3.0-or-later.
#
# File
# etc/config.csh/adios2
@ -22,7 +21,7 @@
# USER EDITABLE PART: Changes made here may be lost with the next upgrade
set adios2_version=ADIOS2-2.4.0
setenv ADIOS2_ARCH_PATH $WM_THIRD_PARTY_DIR/platforms/$WM_ARCH$WM_COMPILER/$adios2_version
setenv ADIOS2_ARCH_PATH "$WM_THIRD_PARTY_DIR/platforms/$WM_ARCH$WM_COMPILER/$adios2_version"
# END OF (NORMAL) USER EDITABLE PART
#------------------------------------------------------------------------------

View File

@ -5,11 +5,10 @@
# \\ / A nd | www.openfoam.com
# \\/ M anipulation |
#------------------------------------------------------------------------------
# Copyright (C) 2018 OpenCFD Ltd.
# Copyright (C) 2018-2020 OpenCFD Ltd.
#------------------------------------------------------------------------------
# License
# This file is part of OpenFOAM, licensed under GNU General Public License
# <http://www.gnu.org/licenses/>.
# This file is part of OpenFOAM, distributed under GPL-3.0-or-later.
#
# File
# etc/config.csh/hypre
@ -31,8 +30,8 @@
#------------------------------------------------------------------------------
# USER EDITABLE PART: Changes made here may be lost with the next upgrade
set hypre_version=hypre-2.11.2
setenv HYPRE_ARCH_PATH $WM_THIRD_PARTY_DIR/platforms/$WM_ARCH$WM_COMPILER$WM_PRECISION_OPTION$WM_LABEL_OPTION/$hypre_version
set hypre_version=hypre-2.19.0
setenv HYPRE_ARCH_PATH "$WM_THIRD_PARTY_DIR/platforms/$WM_ARCH$WM_COMPILER$WM_PRECISION_OPTION$WM_LABEL_OPTION/$hypre_version"
# END OF (NORMAL) USER EDITABLE PART
#------------------------------------------------------------------------------

View File

@ -5,11 +5,10 @@
# \\ / A nd | www.openfoam.com
# \\/ M anipulation |
#------------------------------------------------------------------------------
# Copyright (C) 2017-2018 OpenCFD Ltd.
# Copyright (C) 2017-2020 OpenCFD Ltd.
#------------------------------------------------------------------------------
# License
# This file is part of OpenFOAM, licensed under GNU General Public License
# <http://www.gnu.org/licenses/>.
# This file is part of OpenFOAM, distributed under GPL-3.0-or-later.
#
# File
# etc/config.sh/adios2
@ -23,7 +22,7 @@
# USER EDITABLE PART: Changes made here may be lost with the next upgrade
adios2_version=ADIOS2-2.4.0
export ADIOS2_ARCH_PATH=$WM_THIRD_PARTY_DIR/platforms/$WM_ARCH$WM_COMPILER/$adios2_version
export ADIOS2_ARCH_PATH="$WM_THIRD_PARTY_DIR/platforms/$WM_ARCH$WM_COMPILER/$adios2_version"
# END OF (NORMAL) USER EDITABLE PART
#------------------------------------------------------------------------------
@ -51,7 +50,10 @@ then
if output="$($WM_PROJECT_DIR/bin/tools/lib-dir -sh $ADIOS2_ARCH_PATH 2>/dev/null)"
then
eval "$output"
PATH="$ADIOS2_ARCH_PATH/bin:$PATH"
if [ -d "$ADIOS2_ARCH_PATH/bin" ]
then
PATH="$ADIOS2_ARCH_PATH/bin:$PATH"
fi
fi
unset adios2_version output

View File

@ -5,11 +5,10 @@
# \\ / A nd | www.openfoam.com
# \\/ M anipulation |
#------------------------------------------------------------------------------
# Copyright (C) 2018 OpenCFD Ltd.
# Copyright (C) 2018-2020 OpenCFD Ltd.
#------------------------------------------------------------------------------
# License
# This file is part of OpenFOAM, licensed under GNU General Public License
# <http://www.gnu.org/licenses/>.
# This file is part of OpenFOAM, distributed under GPL-3.0-or-later.
#
# File
# etc/config.sh/hypre
@ -28,8 +27,8 @@
#------------------------------------------------------------------------------
# USER EDITABLE PART: Changes made here may be lost with the next upgrade
hypre_version=hypre-2.11.2
export HYPRE_ARCH_PATH=$WM_THIRD_PARTY_DIR/platforms/$WM_ARCH$WM_COMPILER$WM_PRECISION_OPTION$WM_LABEL_OPTION/$hypre_version
hypre_version=hypre-2.19.0
export HYPRE_ARCH_PATH="$WM_THIRD_PARTY_DIR/platforms/$WM_ARCH$WM_COMPILER$WM_PRECISION_OPTION$WM_LABEL_OPTION/$hypre_version"
# END OF (NORMAL) USER EDITABLE PART
#------------------------------------------------------------------------------
@ -41,10 +40,22 @@ fi
if command -v _foamAddLibAuto >/dev/null
then
# Normal sourcing (not makeHYPRE)
_foamAddLibAuto $HYPRE_ARCH_PATH
unset hypre_version
elif [ "$1" = "-force" ]
then
# Forced command-line sourcing
if output="$($WM_PROJECT_DIR/bin/tools/lib-dir -sh $HYPRE_ARCH_PATH 2>/dev/null)"
then
eval "$output"
fi
unset hypre_version output
fi
#------------------------------------------------------------------------------