ruby 在 OS X 10.6 上找不到 readline

发布于 2024-10-26 00:59:18 字数 688 浏览 0 评论 0原文

我在 OS X 10.6 上运行 ruby​​ 1.9.2,大多数情况都工作正常。但 readline 似乎不起作用,无论是在 IRB 还是在 Rails 控制台中。一些不同的帖子建议将 readline 构建为扩展,就像这样

cd <ruby-source-dir>/ext/readline
ruby extconf.rb
make
make install

所以我这样做了,这就是我得到的:

checking for tgetnum() in -lncurses... yes
checking for readline/readline.h... yes
checking for readline/history.h... yes
checking for readline() in -lreadline... no
checking for readline() in -ledit... no
checking for editline/readline.h... yes
checking for readline() in -ledit... no

然后

make: Nothing to be done for `all'

这让我认为它没有找到我的 readline 安装。关于如何让它找到 readline 有什么想法吗?

I'm running ruby 1.9.2 on OS X 10.6, and mostly things are working fine. But readline doesn't seem to be working, either in IRB or in the rails console. A few different posts suggested building readline as an extension, like this

cd <ruby-source-dir>/ext/readline
ruby extconf.rb
make
make install

So I did that, and here's what I get:

checking for tgetnum() in -lncurses... yes
checking for readline/readline.h... yes
checking for readline/history.h... yes
checking for readline() in -lreadline... no
checking for readline() in -ledit... no
checking for editline/readline.h... yes
checking for readline() in -ledit... no

and then

make: Nothing to be done for `all'

This makes me think it's not finding my readline install. Any ideas on how to get it to find readline?

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

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

发布评论

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

评论(1

唯憾梦倾城 2024-11-02 00:59:19

我重新编译了 readline,然后再次尝试上述步骤,一切正常。我认为这可能是因为我最初是为 osx 10.5 编译 readline 的,当时 ruby​​ 还是 32 位的。

I re-compiled readline and then tried the steps above again and everything worked fine. I think this may be because I had originally compiled readline for osx 10.5, when ruby was still 32 bits.

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