diff options
| author | Max Howell | 2011-08-31 16:59:04 +0100 |
|---|---|---|
| committer | Max Howell | 2011-08-31 17:36:41 +0100 |
| commit | a32e738f7c77a45a42572ca9efc215d1fd1e1519 (patch) | |
| tree | b22fb35bf346afff1c992fada364e570e57ddcae /Library/Homebrew/utils.rb | |
| parent | cf1a6e185c7ce3c02c676590efb49a43063e9aa1 (diff) | |
| download | brew-a32e738f7c77a45a42572ca9efc215d1fd1e1519.tar.bz2 | |
Default to LLVM for Xcodes that default to LLVM
Diffstat (limited to 'Library/Homebrew/utils.rb')
| -rw-r--r-- | Library/Homebrew/utils.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/Library/Homebrew/utils.rb b/Library/Homebrew/utils.rb index 08e6c5264..2a5a3a178 100644 --- a/Library/Homebrew/utils.rb +++ b/Library/Homebrew/utils.rb @@ -246,6 +246,14 @@ module MacOS extend self Pathname.new("/usr/bin/cc").realpath.basename.to_s end + def default_compiler + case default_cc + when /^gcc/ then :gcc + when /^llvm/ then :llvm + when "clang" then :clang + end + end + def gcc_42_build_version `/usr/bin/gcc-4.2 -v 2>&1` =~ /build (\d{4,})/ if $1 |
