XQuartz动态加载错误

发布于 2024-12-17 12:55:07 字数 611 浏览 3 评论 0原文

我更新了 XQuartz,现在它无法加载,并抱怨:

Dyld Error Message:
  Library not loaded: /opt/X11/lib/libfreetype.6.dylib
  Referenced from: /Applications/Utilities/XQuartz.app/Contents/MacOS/X11.bin
  Reason: Incompatible library version: X11.bin requires version 14.0.0 or later, but libfreetype.6.dylib provides version 13.0.0

但是,如果我 otool -L /opt/X11/lib/libfreetype.6.dylib

/opt/X11/lib/libfreetype.6.dylib:
    /opt/X11/lib/libfreetype.6.dylib (compatibility version 14.0.0, current version 14.2.0)
    ...

那么该库是正确的版本!

什么可能导致此错误?

I updated XQuartz, and now it doesn't load, complaining that:

Dyld Error Message:
  Library not loaded: /opt/X11/lib/libfreetype.6.dylib
  Referenced from: /Applications/Utilities/XQuartz.app/Contents/MacOS/X11.bin
  Reason: Incompatible library version: X11.bin requires version 14.0.0 or later, but libfreetype.6.dylib provides version 13.0.0

However, if I otool -L /opt/X11/lib/libfreetype.6.dylib:

/opt/X11/lib/libfreetype.6.dylib:
    /opt/X11/lib/libfreetype.6.dylib (compatibility version 14.0.0, current version 14.2.0)
    ...

So the library is the right version!

What could cause this error?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

彻夜缠绵 2024-12-24 12:55:07

此类错误是由用户在其环境中设置 DYLD_LIBRARY_PATH 引起的。这可能在 /etc/launchd.conf、/etc/profile、/etc/bashrc、~/.profile、~/.bashrc、~/.bash_profile 或类似文件中完成。

DYLD_LIBRARY_PATH 包含一个目录,其中包含名为 libfreetype.6.dylib 的文件,该文件用于代替 XQuartz 中包含的文件。

无论是谁建议您设置 DYLD_LIBRARY_PATH ,都可能是错误的。它应该只在非常特殊的情况下使用,例如在开发环境中。它几乎不应该在运输产品中使用,也不应该在 shell 环境中设置为一般解决方法。

Errors like this are caused by users setting DYLD_LIBRARY_PATH in their environment. This is likely done in either /etc/launchd.conf, /etc/profile, /etc/bashrc, ~/.profile, ~/.bashrc, ~/.bash_profile, or similar.

DYLD_LIBRARY_PATH included a directory that contained a file named libfreetype.6.dylib which was used instead of the one included with XQuartz.

Whoever gave you the recommendation to set DYLD_LIBRARY_PATH likely did so in error. It should only be used in very specific cases, such as in development environments. It should almost never be used in shipping products and never set as a general workaround in your shell environment.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文