尝试在新的Ruby安装上创建新的Rails应用程序时无法找到文件

时间:2012-10-10 06:20:21

标签: ruby-on-rails install ubuntu-10.10

我正在使用本指南 - https://www.digitalocean.com/community/articles/how-to-install-ruby-on-rails-on-ubuntu-12-04-lts-precise-pangolin-with-rvm

我知道这是12.04,但有经验的用户推荐,所以我用它。

我正在关注本指南,当我跑步时:

  rvm install 1.9.3

我进入控制台

 denys@denys-N68S3:~/Desktop$ rvm install 1.9.3
 No binary rubies available for: ubuntu/10.10/i386/ruby-1.9.3-p194.
 Continuing with compilation. Please read 'rvm mount' to get more information on binary 
 rubies.

然后一切正常,并告诉我安装已完成。

我遵循了所有其他指示到最后。现在,当我跑步时

  rails new project

我在控制台中遇到错误:

  /home/denys/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require': libcrypto.so.1.0.0: cannot open shared object file: No such file or directory - /home/denys/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/i686-linux/digest/md5.so (LoadError)
from /home/denys/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from /home/denys/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.8/lib/rails/generators/app_base.rb:1:in `<top (required)>'
from /home/denys/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from /home/denys/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from /home/denys/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.8/lib/rails/generators/rails/app/app_generator.rb:1:in `<top (required)>'
from /home/denys/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from /home/denys/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from /home/denys/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.8/lib/rails/commands/application.rb:24:in `<top (required)>'
from /home/denys/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from /home/denys/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from /home/denys/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.8/lib/rails/cli.rb:15:in `<top (required)>'
from /home/denys/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from /home/denys/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from /home/denys/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.8/bin/rails:7:in `<top (required)>'
from /home/denys/.rvm/gems/ruby-1.9.3-p194/bin/rails:19:in `load'
from /home/denys/.rvm/gems/ruby-1.9.3-p194/bin/rails:19:in `<main>'
from /home/denys/.rvm/gems/ruby-1.9.3-p194/bin/ruby_noexec_wrapper:14:in `eval'
from /home/denys/.rvm/gems/ruby-1.9.3-p194/bin/ruby_noexec_wrapper:14:in `<main>'

我认为这是问题,因为我正在尝试安装,然后Rails无法正常工作。

请帮帮我。

1 个答案:

答案 0 :(得分:0)

某些Ruby库对某些系统库具有外部依赖性。对于您的错误,似乎缺少的是openssl

如果您键入rvm requirements,它将告诉您操作系统上需要哪些系统库。对我来说,在Ubuntu中它说我需要安装以下内容:

  

apt-get install build-essential openssl libreadline6 libreadline6-dev curl git-core zlib1g zlib1g-dev libssl-dev libyaml-dev libsqlite3-dev sqlite3 libxml2-dev libxslt-dev autoconf libc6-dev ncurses-dev automake libtool bison subversion pkg配置

嗯......这并不意味着你一定需要所有这些 - 但有些是绝对必要的,比如openssl / libssl,libxml等