我如何解决brew医生的错误

说到这一切,我都是一个新手,所以原谅我的无能。

当我运行brew Doctor时,我得到以下结果。 有人可以帮忙吗?

[/usr/local]$ brew doctor Error: Setting DYLD_LIBRARY_PATH can break dynamic linking. You should probably unset it. Error: Some keg-only formula are linked into the Cellar. Linking a keg-only formula, such as gettext, into the cellar with brew link f will cause other formulae to detect them during the ./configure step. This may cause problems when compiling those other formulae. Binaries provided by keg-only formulae may override system binaries with other strange results. You may wish to brew unlink these brews: libxml2 Error: Unbrewed dylibs were found in /usr/local/lib. If you didn't put them there on purpose they could cause problems when building Homebrew formulae, and may need to be deleted. Unexpected dylibs: /usr/local/lib/libcharset.1.dylib /usr/local/lib/libfreetype.6.dylib /usr/local/lib/libjpeg.8.dylib /usr/local/lib/liblcms.1.0.19.dylib /usr/local/lib/libMagickCore.4.dylib /usr/local/lib/libMagickWand.4.dylib /usr/local/lib/libpng15.15.dylib /usr/local/lib/libtiff.3.dylib /usr/local/lib/libtiffxx.3.dylib /usr/local/lib/libwmf-0.2.7.1.0.dylib /usr/local/lib/libwmflite-0.2.7.0.1.dylib Error: Unbrewed .la files were found in /usr/local/lib. If you didn't put them there on purpose they could cause problems when building Homebrew formulae, and may need to be deleted. Unexpected .la files: /usr/local/lib/libcharset.la /usr/local/lib/libfreetype.la /usr/local/lib/libjpeg.la /usr/local/lib/liblcms.la /usr/local/lib/libMagickCore.la /usr/local/lib/libMagickWand.la /usr/local/lib/libpng15.la /usr/local/lib/libtiff.la /usr/local/lib/libtiffxx.la /usr/local/lib/libwmf.la /usr/local/lib/libwmflite.la Error: Unbrewed .pc files were found in /usr/local/lib/pkgconfig. If you didn't put them there on purpose they could cause problems when building Homebrew formulae, and may need to be deleted. Unexpected .pc files: /usr/local/lib/pkgconfig/freetype2.pc /usr/local/lib/pkgconfig/ImageMagick.pc /usr/local/lib/pkgconfig/lcms.pc /usr/local/lib/pkgconfig/libpng15.pc /usr/local/lib/pkgconfig/MagickCore.pc /usr/local/lib/pkgconfig/MagickWand.pc /usr/local/lib/pkgconfig/Wand.pc Error: Unbrewed static libraries were found in /usr/local/lib. If you didn't put them there on purpose they could cause problems when building Homebrew formulae, and may need to be deleted. Unexpected static libraries: /usr/local/lib/libcharset.a /usr/local/lib/libfreetype.a /usr/local/lib/libjpeg.a /usr/local/lib/liblcms.a /usr/local/lib/libpng15.a /usr/local/lib/libtiff.a /usr/local/lib/libtiffxx.a /usr/local/lib/libwmf.a /usr/local/lib/libwmflite.a Error: You have uncommitted modifications to Homebrew's core. Unless you know what you are doing, you should run: cd /usr/local && git reset --hard Error: Some directories in your path end in a slash. Directories in your path should not end in a slash. This can break other doctor checks. The following directories should be edited: /usr/local/git/bin/ [/usr/local]$ 
 Error: Setting DYLD_LIBRARY_PATH can break dynamic linking. You should probably unset it. Error: Some keg-only formula are linked into the Cellar. Linking a keg-only formula, such as gettext, into the cellar with brew link f will cause other formulae to detect them during the ./configure step. This may cause problems when compiling those other formulae. Binaries provided by keg-only formulae may override system binaries with other strange results. 

这是要求您取消您的dynamic加载库path。 您可以通过找出您设置的位置并将其删除来做到这一点。 最有可能的是,在〜/ .bashrc或〜/ .bash_profile中有一行,如export DYLD_LIBRARY_PATH=/some/path:$DYLD_LIBRARY_PATH

 You may wish to brew unlink these brews: libxml2 

当Brew链接时,它创build一个符号链接到安装。 这是如何你可以有python2.6。 python2.7安装,但python将运行其中之一。

brew unlink libxml2

 Error: Unbrewed dylibs were found in /usr/local/lib. If you didn't put them there on purpose they could cause problems when building Homebrew formulae, and may need to be deleted. Unexpected dylibs: /usr/local/lib/libcharset.1.dylib /usr/local/lib/libfreetype.6.dylib /usr/local/lib/libjpeg.8.dylib /usr/local/lib/liblcms.1.0.19.dylib /usr/local/lib/libMagickCore.4.dylib /usr/local/lib/libMagickWand.4.dylib /usr/local/lib/libpng15.15.dylib /usr/local/lib/libtiff.3.dylib /usr/local/lib/libtiffxx.3.dylib /usr/local/lib/libwmf-0.2.7.1.0.dylib /usr/local/lib/libwmflite-0.2.7.0.1.dylib Error: Unbrewed .la files were found in /usr/local/lib. If you didn't put them there on purpose they could cause problems when building Homebrew formulae, and may need to be deleted. Unexpected .la files: /usr/local/lib/libcharset.la /usr/local/lib/libfreetype.la /usr/local/lib/libjpeg.la /usr/local/lib/liblcms.la /usr/local/lib/libMagickCore.la /usr/local/lib/libMagickWand.la /usr/local/lib/libpng15.la /usr/local/lib/libtiff.la /usr/local/lib/libtiffxx.la /usr/local/lib/libwmf.la /usr/local/lib/libwmflite.la Error: Unbrewed .pc files were found in /usr/local/lib/pkgconfig. If you didn't put them there on purpose they could cause problems when building Homebrew formulae, and may need to be deleted. Unexpected .pc files: /usr/local/lib/pkgconfig/freetype2.pc /usr/local/lib/pkgconfig/ImageMagick.pc /usr/local/lib/pkgconfig/lcms.pc /usr/local/lib/pkgconfig/libpng15.pc /usr/local/lib/pkgconfig/MagickCore.pc /usr/local/lib/pkgconfig/MagickWand.pc /usr/local/lib/pkgconfig/Wand.pc Error: Unbrewed static libraries were found in /usr/local/lib. If you didn't put them there on purpose they could cause problems when building Homebrew formulae, and may need to be deleted. Unexpected static libraries: /usr/local/lib/libcharset.a /usr/local/lib/libfreetype.a /usr/local/lib/libjpeg.a /usr/local/lib/liblcms.a /usr/local/lib/libpng15.a /usr/local/lib/libtiff.a /usr/local/lib/libtiffxx.a /usr/local/lib/libwmf.a /usr/local/lib/libwmflite.a 

这些是来自其他安装的残留文件。 你可以删除它们。

rm FILENAME

 Error: You have uncommitted modifications to Homebrew's core. Unless you know what you are doing, you should run: cd /usr/local && git reset --hard 

在这里,它告诉你,你做了自制文件的修改。 幸运的是,Homebrew存储在Git版本控制中,所以你可以恢复这些变化。

cd /usr/local && git reset --hard

 Error: Some directories in your path end in a slash. Directories in your path should not end in a slash. This can break other doctor checks. The following directories should be edited: /usr/local/git/bin/ 

PATHvariables是您的计算机在命令行中键入时search程序的位置。 你可以用echo $PATH看到你的path。

标准规定PATH中的所有path不应以斜线结尾。 因此,自制软件正在要求你解决这个问题。

nano ~/.bashrcnano ~/.bash_profile然后查找'/ usr / local / git / bin /'并删除结尾的斜杠。

我也是新来酿造的。 当我第一次尝试的时候,我收到了一大堆错误。 并不是所有的东西都需要固定,因为我需要它来使用酿造。 特别是我能够忽略这个

 Unbrewed * were found in /usr/local/lib 

我得到的消息。 我相信这只是一个问题,当你使用brew安装的软件包会干扰你以前安装的软件(在我的情况下,这是NTFS-3g,与我未来酿造的用途无关)。