aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/utils.rb
diff options
context:
space:
mode:
Diffstat (limited to 'Library/Homebrew/utils.rb')
-rw-r--r--Library/Homebrew/utils.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/Library/Homebrew/utils.rb b/Library/Homebrew/utils.rb
index adf9c8d10..71317a8ef 100644
--- a/Library/Homebrew/utils.rb
+++ b/Library/Homebrew/utils.rb
@@ -264,7 +264,8 @@ module MacOS extend self
end
def gcc_42_build_version
- @gcc_42_build_version ||= if File.exist? "/usr/bin/gcc-4.2"
+ @gcc_42_build_version ||= if File.exist? "/usr/bin/gcc-4.2" \
+ and not Pathname.new("/usr/bin/gcc-4.2").realpath.basename.to_s =~ /^llvm/
`/usr/bin/gcc-4.2 --version` =~ /build (\d{4,})/
$1.to_i
end