Commit 63a84dff authored by mattijs's avatar mattijs
Browse files

ENH:paraview config: support for system installed paraview

parent bbfec946
......@@ -85,10 +85,28 @@ setenv ParaView_DIR $WM_THIRD_PARTY_DIR/platforms/$WM_ARCH$WM_COMPILER/paraview-
# set paths if binaries or source are present
if ( -r $ParaView_DIR || -r $paraviewInstDir ) then
setenv ParaView_INCLUDE_DIR $ParaView_DIR/include/paraview-${ParaView_MAJOR}
if (! -r $ParaView_INCLUDE_DIR && -r $ParaView_DIR/include/paraview) then
setenv ParaView_INCLUDE_DIR $ParaView_DIR/include/paraview
endif
set ParaView_LIB_DIR=${ParaView_DIR}/lib/paraview-${ParaView_MAJOR}
if (! -r $ParaView_LIB_DIR && -r ${ParaView_DIR}/lib/paraview) then
set ParaView_LIB_DIR=${ParaView_DIR}/lib/paraview
endif
setenv PATH ${ParaView_DIR}/bin:${PATH}
setenv LD_LIBRARY_PATH "${ParaView_DIR}/lib/paraview-${ParaView_MAJOR}:${LD_LIBRARY_PATH}"
setenv LD_LIBRARY_PATH "${ParaView_LIB_DIR}:${LD_LIBRARY_PATH}"
setenv PV_PLUGIN_PATH $FOAM_LIBBIN/paraview-${ParaView_MAJOR}
setenv ParaView_INCLUDE_DIR $ParaView_DIR/include/paraview-${ParaView_MAJOR}
if ($?FOAM_VERBOSE && $?prompt) then
echo "Using paraview"
echo " ParaView_DIR : $ParaView_DIR"
echo " ParaView_LIB_DIR : $ParaView_LIB_DIR"
echo " ParaView_INCLUDE_DIR : $ParaView_INCLUDE_DIR"
echo " PV_PLUGIN_PATH : $PV_PLUGIN_PATH"
endif
# add in python libraries if required
set paraviewPython=$ParaView_DIR/Utilities/VTKPythonWrapping
......
......@@ -94,11 +94,30 @@ export ParaView_DIR=$WM_THIRD_PARTY_DIR/platforms/$WM_ARCH$WM_COMPILER/paraview-
# set paths if binaries or source are present
if [ -r $ParaView_DIR -o -r $paraviewInstDir ]
then
export ParaView_INCLUDE_DIR=$ParaView_DIR/include/paraview-$ParaView_MAJOR
if [ ! -d $ParaView_INCLUDE_DIR -a -d $ParaView_DIR/include/paraview ]
then
export ParaView_INCLUDE_DIR=$ParaView_DIR/include/paraview
fi
ParaView_LIB_DIR=$ParaView_DIR/lib/paraview-$ParaView_MAJOR
if [ ! -d $ParaView_LIB_DIR -a -d $ParaView_DIR/lib/paraview ]
then
ParaView_LIB_DIR=$ParaView_DIR/lib/paraview
fi
export PATH=$ParaView_DIR/bin:$PATH
export LD_LIBRARY_PATH=$ParaView_DIR/lib/paraview-$ParaView_MAJOR:$LD_LIBRARY_PATH
export LD_LIBRARY_PATH=$ParaView_LIB_DIR:$LD_LIBRARY_PATH
export PV_PLUGIN_PATH=$FOAM_LIBBIN/paraview-$ParaView_MAJOR
export ParaView_INCLUDE_DIR=$ParaView_DIR/include/paraview-$ParaView_MAJOR
if [ "$FOAM_VERBOSE" -a "$PS1" ]
then
echo "Using paraview"
echo " ParaView_DIR : $ParaView_DIR"
echo " ParaView_LIB_DIR : $ParaView_LIB_DIR"
echo " ParaView_INCLUDE_DIR : $ParaView_INCLUDE_DIR"
echo " PV_PLUGIN_PATH : $PV_PLUGIN_PATH"
fi
# add in python libraries if required
paraviewPython=$ParaView_DIR/Utilities/VTKPythonWrapping
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment