我该如何解决啤酒医生的错误? [英] How do I fix brew doctor errors?

查看:59
本文介绍了我该如何解决啤酒医生的错误?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在这方面我是个新手,所以请原谅我的无能.

当我运行brew Doctor时,我得到以下信息.有人可以帮忙吗?

 <代码> [/usr/local] $ brew医生错误:设置DYLD_LIBRARY_PATH可能会中断动态链接.您可能应该取消设置.错误:一些仅桶装的公式已链接到地窖中.通过以下方式将仅桶式的公式(例如gettext)链接到地窖中酿造链接f会导致其他公式在./configure步骤.编译这些文件时可能会导致问题其他公式.仅桶式公式提供的二进制文件可能会覆盖系统二进制文件与其他奇怪的结果.您可能希望冲泡取消以下冲泡的链接:libxml2错误:在/usr/local/lib中发现了未酿酒的dylib.如果您不故意将它们放在那儿,它们可能会在出现问题时引起问题建立Homebrew公式,可能需要删除.意外的dylib:/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错误:在/usr/local/lib中找到未酿酒的.la文件.如果您不故意将它们放在那儿,它们可能会在出现问题时引起问题建立Homebrew公式,可能需要删除.意外的.la文件:/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错误:在/usr/local/lib/pkgconfig中找到未酿酒的.pc文件.如果您不故意将它们放在那儿,它们可能会在出现问题时引起问题建立Homebrew公式,可能需要删除.意外的.pc文件:/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错误:在/usr/local/lib中发现了未压缩的静态库.如果您不故意将它们放在那儿,它们可能会在出现问题时引起问题建立Homebrew公式,可能需要删除.意外的静态库:/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错误:您尚未对Homebrew的核心进行修改.除非您知道自己在做什么,否则应该运行:光盘/usr/local&&git reset --hard错误:路径中的某些目录以斜杠结尾.您路径中的目录不应以斜线结尾.这可能会破坏其他医生检查.应编辑以下目录:/usr/local/git/bin/[/usr/local] $ 

解决方案

 错误:设置DYLD_LIBRARY_PATH可能会中断动态链接.您可能应该取消设置.错误:一些仅桶装的公式已链接到地窖中.通过酿造链接f将只有桶的公式(例如gettext)链接到地窖中,将导致其他公式在./configure步骤中检测到它们.编译其他公式时,这可能会引起问题.仅桶式公式提供的二进制文件可能会用其他奇怪的结果覆盖系统二进制文件. 

这是要您取消设置动态加载库路径.您可以通过找出它的设置位置并将其删除来做到这一点.很可能,您的〜/.bashrc或〜/.bash_profile中有一行看起来像 export DYLD_LIBRARY_PATH =/some/path:$ DYLD_LIBRARY_PATH

 您可能希望冲泡断开这些冲泡的链接:libxml2 

当Brew链接时,它会创建一个指向安装的符号链接.这就是您拥有python2.6的方式.已安装python2.7,但 python 将运行其中之一.

酿造取消链接libxml2

 错误:在/usr/local/lib中发现了未酿酒的dylib.如果您没有故意将它们放在此处,则它们在构建Homebrew公式时可能会引起问题,并且可能需要删除.意外的dylib:/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错误:未酿酒的.la在/usr/local/lib中找到文件.如果您没有故意将它们放在此处,则它们在构建Homebrew公式时可能会引起问题,并且可能需要删除.意外的.la文件:/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错误:在/usr/local/lib/pkgconfig中找到未酿酒的.pc文件.如果您没有故意将它们放在此处,则它们在构建Homebrew公式时可能会引起问题,并且可能需要删除.意外的.pc文件:/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错误:在/usr/中找到未开发的静态库本地/lib.如果您没有故意将它们放在此处,则它们在构建Homebrew公式时可能会引起问题,并且可能需要删除.意外的静态库:/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

 错误:您尚未提交对Homebrew核心的修改.除非您知道自己在做什么,否则应该运行:cd/usr/local&&git reset --hard 

在这里,它告诉您您对Homebrew文件进行了修改.幸运的是,Homebrew存储在Git版本控制中,因此您可以还原这些更改.

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

 错误:路径中的某些目录以斜杠结尾.您路径中的目录不应以斜线结尾.这可能会破坏其他医生的检查.应编辑以下目录:/usr/local/git/bin/ 

当在命令行中键入PATH变量时,计算机将在其中搜索程序.您可以使用 echo $ PATH 查看路径.

标准规定PATH中的所有路径都不应以斜杠结尾.因此,自制软件要求您修复它.

nano〜/.bashrc nano〜/.bash_profile 并查找'/usr/local/git/bin/'并删除斜杠.

I'm very much a newbie when it comes to all this so forgive my incompetence.

When I run brew Doctor, I get the following. Can someone help?

[/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.

This is asking you to unset your Dynamic Loading Library Path. You can do this by finding out where you set it and removing it. Most likely, you have a line in your ~/.bashrc or ~/.bash_profile that looks like export DYLD_LIBRARY_PATH=/some/path:$DYLD_LIBRARY_PATH

You may wish to brew unlink these brews:

libxml2

When Brew links, it's creating a symlink to the installation. It's how you can have python2.6. python2.7 installed but python will run one of them.

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 

These are residual files from other installations. You can delete them.

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 

Here, it is telling you that you made modifications to Homebrew files. Luckily, Homebrew is stored in Git version control so you can revert those changes.

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/ 

The PATH variable is where your computer searches for programs when you type it in the command line. You can see your path with echo $PATH.

Standards dictate that all the paths in PATH should not end in a slash. Thus, homebrew is asking you to fix it.

nano ~/.bashrc or nano ~/.bash_profile and look for '/usr/local/git/bin/' and remove the trailing slash.

这篇关于我该如何解决啤酒医生的错误?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆