mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
STYLE: use 'foamCompiler' instead of 'compilerInstall'
- more obvious in its meaning
This commit is contained in:
@ -75,7 +75,7 @@ do
|
||||
_inlineSed \
|
||||
etc/bashrc \
|
||||
'/^[^#]/s@foamInstall=.*@foamInstall='"$foamInstall@" \
|
||||
"Replacing foamInstall setting by $foamInstall"
|
||||
"Replacing foamInstall setting by '$foamInstall'"
|
||||
shift 2
|
||||
;;
|
||||
--projectName)
|
||||
@ -84,7 +84,7 @@ do
|
||||
_inlineSed \
|
||||
etc/bashrc \
|
||||
'/^[^#]/s@WM_PROJECT_DIR=.*@WM_PROJECT_DIR=$WM_PROJECT_INST_DIR/'"$projectName@" \
|
||||
"Replacing WM_PROJECT_DIR setting by $projectName"
|
||||
"Replacing WM_PROJECT_DIR setting by '$projectName'"
|
||||
shift 2
|
||||
;;
|
||||
--archOption)
|
||||
@ -93,7 +93,7 @@ do
|
||||
_inlineSed \
|
||||
etc/bashrc \
|
||||
'/^[^#]/s@: ${WM_ARCH_OPTION:=64}@WM_ARCH_OPTION='"$archOption@" \
|
||||
"Replacing WM_ARCH_OPTION setting by $archOption"
|
||||
"Replacing WM_ARCH_OPTION setting by '$archOption'"
|
||||
shift 2
|
||||
;;
|
||||
--paraviewInstall)
|
||||
@ -102,7 +102,7 @@ do
|
||||
_inlineSed \
|
||||
etc/apps/paraview3/bashrc \
|
||||
'/^[^#]/s@ParaView_DIR=.*@ParaView_DIR='"$paraviewInstall@" \
|
||||
"Replacing ParaView_DIR setting by $paraviewInstall"
|
||||
"Replacing ParaView_DIR setting by '$paraviewInstall'"
|
||||
shift 2
|
||||
;;
|
||||
*)
|
||||
@ -113,18 +113,18 @@ done
|
||||
|
||||
[ -n "$foamInstall" -o -n "$projectName" -o -n "$archOption" -o -n "$paraviewInstall" ] || usage "Please specify at least one configure option"
|
||||
|
||||
#echo "Replacing WM_PROJECT setting by $projectName"
|
||||
#echo "Replacing WM_PROJECT setting by '$projectName'"
|
||||
#sed -i -e 's@WM_PROJECT=.*@WM_PROJECT='"$projectName@" etc/bashrc
|
||||
|
||||
# Replace the WM_MPLIB always
|
||||
_inlineSed \
|
||||
etc/bashrc \
|
||||
'/^[^#]/s@: ${WM_MPLIB:=.*}@WM_MPLIB=SYSTEMOPENMPI@' \
|
||||
"Replacing WM_MPLIB setting by SYSTEMOPENMPI"
|
||||
# Replace the compilerInstall always
|
||||
"Replacing WM_MPLIB setting by 'SYSTEMOPENMPI'"
|
||||
# Replace the foamCompiler always
|
||||
_inlineSed \
|
||||
etc/settings.sh \
|
||||
'/^[^#]/s@: ${compilerInstall:=.*}@compilerInstall=system@' \
|
||||
"Replacing compilerInstall setting by system"
|
||||
'/^[^#]/s@: ${foamCompiler:=.*}@foamCompiler=system@' \
|
||||
"Replacing foamCompiler setting by 'system'"
|
||||
|
||||
#------------------------------------------------------------------------------
|
||||
|
||||
@ -38,7 +38,7 @@
|
||||
|
||||
## Specify system compiler
|
||||
## ~~~~~~~~~~~~~~~~~~~~~~~
|
||||
#set compilerInstall=system
|
||||
#set foamCompiler=system
|
||||
|
||||
## Specify system openmpi
|
||||
## ~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
@ -38,7 +38,7 @@
|
||||
|
||||
# Specify system compiler
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~
|
||||
compilerInstall=system
|
||||
foamCompiler=system
|
||||
|
||||
# Specify system openmpi
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
@ -26,7 +26,7 @@
|
||||
#
|
||||
# Description
|
||||
# Startup file for OpenFOAM
|
||||
# Sourced from OpenFOAM-??/etc/cshrc
|
||||
# Sourced from OpenFOAM-<VERSION>/etc/cshrc
|
||||
#
|
||||
#------------------------------------------------------------------------------
|
||||
|
||||
@ -68,8 +68,10 @@ setenv FOAM_UTILITIES $FOAM_APP/utilities
|
||||
setenv FOAM_SOLVERS $FOAM_APP/solvers
|
||||
setenv FOAM_RUN $WM_PROJECT_USER_DIR/run
|
||||
|
||||
# add OpenFOAM scripts and wmake to the path
|
||||
setenv PATH ${WM_DIR}:${WM_PROJECT_DIR}/bin:${PATH}
|
||||
# add wmake to the path - not required for runtime only environment
|
||||
if ( -d "${WM_DIR}" ) setenv PATH ${WM_DIR}:${PATH}
|
||||
# add OpenFOAM scripts to the path
|
||||
setenv PATH ${WM_PROJECT_DIR}/bin:${PATH}
|
||||
|
||||
_foamAddPath ${FOAM_USER_APPBIN}:${FOAM_SITE_APPBIN}:${FOAM_APPBIN}
|
||||
# Make sure to pick up dummy versions of external libraries last
|
||||
@ -83,11 +85,12 @@ unsetenv MPFR_ARCH_PATH
|
||||
|
||||
# Select compiler installation
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
# compilerInstall = OpenFOAM | system
|
||||
if ( ! $?compilerInstall ) set compilerInstall=system
|
||||
# foamCompiler = system | ThirdParty (OpenFOAM)
|
||||
if ( ! $?foamCompiler ) set foamCompiler=system
|
||||
|
||||
switch ("$compilerInstall")
|
||||
switch ("$foamCompiler")
|
||||
case OpenFOAM:
|
||||
case ThirdParty:
|
||||
switch ("$WM_COMPILER")
|
||||
case Gcc:
|
||||
case Gcc++0x:
|
||||
@ -143,7 +146,7 @@ case OpenFOAM:
|
||||
echo "Warning in $WM_PROJECT_DIR/etc/settings.csh:"
|
||||
echo " Cannot find $gccDir installation."
|
||||
echo " Please install this compiler version or if you wish to use the system compiler,"
|
||||
echo " change the 'compilerInstall' setting to 'system' in this file"
|
||||
echo " change the 'foamCompiler' setting to 'system' in this file"
|
||||
echo
|
||||
endif
|
||||
|
||||
@ -181,7 +184,7 @@ case OpenFOAM:
|
||||
echo "Warning in $WM_PROJECT_DIR/etc/settings.csh:"
|
||||
echo " Cannot find $clangDir installation."
|
||||
echo " Please install this compiler version or if you wish to use the system compiler,"
|
||||
echo " change the 'compilerInstall' setting to 'system' in this file"
|
||||
echo " change the 'foamCompiler' setting to 'system' in this file"
|
||||
echo
|
||||
endif
|
||||
|
||||
@ -382,6 +385,6 @@ endif
|
||||
# cleanup environment:
|
||||
# ~~~~~~~~~~~~~~~~~~~~
|
||||
unalias _foamAddPath _foamAddLib _foamAddMan
|
||||
unset compilerInstall minBufferSize
|
||||
unset foamCompiler minBufferSize
|
||||
|
||||
# ----------------------------------------------------------------- end-of-file
|
||||
|
||||
@ -26,7 +26,7 @@
|
||||
#
|
||||
# Description
|
||||
# Startup file for OpenFOAM
|
||||
# Sourced from OpenFOAM-??/etc/bashrc
|
||||
# Sourced from OpenFOAM-<VERSION>/etc/bashrc
|
||||
#
|
||||
#------------------------------------------------------------------------------
|
||||
|
||||
@ -91,8 +91,10 @@ export FOAM_UTILITIES=$FOAM_APP/utilities
|
||||
export FOAM_SOLVERS=$FOAM_APP/solvers
|
||||
export FOAM_RUN=$WM_PROJECT_USER_DIR/run
|
||||
|
||||
# add OpenFOAM scripts and wmake to the path
|
||||
export PATH=$WM_DIR:$WM_PROJECT_DIR/bin:$PATH
|
||||
# add wmake to the path - not required for runtime only environment
|
||||
[ -d "$WM_DIR" ] && PATH=$WM_DIR:$PATH
|
||||
# add OpenFOAM scripts to the path
|
||||
export PATH=$WM_PROJECT_DIR/bin:$PATH
|
||||
|
||||
_foamAddPath $FOAM_USER_APPBIN:$FOAM_SITE_APPBIN:$FOAM_APPBIN
|
||||
# Make sure to pick up dummy versions of external libraries last
|
||||
@ -105,11 +107,11 @@ unset MPFR_ARCH_PATH
|
||||
|
||||
# Select compiler installation
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
# compilerInstall = OpenFOAM | system
|
||||
: ${compilerInstall:=system}
|
||||
# foamCompiler = system | ThirdParty (OpenFOAM)
|
||||
: ${foamCompiler:=system}
|
||||
|
||||
case "${compilerInstall:-OpenFOAM}" in
|
||||
OpenFOAM)
|
||||
case "${foamCompiler}" in
|
||||
OpenFOAM | ThirdParty)
|
||||
case "$WM_COMPILER" in
|
||||
Gcc | Gcc++0x)
|
||||
gcc_version=gcc-4.4.3
|
||||
@ -161,7 +163,7 @@ OpenFOAM)
|
||||
echo "Warning in $WM_PROJECT_DIR/etc/settings.sh:"
|
||||
echo " Cannot find $gccDir installation."
|
||||
echo " Please install this compiler version or if you wish to use the system compiler,"
|
||||
echo " change the 'compilerInstall' setting to 'system' in this file"
|
||||
echo " change the 'foamCompiler' setting to 'system' in this file"
|
||||
echo
|
||||
}
|
||||
|
||||
@ -202,7 +204,7 @@ OpenFOAM)
|
||||
echo "Warning in $WM_PROJECT_DIR/etc/settings.sh:"
|
||||
echo " Cannot find $clangDir installation."
|
||||
echo " Please install this compiler version or if you wish to use the system compiler,"
|
||||
echo " change the 'compilerInstall' setting to 'system' in this file"
|
||||
echo " change the 'foamCompiler' setting to 'system' in this file"
|
||||
echo
|
||||
}
|
||||
|
||||
@ -406,6 +408,6 @@ export MPI_BUFFER_SIZE
|
||||
|
||||
# cleanup environment:
|
||||
# ~~~~~~~~~~~~~~~~~~~~
|
||||
unset _foamAddPath _foamAddLib _foamAddMan compilerInstall minBufferSize
|
||||
unset _foamAddPath _foamAddLib _foamAddMan foamCompiler minBufferSize
|
||||
|
||||
# ----------------------------------------------------------------- end-of-file
|
||||
|
||||
Reference in New Issue
Block a user