Make MPIRequirement satisfied on Xcode-only Macs
Closes Homebrew/homebrew#16409. Signed-off-by: Jack Nagel <jacknagel@gmail.com>
This commit is contained in:
parent
951620f146
commit
4291bc29db
@ -124,6 +124,11 @@ class MPIDependency < Requirement
|
|||||||
end
|
end
|
||||||
|
|
||||||
def satisfied?
|
def satisfied?
|
||||||
|
# we have to assure the ENV is (almost) as during the build
|
||||||
|
orig_PATH = ENV['PATH']
|
||||||
|
require 'superenv'
|
||||||
|
ENV.setup_build_environment
|
||||||
|
ENV.userpaths!
|
||||||
@lang_list.each do |lang|
|
@lang_list.each do |lang|
|
||||||
case lang
|
case lang
|
||||||
when :cc, :cxx, :f90, :f77
|
when :cc, :cxx, :f90, :f77
|
||||||
@ -134,6 +139,9 @@ class MPIDependency < Requirement
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# Restore the original paths
|
||||||
|
ENV['PATH'] = orig_PATH
|
||||||
|
|
||||||
@unknown_langs.empty? and @non_functional.empty?
|
@unknown_langs.empty? and @non_functional.empty?
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user