- the foamConfigurePaths script is quite simplistic and aggressive in what it changes. This was particularly evident when using it to change gcc/clang versions. Restructured the corresponding compiler settings to define default versions (eg, "default_gcc_version") that limits the scope of changes performed by foamConfigurePaths and makes it easier to understand if changing manually.
40 lines
1.3 KiB
Bash
40 lines
1.3 KiB
Bash
#----------------------------------*-sh-*--------------------------------------
|
|
# ========= |
|
|
# \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
|
# \\ / O peration |
|
|
# \\ / A nd | www.openfoam.com
|
|
# \\/ M anipulation |
|
|
#------------------------------------------------------------------------------
|
|
# Copyright (C) 2011-2016 OpenFOAM Foundation
|
|
# Copyright (C) 2017 OpenCFD Ltd.
|
|
#------------------------------------------------------------------------------
|
|
# License
|
|
# This file is part of OpenFOAM, distributed under GPL-3.0-or-later.
|
|
#
|
|
# File
|
|
# config.sh/example/compiler
|
|
# - sourced by OpenFOAM-*/etc/config.sh/settings
|
|
#
|
|
# Description
|
|
# Older example of fine tuning compiler settings for OpenFOAM.
|
|
#
|
|
# The preferred mechanism is now with a "compiler-$WM_COMPILER" file
|
|
# in one of the etc/ directories.
|
|
#
|
|
#------------------------------------------------------------------------------
|
|
|
|
# Load the standard versions
|
|
eval $($WM_PROJECT_DIR/bin/foamEtcFile -sh -config -mode=o compiler)
|
|
|
|
# Modify/override compiler settings
|
|
case "$WM_COMPILER" in
|
|
Gcc70*)
|
|
gcc_version=gcc-7.0.0
|
|
gmp_version=gmp-6.1.2
|
|
mpfr_version=mpfr-3.1.5
|
|
mpc_version=mpc-1.0.3
|
|
;;
|
|
esac
|
|
|
|
#------------------------------------------------------------------------------
|