ENV: avoid misleading Fortran setup warnings

Fixes Homebrew/homebrew#31156.
Closes Homebrew/homebrew#47246.

Signed-off-by: Martin Afanasjew <martin@afanasjew.de>
This commit is contained in:
Martin Afanasjew 2015-12-18 17:04:58 +01:00
parent f0a370ea12
commit 8e4fad8969

View File

@ -203,6 +203,12 @@ module SharedEnvExtension
end
def fortran
# Ignore repeated calls to this function as it will misleadingly warn about
# building with an alternative Fortran compiler without optimization flags,
# despite it often being the Homebrew-provided one set up in the first call.
return if @fortran_setup_done
@fortran_setup_done = true
flags = []
if fc