薄(红宝石)正在呕吐

发布于 2024-08-12 15:04:08 字数 761 浏览 1 评论 0原文

简单的 sinatra 应用程序:

require 'rubygems'
require 'sinatra'

get '/' do
  "Hey"
end

然后:

$ ruby test.rb

当我点击 http://localhost:4567 时,它会断开连接,我得到:

/usr/local/lib/ruby/gems/1.8/gems/thin-1.2.5/lib/thin_parser.bundle: dlopen(/usr/local/lib/ruby/gems/1.8/gems/thin-1.2.5/lib/thin_parser.bundle, 9): no suitable image found.  Did find: (LoadError)
/usr/local/lib/ruby/gems/1.8/gems/thin-1.2.5/lib/thin_parser.bundle: unknown required load command 0x80000022 - /usr/local/lib/ruby/gems/1.8/gems/thin-1.2.5/lib/thin_parser.bundle

所有宝石都是最新的。我正在运行 ruby​​ 1.8.7 (2008-08-11 patchlevel 72) [i686-darwin9.6.0]

Simple sinatra app:

require 'rubygems'
require 'sinatra'

get '/' do
  "Hey"
end

Then:

$ ruby test.rb

And when I hit http://localhost:4567, it drops the connection and I get:

/usr/local/lib/ruby/gems/1.8/gems/thin-1.2.5/lib/thin_parser.bundle: dlopen(/usr/local/lib/ruby/gems/1.8/gems/thin-1.2.5/lib/thin_parser.bundle, 9): no suitable image found.  Did find: (LoadError)
/usr/local/lib/ruby/gems/1.8/gems/thin-1.2.5/lib/thin_parser.bundle: unknown required load command 0x80000022 - /usr/local/lib/ruby/gems/1.8/gems/thin-1.2.5/lib/thin_parser.bundle

All gems are up-to-date. I am running ruby 1.8.7 (2008-08-11 patchlevel 72) [i686-darwin9.6.0]

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

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

发布评论

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

评论(1

深海蓝天 2024-08-19 15:04:08

我怀疑 Thin 被编译为 32 位模块,并且您正在使用 x86_64 Ruby (或相反)

I suspect that Thin is compiled as a 32-bit module and you're using x86_64 Ruby (or the other way around)

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