#!/bin/sh
cd "${0%/*}" || exit            # Run from this directory
set -- -all="${0##*/}" "$@"     # Execute this instead of ./Allwmake
. "${WM_PROJECT_DIR:?}"/wmake/scripts/AllwmakeParseArguments
. "${WM_PROJECT_DIR:?}"/wmake/scripts/wmakeFunctions  # Need wmake functions
. "${WM_PROJECT_DIR:?}"/wmake/scripts/have_scotch

#------------------------------------------------------------------------------
# Environment
#   - FOAM_MPI_LIBBIN (optional: defaults to FOAM_LIBBIN/FOAM_MPI)

: "${FOAM_EXT_LIBBIN:=/usr/lib$WM_COMPILER_LIB_ARCH}"  # Extra safety?
export FOAM_EXT_LIBBIN

if have_scotch
then
    if have_ptscotch
    then
        # Never need/want openmp for MPI interfaces
        wmakeLibMpi -no-openmp ptscotchDecomp "scotch=$SCOTCH_VERSION"
    fi
fi


#------------------------------------------------------------------------------
