diff options
| author | Misty De Meo | 2012-06-25 15:52:14 -0500 |
|---|---|---|
| committer | Misty De Meo | 2012-06-25 15:52:40 -0500 |
| commit | cd34b164b2ca1b55769b782f7b5f9e4f7ea5c710 (patch) | |
| tree | eac38471b9612b4ecdf71ac6491ccee2899e63d9 | |
| parent | 31d152780b9f1b7e80471cf1304c9760c852b6a5 (diff) | |
| download | brew-cd34b164b2ca1b55769b782f7b5f9e4f7ea5c710.tar.bz2 | |
MacOS.sdk_path: make sure xcode-select is sane
According to a user on IRC with a brand-new Mac, xcode-select is preconfigured
to /Developer out of the box even though that doesn't exist on modern Xcode.
So we shouldn't trust that it makes any sense.
| -rw-r--r-- | Library/Homebrew/utils.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Library/Homebrew/utils.rb b/Library/Homebrew/utils.rb index 728fa4e14..9fa97b49a 100644 --- a/Library/Homebrew/utils.rb +++ b/Library/Homebrew/utils.rb @@ -361,7 +361,7 @@ module MacOS extend self def sdk_path(v=MacOS.version) # The path of the MacOSX SDK. - if not MacOS.xctools_fucked? + if !MacOS.xctools_fucked? and File.directory? `xcode-select -print-path`.chomp path = `#{locate('xcodebuild')} -version -sdk macosx#{v} Path 2>/dev/null`.chomp.chomp elsif File.directory? '/Developer/SDKs/MacOS#{v}.sdk' # the old default (or wild wild west style) |
