COMP: adjust make scripts for systems with .dylib instead of .so

This commit is contained in:
Mark Olesen
2018-04-11 16:12:29 +02:00
parent 455551b48b
commit 6d7ef8dc42
9 changed files with 71 additions and 42 deletions

View File

@ -19,12 +19,15 @@
# ----------------------------------------------
# NO USER-CONFIGURABLE SETTINGS WITHIN THIS FILE
#------------------------------------------------------------------------------
# Dynamic library endings (default is .so)
[ "$(uname -s)" = Darwin ] && SO=dylib || SO=so
# Short-circuit test for an installation
if [ "$1" = "-test" ]
then
[ "$#" -eq 2 ] || { echo "${0##*/} -test : needs 1 argument"; exit 1; }
dir="$2" # <- MPI_ARCH_PATH
if [ -r "$dir/lib$WM_COMPILER_LIB_ARCH/libmpich.so" ]
if [ -r "$dir/lib$WM_COMPILER_LIB_ARCH/libmpich.$SO" ]
then
echo "Have mpich shared library (${dir##*/})"
exit 0
@ -122,7 +125,7 @@ fi
MPI_SOURCE_DIR=$sourceBASE/$mpiPACKAGE
MPI_ARCH_PATH=$installBASE/$mpiPACKAGE
if [ -r "$MPI_ARCH_PATH/lib_ARCH/libmpi.so" ]
if [ -r "$MPI_ARCH_PATH/lib_ARCH/libmpi.$SO" ]
then
echo "Already has shared library"
elif [ -r "$MPI_ARCH_PATH/lib/libmpi.a" ]