mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-12-28 03:37:59 +00:00
CONFIG: improve robustness/flexibility for MPI config handling
- use orte-info to determine prefix/libdir for openmpi. This removes a run-time dependency on mpicc, which is actually only needed for building with MPI (not running with MPI). The corresponding openmpi devel package (deb/rpm) will not necessarily be installed on a particular system. - retain mpicc logic if the new logic using orte-info does not deliver an answer. Final fallback to using 'orterun' to infer prefix/libdir. - Additional logic for intel and msmpi to make it easier to locate these vendor packages within ThirdParty (ie, under ThirdParty/opt/...) CONFIG: improve robustness - add check for absolute path when adding PATH/LD_LIBRARY_PATH etc. - prefix more variables with '_foam*' to prevent accidental overwrite of userspace shell variables when sourcing
This commit is contained in:
@ -143,14 +143,14 @@ export FOAM_USER_LIBBIN="$WM_PROJECT_USER_DIR/platforms/$WM_OPTIONS/lib"
|
||||
|
||||
|
||||
# Prepend wmake to the path - not required for runtime-only environment
|
||||
foundDir="$WM_PROJECT_DIR/wmake"
|
||||
_foamFoundDir="$WM_PROJECT_DIR/wmake"
|
||||
if [ -d "$WM_DIR" ]
|
||||
then
|
||||
foundDir="${WM_DIR}"
|
||||
_foamFoundDir="${WM_DIR}"
|
||||
fi
|
||||
if [ -d "$foundDir" ]
|
||||
if [ -d "$_foamFoundDir" ]
|
||||
then
|
||||
PATH="$foundDir:$PATH"
|
||||
PATH="$_foamFoundDir:$PATH"
|
||||
else
|
||||
unset WM_DIR
|
||||
fi
|
||||
@ -308,7 +308,7 @@ esac
|
||||
|
||||
# Cleanup
|
||||
# ~~~~~~~
|
||||
unset archDir siteDir foundDir archOption
|
||||
unset archOption archDir siteDir _foamFoundDir
|
||||
unset gcc_version gccDir
|
||||
unset gmp_version gmpDir mpfr_version mpfrDir mpc_version mpcDir
|
||||
unset clang_version clangDir
|
||||
|
||||
Reference in New Issue
Block a user