Commit 09ba9d39 authored by mark's avatar mark
Browse files

ENH: make FOAM_EXT_LIBBIN optional in the configuration files

- useful for builds that don't use the ThirdParty directory at all
parent b6c364c5
......@@ -32,7 +32,7 @@
# wmake/rules/General/mplibUSERMPI file and managing all settings
#
#------------------------------------------------------------------------------
unsetenv MPI_ARCH_PATH MPI_HOME FOAM_MPI_LIBBIN
unsetenv MPI_ARCH_PATH MPI_HOME
switch ("$WM_MPLIB")
case SYSTEMOPENMPI:
......@@ -249,16 +249,17 @@ endsw
# Add (non-dummy) MPI implementation
# Dummy MPI already added to LD_LIBRARY_PATH and has no external libraries
# - dummy MPI already added to LD_LIBRARY_PATH and has no external libraries
if ( "$FOAM_MPI" != dummy ) then
_foamAddLib ${FOAM_LIBBIN}/${FOAM_MPI}:${FOAM_EXT_LIBBIN}/${FOAM_MPI}
if ( $?FOAM_EXT_LIBBIN ) then # External libraries (allowed to be unset)
_foamAddLib ${FOAM_EXT_LIBBIN}/${FOAM_MPI}
endif
_foamAddLib ${FOAM_LIBBIN}/${FOAM_MPI}
endif
# Set the minimum MPI buffer size (used by all platforms except SGI MPI)
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Minimum MPI buffer size (used by all except SGI MPI)
if ( ! $?minBufferSize ) set minBufferSize=20000000
if ( $?MPI_BUFFER_SIZE ) then
if ( $MPI_BUFFER_SIZE < $minBufferSize ) then
setenv MPI_BUFFER_SIZE $minBufferSize
......
......@@ -197,8 +197,11 @@ endif
unset siteDir
_foamAddPath ${FOAM_USER_APPBIN}:${FOAM_SITE_APPBIN}:${FOAM_APPBIN}
# Make sure to pick up dummy versions of external libraries last
_foamAddLib ${FOAM_USER_LIBBIN}:${FOAM_SITE_LIBBIN}:${FOAM_LIBBIN}:${FOAM_EXT_LIBBIN}:${FOAM_LIBBIN}/dummy
_foamAddLib $FOAM_LIBBIN/dummy # Dummy versions of external libraries last
if ( $?FOAM_EXT_LIBBIN ) then # External libraries (allowed to be unset)
_foamAddLib $FOAM_EXT_LIBBIN
endif
_foamAddLib ${FOAM_USER_LIBBIN}:${FOAM_SITE_LIBBIN}:${FOAM_LIBBIN}
#------------------------------------------------------------------------------
......
......@@ -32,7 +32,7 @@
# wmake/rules/General/mplibUSERMPI file and managing all settings
#
#------------------------------------------------------------------------------
unset MPI_ARCH_PATH MPI_HOME FOAM_MPI_LIBBIN
unset MPI_ARCH_PATH MPI_HOME
case "$WM_MPLIB" in
SYSTEMOPENMPI)
......@@ -264,17 +264,19 @@ INTELMPI)
esac
# Add (non-dummy) MPI implementation
# Dummy MPI already added to LD_LIBRARY_PATH and has no external libraries
# - dummy MPI already added to LD_LIBRARY_PATH and has no external libraries
if [ "$FOAM_MPI" != dummy ] && type _foamAddLib > /dev/null 2>&1
then
_foamAddLib $FOAM_LIBBIN/$FOAM_MPI:$FOAM_EXT_LIBBIN/$FOAM_MPI
if [ -n "$FOAM_EXT_LIBBIN" ] # External libraries (allowed to be unset)
then
_foamAddLib $FOAM_EXT_LIBBIN/$FOAM_MPI
fi
_foamAddLib $FOAM_LIBBIN/$FOAM_MPI
fi
# Set the minimum MPI buffer size (used by all platforms except SGI MPI)
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Minimum MPI buffer size (used by all except SGI MPI)
: ${minBufferSize:=20000000}
if [ "${MPI_BUFFER_SIZE:=$minBufferSize}" -lt $minBufferSize ]
then
MPI_BUFFER_SIZE=$minBufferSize
......
......@@ -198,8 +198,12 @@ fi
unset siteDir
_foamAddPath $FOAM_USER_APPBIN:$FOAM_SITE_APPBIN:$FOAM_APPBIN
# Make sure to pick up dummy versions of external libraries last
_foamAddLib $FOAM_USER_LIBBIN:$FOAM_SITE_LIBBIN:$FOAM_LIBBIN:$FOAM_EXT_LIBBIN:$FOAM_LIBBIN/dummy
_foamAddLib $FOAM_LIBBIN/dummy # Dummy versions of external libraries last
if [ -n "$FOAM_EXT_LIBBIN" ] # External libraries (allowed to be unset)
then
_foamAddLib $FOAM_EXT_LIBBIN
fi
_foamAddLib $FOAM_USER_LIBBIN:$FOAM_SITE_LIBBIN:$FOAM_LIBBIN
#------------------------------------------------------------------------------
......
Supports Markdown
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