aboutsummaryrefslogtreecommitdiffstats
path: root/Library
diff options
context:
space:
mode:
Diffstat (limited to 'Library')
-rw-r--r--Library/Homebrew/cmd/doctor.rb14
-rw-r--r--Library/Homebrew/cmd/install.rb1
2 files changed, 15 insertions, 0 deletions
diff --git a/Library/Homebrew/cmd/doctor.rb b/Library/Homebrew/cmd/doctor.rb
index 3bd5d4d98..94304b372 100644
--- a/Library/Homebrew/cmd/doctor.rb
+++ b/Library/Homebrew/cmd/doctor.rb
@@ -312,6 +312,20 @@ def check_for_stray_developer_directory
end
end
+def check_for_bad_install_name_tool
+ return if MacOS.version < 10.9
+
+ libs = `otool -L /usr/bin/install_name_tool`
+ unless libs.include? "/usr/lib/libxcselect.dylib" then <<-EOS.undent
+ You have an outdated version of /usr/bin/install_name_tool installed.
+ This will cause binary package installations to fail.
+ This can happen if you install osx-gcc-installer or RailsInstaller.
+ To restore it, you must reinstall OS X or restore the binary from
+ the OS packages.
+ EOS
+ end
+end
+
def __check_subdir_access base
target = HOMEBREW_PREFIX+base
return unless target.exist?
diff --git a/Library/Homebrew/cmd/install.rb b/Library/Homebrew/cmd/install.rb
index cf652b17a..55385154d 100644
--- a/Library/Homebrew/cmd/install.rb
+++ b/Library/Homebrew/cmd/install.rb
@@ -55,6 +55,7 @@ module Homebrew extend self
check_for_installed_developer_tools
check_xcode_license_approved
check_for_osx_gcc_installer
+ check_for_bad_install_name_tool
].each do |check|
out = checks.send(check)
opoo out unless out.nil?