diff options
| author | Adam Vandenberg | 2010-04-03 09:43:17 -0700 |
|---|---|---|
| committer | Adam Vandenberg | 2010-04-06 08:22:29 -0700 |
| commit | 3154b1f60b4ae02b6d0ce70938d720394c93c6e6 (patch) | |
| tree | a6d90e26f516b10d4cd31ce5d3c929773866c8b7 /Library | |
| parent | 39ed52eba570cd2072065ad5c027e4a5fb4b7f9a (diff) | |
| download | homebrew-3154b1f60b4ae02b6d0ce70938d720394c93c6e6.tar.bz2 | |
Add pkg-config check.
Diffstat (limited to 'Library')
| -rw-r--r-- | Library/Homebrew/brew_doctor.rb | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/Library/Homebrew/brew_doctor.rb b/Library/Homebrew/brew_doctor.rb index 4e9edd52b..bf4907cf3 100644 --- a/Library/Homebrew/brew_doctor.rb +++ b/Library/Homebrew/brew_doctor.rb @@ -141,6 +141,21 @@ def check_user_path end end +def check_pkg_config + binary = `which pkg-config`.chomp + return if binary.empty? + + unless binary == "#{HOMEBREW_PREFIX}/bin/pkg-config" + puts <<-EOS.undent + You have a non-brew 'pkg-config' in your PATH: + #{binary} + + `./configure` may have problems finding brew-installed packages using + this other pkg-config. + EOS + end +end + def brew_doctor read, write = IO.pipe @@ -156,6 +171,7 @@ def brew_doctor check_for_x11 check_share_locale check_user_path + check_pkg_config exit! 0 else |
