gpt4 book ai didi

ruby - jekyll 服务依赖错误 - 无法打开 'lib curl'

转载 作者:数据小太阳 更新时间:2023-10-29 08:25:58 25 4
gpt4 key购买 nike

我正在尝试运行 bundle exec jekyll serve 但出现错误:

依赖错误:哎呀!看起来您没有安装 jekyll-remote-theme 或其依赖项之一。为了按照当前配置使用 Jekyll,您需要安装这个 gem。来自 Ruby 的完整错误消息是:'无法打开库'libcurl':找不到指定的模块。 .无法打开库“libcurl.dll”:找不到指定的模块。 .无法打开库“libcurl.so.4”:找不到指定的模块。 .无法打开库“libcurl.so.4.dll”:找不到指定的模块。 ' 如果遇到麻烦,可以在 https://jekyllrb.com/help/找到有用的资源!
杰基尔 3.6.2 |错误:jekyll-remote-theme

所以我检查了是否安装了 curl:

$ curl --version
curl 7.50.1 (x86_64-w64-mingw32) libcurl/7.50.1 OpenSSL/1.0.2h zlib/1.2.8 libidn/1.33 libssh2/1.7.0 nghttp2/1.13.0 librtmp/2.3
协议(protocol): dict file ftp ftps gopher http https imap imaps ldap ldaps pop3 pop3s rtmp rtsp scp sftp smtp smtps telnet tftp
特性:IDN IPv6 大文件 SSPI Kerberos SPNEGO NTLM SSL libz TLS-SRP HTTP2 Metalink

我搜索过类似的问题,但解决方案似乎与我的问题无关。我是 Jekyll 和 Ruby 的新手,我只是想能够离线查看我的 Github 页面。

我使用的是 Windows 7 64 位。如有任何建议,我们将不胜感激!

最佳答案

这是对我有用的:

(链接已更新,但最初指向版本 7.40)

  • 以某种方式将它放在 PATH 上。
    • (我只是放在\ruby24\bin\下)
    • 也许对您来说是 C:\Ruby24-x64\bin,这是其他人建议的。

关于问题

  • 似乎来自 Ruby-FFI。 ( as described here )

  • 我在 jekyll-remote-theme 的依赖项上遇到了同样的错误。

    (One of them is typhoeus 使用 FFI。)

  • 此外,执行 github-pages health-check 显示此错误:

    ffi-1.9.18-x64-mingw32/lib/ffi/library.rb:147:in `block in ffi_lib': Could not 
open libra (LoadError): The specified module could not be found.
Could not open library 'libcurl.dll': The specified module could not be found.
Could not open library 'libcurl.so.4': The specified module could not be
found.
Could not open library 'libcurl.so.4.dll': The specified module could not be
found.

我尝试过但不起作用的方法:

  • 将从当前 Curl Download Wizard 获得的 cygcurl-4.dll 放在 PATH 中
  • 将上面的cygcurl-4.dll重命名为libcurl.dll并将其放入PATH
  • 正在安装 msys2libcurl-devel 7.57.0-1
  • msys-curl-4.dll(来自 msys64\usr\bin 中的 msys2)重命名为 libcurl。 dll

没有尝试:

  • 从最新源构建 curl/libcurl。因为根据 pacman -Ss libcurl 我已经有了最新的:

    msys/libcurl 7.57.0-1(库)[已安装] 多协议(protocol)文件传输库(运行时)

    msys/libcurl-devel 7.57.0-1(开发)[已安装] Libcurl header 和库

关于ruby - jekyll 服务依赖错误 - 无法打开 'lib curl',我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/47720302/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com