Skip to content

Commit

Permalink
skip rdbmsua.x if no modulefile
Browse files Browse the repository at this point in the history
  • Loading branch information
aerorahul committed Mar 19, 2024
1 parent 6943240 commit b343a68
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions ush/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,15 @@ set +x

# Build rdbfmsua.x with makefile separately due to GEMPAK issues in cmake
# Load modules
source "${DIR_ROOT}/ush/module-setup.sh"
module use "${DIR_ROOT}/modulefiles"
module load "rdbfmsua_${MACHINE_ID}.${COMPILER}"
module list
if [[ -f "${DIR_ROOT}/modulefiles/rdbfmsua_${MACHINE_ID}.${COMPILER}" ]]; then
source "${DIR_ROOT}/ush/module-setup.sh"
module use "${DIR_ROOT}/modulefiles"
module load "rdbfmsua_${MACHINE_ID}.${COMPILER}"
module list
else
echo "No modulefile for 'rdbfmsua' on '${MACHINE_ID}'. Skip building 'rdbfmsua.x'"
exit 0
fi

cd "${DIR_ROOT}/src/rdbfmsua.fd"
export MACHINE_ID
Expand Down

0 comments on commit b343a68

Please sign in to comment.