diff --git a/bin/foamJob b/bin/foamJob index 5583c91888..75a963e93c 100755 --- a/bin/foamJob +++ b/bin/foamJob @@ -7,7 +7,7 @@ # \\/ M anipulation | #------------------------------------------------------------------------------ # Copyright (C) 2011-2015 OpenFOAM Foundation -# Copyright (C) 2019-2022 OpenCFD Ltd. +# Copyright (C) 2019-2023 OpenCFD Ltd. #------------------------------------------------------------------------------ # License # This file is part of OpenFOAM, distributed under GPL-3.0-or-later. @@ -23,6 +23,15 @@ # If dispatching via foamExec foamExec="$WM_PROJECT_DIR/bin/tools/foamExec" +# Darwin workaround - SIP clearing DYLD_LIBRARY_PATH variable +if [ -n "$FOAM_LD_LIBRARY_PATH" ] && [ -z "$DYLD_LIBRARY_PATH" ] +then + export DYLD_LIBRARY_PATH="$FOAM_LD_LIBRARY_PATH" +fi + + +#------------------------------------------------------------------------------ + usage() { exec 1>&2 while [ "$#" -ge 1 ]; do echo "$1"; shift; done