ENV.fortran adds back superenv removed PATHs
Fixes Homebrew/homebrew#15103.
This commit is contained in:
parent
382fa27520
commit
b94e220bc3
@ -446,6 +446,10 @@ class << ENV
|
|||||||
def fortran
|
def fortran
|
||||||
fc_flag_vars = %w{FCFLAGS FFLAGS}
|
fc_flag_vars = %w{FCFLAGS FFLAGS}
|
||||||
|
|
||||||
|
# superenv removes these PATHs, but this option needs them
|
||||||
|
# TODO fix better, probably by making a super-fc
|
||||||
|
ENV['PATH'] += ":#{HOMEBREW_PREFIX}/bin:/usr/local/bin"
|
||||||
|
|
||||||
if self['FC']
|
if self['FC']
|
||||||
ohai "Building with an alternative Fortran compiler. This is unsupported."
|
ohai "Building with an alternative Fortran compiler. This is unsupported."
|
||||||
self['F77'] = self['FC'] unless self['F77']
|
self['F77'] = self['FC'] unless self['F77']
|
||||||
@ -470,7 +474,7 @@ class << ENV
|
|||||||
EOS
|
EOS
|
||||||
end
|
end
|
||||||
|
|
||||||
elsif `/usr/bin/which gfortran`.chomp.size > 0
|
elsif `/usr/bin/which gfortran`.chuzzle
|
||||||
ohai <<-EOS.undent
|
ohai <<-EOS.undent
|
||||||
Using Homebrew-provided fortran compiler.
|
Using Homebrew-provided fortran compiler.
|
||||||
This may be changed by setting the FC environment variable.
|
This may be changed by setting the FC environment variable.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user