STYLE: additional comments about suffixes

- strip both prefix and suffix for VTK and ParaView builds
This commit is contained in:
Mark Olesen
2018-06-11 10:19:18 +02:00
parent dab3042c45
commit 54efaa445a
3 changed files with 22 additions and 3 deletions

View File

@ -47,7 +47,13 @@ then
fi fi
unset ParaView_DIR ParaView_INCLUDE_DIR PV_PLUGIN_PATH unset ParaView_DIR ParaView_INCLUDE_DIR PV_PLUGIN_PATH
ParaView_VERSION="${ParaView_VERSION##*-}" # Without prefix case "$ParaView_VERSION" in
[Pp]*)
ParaView_VERSION="${ParaView_VERSION##*-}" # Without "ParaView-" prefix
;;
esac
ParaView_VERSION="${ParaView_VERSION%%-*}" # Without suffix (eg, -python)
# Set initial ParaView_MAJOR based on current value of ParaView_VERSION # Set initial ParaView_MAJOR based on current value of ParaView_VERSION
setParaViewVersion ${ParaView_VERSION:-none} setParaViewVersion ${ParaView_VERSION:-none}

View File

@ -2,6 +2,10 @@
# An example for building particular combinations of ParaView with # An example for building particular combinations of ParaView with
# - mpi (0 = no upper-limit on processes) # - mpi (0 = no upper-limit on processes)
# - mesa # - mesa
# - python (required for Catalyst)
#
# NOTE: must modify etc/config.*/paraview to use this particular version
# and combination, or use chaining as per etc/config.*/example/paraview
# mesa=mesa-11.2.2 # mesa=mesa-11.2.2
# mesa=mesa-13.0.3 # mesa=mesa-13.0.3
@ -11,7 +15,8 @@ set -x
./makeParaView \ ./makeParaView \
-mpi=0 \ -mpi=0 \
-mesa-prefix $WM_THIRD_PARTY_DIR/platforms/$WM_ARCH$WM_COMPILER/$mesa \ -mesa-prefix $WM_THIRD_PARTY_DIR/platforms/$WM_ARCH$WM_COMPILER/$mesa \
-suffix mesa \ -python \
-suffix mesa-mpi-py \
"$@" "$@"
#------------------------------------------------------------------------------ #------------------------------------------------------------------------------

10
makeVTK
View File

@ -42,7 +42,15 @@ unset vtk_version mesa_version # Purge current values
# vtk version from OpenFOAM etc/config.sh file: # vtk version from OpenFOAM etc/config.sh file:
_foamEtc -config vtk _foamEtc -config vtk
VTK_VERSION="${vtk_version##*-}" # Without prefix VTK_VERSION="$vtk_version"
case "$VTK_VERSION" in
[Vv]*)
VTK_VERSION="${VTK_VERSION##*-}" # Without "VTK-" prefix
;;
esac
VTK_VERSION="${VTK_VERSION%%-*}" # Without suffix (eg, -mesa)
# New rendering backend (starting with vtk 7?). # New rendering backend (starting with vtk 7?).
withGL2=auto # auto-config based on version withGL2=auto # auto-config based on version