From e65c3a71eb4382a8fc42d6a6f78122bf310b469e Mon Sep 17 00:00:00 2001 From: Jack Nagel Date: Tue, 12 Jun 2012 00:27:19 -0500 Subject: [PATCH] Update doctor checks for XQuartz - pkg-config no longer defaults to checking /usr/X11/lib/pkgconfig; instead this path is added via ENV.x11 or depends_on :x11. Formulae that expect X11 libs should be explicitly marked as depends_on :x11. - Remove warning about /usr/X11 as a symlink. Signed-off-by: Jack Nagel --- Library/Homebrew/cmd/doctor.rb | 42 +++++----------------------------- 1 file changed, 6 insertions(+), 36 deletions(-) diff --git a/Library/Homebrew/cmd/doctor.rb b/Library/Homebrew/cmd/doctor.rb index 99cc096a23..f2f84b45fb 100644 --- a/Library/Homebrew/cmd/doctor.rb +++ b/Library/Homebrew/cmd/doctor.rb @@ -168,22 +168,12 @@ def check_for_stray_las end def check_for_x11 - unless x11_installed? - <<-EOS.undent - X11 not installed. - You don't have X11 installed as part of your OS X installation. - This is not required for all formulae, but is expected by some. - EOS - end -end - -def check_for_nonstandard_x11 - x11 = Pathname.new('/usr/X11') - if x11.symlink? - <<-EOS.undent - /usr/X11 is a symlink - Homebrew's X11 support has only be tested with Apple's X11. - In particular, "XQuartz" and "XDarwin" are not known to be compatible. + unless MacOS.x11_installed? then <<-EOS.undent + X11 is not installed. + You don't have X11 installed as part of your OS X installation. + This is not required for all formulae, but is expected by some. + You can download the latest version of XQuartz from: + https://xquartz.macosforge.org EOS end end @@ -501,26 +491,6 @@ def check_which_pkg_config end end -def check_pkg_config_paths - binary = which 'pkg-config' - return if binary.nil? - - pkg_config_paths = `pkg-config --variable pc_path pkg-config`.chomp.split(':') - - # Check that all expected paths are being searched - unless pkg_config_paths.include? "/usr/X11/lib/pkgconfig" - <<-EOS.undent - Your pkg-config is not checking "/usr/X11/lib/pkgconfig" for packages. - Earlier versions of the pkg-config formula did not add this path - to the search path, which means that other formula may not be able - to find certain dependencies. - - To resolve this issue, re-brew pkg-config with: - brew rm pkg-config && brew install pkg-config - EOS - end -end - def check_for_gettext if %w[lib/libgettextlib.dylib lib/libintl.dylib