无法运行Python3.8.9作为Bazel建立在Apple-M1上的一部分

发布于 2025-01-20 22:01:33 字数 1491 浏览 3 评论 0原文

bazel installs /private/var/tmp/_bazel_user/a8b53c99106043b42ff3e67372f6598e/external/pbpy_sc.3.8.9/python-sc.3.8.9_dist/bin/python3 and fails to run it during the build with the following错误:

dyld[60500]: Library not loaded: /usr/local/opt/gettext/lib/libintl.8.dylib
  Referenced from: /private/var/tmp/_bazel_user/a8b53c99106043b42ff3e67372f6598e/external/pbpy_sc.3.8.9/python-sc.3.8.9_dist/bin/python3

  Reason: tried: '/usr/local/opt/gettext/lib/libintl.8.dylib' (no such file), '/usr/local/lib/libintl.8.dylib' (no such file), '/usr/lib/libintl.8.dylib' (no such file)

otool出于某种原因,Python3取决于getText

$ otool -L /private/var/tmp/_bazel_user/a8b53c99106043b42ff3e67372f6598e/external/pbpy_sc.3.8.9/python-sc.3.8.9_dist/bin/python3
/private/var/tmp/_bazel_user/a8b53c99106043b42ff3e67372f6598e/external/pbpy_sc.3.8.9/python-sc.3.8.9_dist/bin/python3:
    /System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation (compatibility version 150.0.0, current version 1770.255.0)
    /usr/local/opt/gettext/lib/libintl.8.dylib (compatibility version 11.0.0, current version 11.0.0)
    /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1292.60.1)
    /usr/lib/libncurses.5.4.dylib (compatibility version 5.4.0, current version 5.4.0)

libintl.8.dylib /opt/opt/local/lib/code>中,但不是python在哪里看的地方?

bazel installs /private/var/tmp/_bazel_user/a8b53c99106043b42ff3e67372f6598e/external/pbpy_sc.3.8.9/python-sc.3.8.9_dist/bin/python3 and fails to run it during the build with the following error:

dyld[60500]: Library not loaded: /usr/local/opt/gettext/lib/libintl.8.dylib
  Referenced from: /private/var/tmp/_bazel_user/a8b53c99106043b42ff3e67372f6598e/external/pbpy_sc.3.8.9/python-sc.3.8.9_dist/bin/python3

  Reason: tried: '/usr/local/opt/gettext/lib/libintl.8.dylib' (no such file), '/usr/local/lib/libintl.8.dylib' (no such file), '/usr/lib/libintl.8.dylib' (no such file)

otool shows that python3 depends on gettext for some reason.

$ otool -L /private/var/tmp/_bazel_user/a8b53c99106043b42ff3e67372f6598e/external/pbpy_sc.3.8.9/python-sc.3.8.9_dist/bin/python3
/private/var/tmp/_bazel_user/a8b53c99106043b42ff3e67372f6598e/external/pbpy_sc.3.8.9/python-sc.3.8.9_dist/bin/python3:
    /System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation (compatibility version 150.0.0, current version 1770.255.0)
    /usr/local/opt/gettext/lib/libintl.8.dylib (compatibility version 11.0.0, current version 11.0.0)
    /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1292.60.1)
    /usr/lib/libncurses.5.4.dylib (compatibility version 5.4.0, current version 5.4.0)

There is libintl.8.dylib in /opt/local/lib/ but not where python is looking at?

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

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

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文