Rails安装问题(Mac 10.7)

时间:2013-05-06 13:19:53

标签: ruby-on-rails ruby macos

我刚刚使用自制软件安装了ruby并执行了gem安装rails。

虽然它表示已经安装了rails,但当我在终端上键入rails时,我得到以下输出:

/Users/moveablecode/.rvm/rubies/ruby-1.9.3-p392/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:55:in `require': dlopen(/Users/moveablecode/.rvm/rubies/ruby-1.9.3-p392/lib/ruby/1.9.1/x86_64-darwin11.4.0/digest/md5.bundle, 9): Library not loaded: /opt/local/lib/libcrypto.1.0.0.dylib (LoadError)
  Referenced from: /Users/moveablecode/.rvm/rubies/ruby-1.9.3-p392/lib/ruby/1.9.1/x86_64-darwin11.4.0/digest/md5.bundle
  Reason: image not found - /Users/moveablecode/.rvm/rubies/ruby-1.9.3-p392/lib/ruby/1.9.1/x86_64-darwin11.4.0/digest/md5.bundle
    from /Users/moveablecode/.rvm/rubies/ruby-1.9.3-p392/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:55:in `require'
    from /Users/moveablecode/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/generators/app_base.rb:1:in `<top (required)>'
    from /Users/moveablecode/.rvm/rubies/ruby-1.9.3-p392/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:55:in `require'
    from /Users/moveablecode/.rvm/rubies/ruby-1.9.3-p392/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:55:in `require'
    from /Users/moveablecode/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/generators/rails/app/app_generator.rb:1:in `<top (required)>'
    from /Users/moveablecode/.rvm/rubies/ruby-1.9.3-p392/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:55:in `require'
    from /Users/moveablecode/.rvm/rubies/ruby-1.9.3-p392/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:55:in `require'
    from /Users/moveablecode/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/commands/application.rb:24:in `<top (required)>'
    from /Users/moveablecode/.rvm/rubies/ruby-1.9.3-p392/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:55:in `require'
    from /Users/moveablecode/.rvm/rubies/ruby-1.9.3-p392/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:55:in `require'
    from /Users/moveablecode/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/lib/rails/cli.rb:15:in `<top (required)>'
    from /Users/moveablecode/.rvm/rubies/ruby-1.9.3-p392/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:55:in `require'
    from /Users/moveablecode/.rvm/rubies/ruby-1.9.3-p392/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:55:in `require'
    from /Users/moveablecode/.rvm/gems/ruby-1.9.3-p392/gems/railties-3.2.13/bin/rails:7:in `<top (required)>'
    from /Users/moveablecode/.rvm/gems/ruby-1.9.3-p392/bin/rails:19:in `load'
    from /Users/moveablecode/.rvm/gems/ruby-1.9.3-p392/bin/rails:19:in `<main>'
    from /Users/moveablecode/.rvm/gems/ruby-1.9.3-p392/bin/ruby_noexec_wrapper:14:in `eval'
    from /Users/moveablecode/.rvm/gems/ruby-1.9.3-p392/bin/ruby_noexec_wrapper:14:in `<main>'

解决这些错误的任何解决方案?

1 个答案:

答案 0 :(得分:2)

尝试使用railsinstaller。从http://railsinstaller.org/下载 并按照http://pragmaticstudio.com/blog/2010/9/23/install-rails-ruby-mac中的步骤操作,这对您更有帮助。这是安装rails的最简单方法