aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/formula.rb
diff options
context:
space:
mode:
Diffstat (limited to 'Library/Homebrew/formula.rb')
-rw-r--r--Library/Homebrew/formula.rb7
1 files changed, 6 insertions, 1 deletions
diff --git a/Library/Homebrew/formula.rb b/Library/Homebrew/formula.rb
index bbcb1dab2..29e87af06 100644
--- a/Library/Homebrew/formula.rb
+++ b/Library/Homebrew/formula.rb
@@ -212,7 +212,12 @@ class Formula
def fails_with? cc
cc = Compiler.new(cc) unless cc.is_a? Compiler
(self.class.cc_failures || []).any? do |failure|
- failure.compiler == cc.name && failure.build >= cc.build
+ if cc.version
+ # non-Apple GCCs don't have builds, just version numbers
+ failure.compiler == cc.name && failure.version >= cc.version
+ else
+ failure.compiler == cc.name && failure.build >= cc.build
+ end
end
end