安装Sqlite3-ruby错误

发布于 2024-09-26 16:53:51 字数 650 浏览 2 评论 0原文

当我尝试安装:gem install sqlite3-ruby时,它显示:

    Building native extensions.  This could take a while...
ERROR:  Error installing sqlite3-ruby:
    ERROR: Failed to build gem native extension.

/usr/bin/ruby1.8 extconf.rb
extconf.rb:3:in `require': no such file to load -- mkmf (LoadError)
    from extconf.rb:3


Gem files will remain installed in /usr/lib/ruby/gems/1.8/gems/sqlite3-ruby-1.3.1 for inspection.
Results logged to /usr/lib/ruby/gems/1.8/gems/sqlite3-ruby-1.3.1/ext/sqlite3/gem_make.out

我的环境: SQLite:2.8.17 导轨:3.0.0 红宝石:1.9.2 Ubuntu:10.04 gem:1.3.7

我在网上查找了所有类似的问题,没有任何帮助,我该怎么办? :(

When I tried to install: gem install sqlite3-ruby it shows:

    Building native extensions.  This could take a while...
ERROR:  Error installing sqlite3-ruby:
    ERROR: Failed to build gem native extension.

/usr/bin/ruby1.8 extconf.rb
extconf.rb:3:in `require': no such file to load -- mkmf (LoadError)
    from extconf.rb:3


Gem files will remain installed in /usr/lib/ruby/gems/1.8/gems/sqlite3-ruby-1.3.1 for inspection.
Results logged to /usr/lib/ruby/gems/1.8/gems/sqlite3-ruby-1.3.1/ext/sqlite3/gem_make.out

My environment:
sqlite: 2.8.17
rails: 3.0.0
ruby: 1.9.2
ubuntu: 10.04
gem: 1.3.7

I have looking all similiar question in webs and SO, nothing help, what should I do? :(

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

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

发布评论

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

评论(1

请爱~陌生人 2024-10-03 16:53:51

我也有同样的问题。我通过

sudo apt-get install sqlite3 libsqlite3-dev

然后以下命令解决了它。

sudo gem install sqlite3-ruby

I had this same problem. I solved it by

sudo apt-get install sqlite3 libsqlite3-dev

Then the following command worked.

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