diff options
| author | Mike McQuaid | 2016-07-16 21:01:22 +0100 |
|---|---|---|
| committer | Mike McQuaid | 2016-07-27 15:05:42 -0600 |
| commit | 012fc4709ab2e0189a39a41a5c47e832e037bfb1 (patch) | |
| tree | 0447008903b5393290c6f29226ae4d9967b0f332 /Library/Homebrew/extend/os/mac/development_tools.rb | |
| parent | c86c600bfd6c5a86eff5fe97ed96fd28fd131fbb (diff) | |
| download | brew-012fc4709ab2e0189a39a41a5c47e832e037bfb1.tar.bz2 | |
development_tools: add install instruction helpers.
Diffstat (limited to 'Library/Homebrew/extend/os/mac/development_tools.rb')
| -rw-r--r-- | Library/Homebrew/extend/os/mac/development_tools.rb | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/Library/Homebrew/extend/os/mac/development_tools.rb b/Library/Homebrew/extend/os/mac/development_tools.rb index d572bf28e..25235e4ae 100644 --- a/Library/Homebrew/extend/os/mac/development_tools.rb +++ b/Library/Homebrew/extend/os/mac/development_tools.rb @@ -22,6 +22,44 @@ class DevelopmentTools MacOS::Xcode.installed? || MacOS::CLT.installed? end + def installation_instructions + if MacOS.version >= "10.9" + <<-EOS.undent + Install the Command Line Tools: + xcode-select --install + EOS + elsif MacOS.version == "10.8" || MacOS.version == "10.7" + <<-EOS.undent + Install the Command Line Tools from + https://developer.apple.com/downloads/ + or via Xcode's preferences. + EOS + else + <<-EOS.undent + Install Xcode from + https://developer.apple.com/xcode/downloads/ + EOS + end + end + + def custom_installation_instructions + if MacOS.version > :tiger + <<-EOS.undent + Install GNU's GCC + brew install gcc + EOS + else + # Tiger doesn't ship with apple-gcc42, and this is required to build + # some software that doesn't build properly with FSF GCC. + <<-EOS.undent + Install Apple's GCC + brew install apple-gcc42 + or GNU's GCC + brew install gcc + EOS + end + end + def default_compiler case default_cc # if GCC 4.2 is installed, e.g. via Tigerbrew, prefer it |
