diff --git a/flang/tools/f18/flang b/flang/tools/f18/flang --- a/flang/tools/f18/flang +++ b/flang/tools/f18/flang @@ -358,6 +358,12 @@ # first generated and then deleted by this script. # NOTE: We need to make sure that the base-name is unique to every # invocation. Otherwise we can't use this script in parallel. + if ! command -v uuidgen &> /dev/null + then + echo "uuidgen is required for generating unparsed file names." + exit 1 + fi + local -r unique_id=$(uuidgen | cut -b25-36) local -r unparsed_file_base="flang_unparsed_file_$unique_id"