CONFIG: export ThirdParty Qt5_DIR (issue #827)

This commit is contained in:
Mark Olesen 2018-05-14 17:04:18 +01:00
parent df3b406ef8
commit 65129d7b90
6 changed files with 30 additions and 8 deletions

View File

@ -13,8 +13,8 @@
# config.csh/example/paraview
#
# Description
# Example of defining a different ParaView_VERSION but retaining
# the standard config.csh/paraview mechanism
# Example of defining a different ParaView_VERSION but retaining the
# standard config.csh/paraview mechanism
#
# Note
# This file could be copied to a user or site location, but should never
@ -25,7 +25,8 @@
set pv=5.5.0
set pv=5.5.0-mpipy
set qt=qt-5.9.0
eval `foamEtcFile -csh -config -mode=o paraview -- ParaView_VERSION=$pv`
eval `foamEtcFile -csh -config -mode=o paraview -- ParaView_VERSION=$pv ParaView_QT=$qt`
#------------------------------------------------------------------------------

View File

@ -120,8 +120,16 @@ if ( $?ParaView_VERSION ) then
#OBSOLETE? endif
# QT libraries as required
# Set Qt5_DIR to root directory.
# Another possibility: "qtpaths --qt-version"
set qtDir="$archDir/$ParaView_QT"
if ( -d "$qtDir" ) then
switch ($ParaView_QT)
case *-qt*:
setenv Qt5_DIR $qtDir
breaksw
endsw
foreach qtLibDir ("$qtDir/lib$WM_COMPILER_LIB_ARCH" "$qtDir/lib")
if ( -d "$qtLibDir" ) then
setenv LD_LIBRARY_PATH "${qtLibDir}:${LD_LIBRARY_PATH}"

View File

@ -111,6 +111,7 @@ unsetenv ParaView_INCLUDE_DIR
unsetenv ParaView_VERSION
unsetenv PV_PLUGIN_PATH
unsetenv VTK_DIR
unsetenv Qt5_DIR # Perhaps only unset if it is in WM_THIRD_PARTY_DIR?
#------------------------------------------------------------------------------
# Unset other ThirdParty environment variables

View File

@ -13,8 +13,8 @@
# config.sh/example/paraview
#
# Description
# Example of defining a different ParaView_VERSION but retaining
# the standard config.sh/paraview mechanism
# Example of defining a different ParaView_VERSION but retaining the
# standard config.sh/paraview mechanism
#
# Note
# This file could be copied to a user or site location, but should never
@ -25,7 +25,8 @@
pv=5.5.0
pv=5.5.0-mpipy
qt=qt-5.9.0
eval $(foamEtcFile -sh -config -mode=o paraview -- ParaView_VERSION=$pv)
eval $(foamEtcFile -sh -config -mode=o paraview -- ParaView_VERSION=$pv ParaView_QT=$qt)
#------------------------------------------------------------------------------

View File

@ -127,10 +127,16 @@ then
#OBSOLETE? export PYTHONPATH=$PYTHONPATH:${PYTHONPATH:+:}$pvPython:$pvLibDir
#OBSOLETE? fi
# QT libraries as required
# QT libraries as required, and Qt5_DIR for the root directory.
# Another possibility: "qtpaths --qt-version"
qtDir="$archDir/$ParaView_QT"
if [ -d "$qtDir" ]
then
case "$ParaView_QT" in
*-5*)
export Qt5_DIR=$qtDir
;;
esac
for qtLibDir in $qtDir/lib$WM_COMPILER_LIB_ARCH $qtDir/lib
do
if [ -d "$qtLibDir" ]

View File

@ -97,7 +97,6 @@ then
unset OPAL_PREFIX
fi
#------------------------------------------------------------------------------
# Unset Ensight/ParaView-related environment variables
@ -108,6 +107,12 @@ unset ParaView_VERSION
unset PV_PLUGIN_PATH
unset VTK_DIR
# Undefine Qt5_DIR if set to one of the paths on foamOldDirs
if [ -z "$($foamClean -env=Qt5_DIR "$foamOldDirs")" ]
then
unset Qt5_DIR
fi
#------------------------------------------------------------------------------
# Unset other ThirdParty environment variables