Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Brew doctor gives out warnings

Tags:

homebrew

when I ran brew doctor I go loads of warnings. So I went ahead, cleaned out the existing installation and did it from scratch.

Now I still get some warnings:

    Warning: "config" scripts exist outside your system or Homebrew directories.
`./configure` scripts often look for *-config scripts to determine if
software packages are installed, and what additional flags to use when
compiling and linking.

Having additional scripts in your path can confuse software installed via
Homebrew if the config script overrides a system or Homebrew provided
script of the same name. We found the following "config" scripts:

    /opt/sm/pkg/active/bin/curl-config
    /opt/sm/pkg/active/bin/ncurses5-config
    /opt/sm/pkg/active/bin/ncursesw5-config
    /opt/sm/pkg/active/bin/pkg-config
    /opt/sm/pkg/active/bin/xml2-config
    /opt/sm/pkg/active/bin/xslt-config
Warning: You have a non-Homebrew 'pkg-config' in your PATH:
  /opt/sm/pkg/active/bin/pkg-config

`./configure` may have problems finding brew-installed packages using
this other pkg-config.

But since I only started using OS X a few days ago, I am not sure if the mentioned config files are relevant or if I can just delete them? Have already been looking through forums for hours, but still none the wiser at the moment... Any advice is very much appreciated!

like image 714
Thomas Kuhlmann Avatar asked Mar 05 '13 13:03

Thomas Kuhlmann


2 Answers

Try taking /opt/sm/pkg/active/bin/ out of your PATH.

That will prevent the scripts installed in that directory from accidentally taking precedence over the ones installed by homebrew.

like image 158
Patrick Lewis Avatar answered Jan 04 '23 05:01

Patrick Lewis


If you're a newbie like me and want a more clear answer on exactly how to do this, I found this answer here How to change path for homebrew: "config" scripts exist outside your system or Homebrew directories and it worked for me:

The /opt/sm is in the /etc/profile.d directory. Open it by entering

cd /etc/profile.d in terminal and then

open .

Open sm.sh file in text editor and then comment out the path by putting a hash sign # in front of

PATH="${PATH}:/opt/sm/bin:/opt/sm/pkg/active/bin:/opt/sm/pkg/active/sbin"

Save the change in your text editor and then quit and relaunch Terminal. Run brew doctor 'Warning' should be gone.

like image 30
danisyellis Avatar answered Jan 04 '23 03:01

danisyellis