我正在嘗試學習Ruby on Rails。我購買了Ruby Mine並將其安裝在Ubuntu上。我按照安裝說明操作,當我試圖調試我的第一個項目中的RubyMine,我得到這個:使用RubyMine接收錯誤
Error running Development: test001: Failed to install gems.
Following gems were not installed: linecache19 (0.5.12): Error installing linecache19: ERROR: Failed to build gem native extension. /home/stormkiernan/.rvm/rubies/ruby-1.9.2-p290/bin/ruby extconf.rb * extconf.rb failed * Could not create Makefile due to some reason, probably lack of necessary libraries and/or headers. Check the mkmf.log file for more details. You may need configuration options. Provided configuration options: --with-opt-dir --without-opt-dir --with-opt-include --without-opt-include=${opt-dir}/include --with-opt-lib --without-opt-lib=${opt-dir}/lib --with-make-prog --without-make-prog --srcdir=. --curdir --ruby=/home/stormkiernan/.rvm/rubies/ruby-1.9.2-p290/bin/ruby /home/stormkiernan/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in
require': no such file to load -- openssl (LoadError) from /home/stormkiernan/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in
require' from /home/stormkiernan/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/1.9.1/net/https.rb:92:in' from /home/stormkiernan/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in
require' from /home/stormkiernan/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:inrequire' from /home/stormkiernan/.rvm/gems/[email protected]/gems/ruby_core_source-0.1.5/lib/contrib/uri_ext.rb:11:in
' from /home/stormkiernan/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:inrequire' from /home/stormkiernan/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in
require' from /home/stormkiernan/.rvm/gems/[email protected]/gems/ruby_core_source-0.1.5/lib/ruby_core_source.rb:6:in' from rubygems/custom_require>:33:in
require' from rubygems/custom_require>:33:inrescue in require' from rubygems/custom_require>:29:in
require' from extconf.rb:2:in' Gem files will remain installed in /home/stormkiernan/.rvm/gems/[email protected]/gems/linecache19-0.5.12 for inspection. Results logged to /home/stormkiernan/.rvm/gems/[email protected]/gems/linecache19-0.5.12/ext/trace_nums/gem_make.out /home/stormkiernan/Downloads/RubyMine-3.2.4/rb/gems/ruby-debug-base19x-0.11.30.pre2.gem: Error installing ruby-debug-base19x-0.11.30.pre2.gem: ERROR: Failed to build gem native extension. /home/stormkiernan/.rvm/rubies/ruby-1.9.2-p290/bin/ruby extconf.rb *** extconf.rb failed *** Could not create Makefile due to some reason, probably lack of necessary libraries and/or headers. Check the mkmf.log file for more details. You may need configuration options. Provided configuration options: --with-opt-dir --without-opt-dir --with-opt-include --without-opt-include=${opt-dir}/include --with-opt-lib --without-opt-lib=${opt-dir}/lib --with-make-prog --without-make-prog --srcdir=. --curdir --ruby=/home/stormkiernan/.rvm/rubies/ruby-1.9.2-p290/bin/ruby /home/stormkiernan/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in
require': no such file to load -- openssl (LoadError) from /home/stormkiernan/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:inrequire' from /home/stormkiernan/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/1.9.1/net/https.rb:92:in
' from /home/stormkiernan/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:inrequire' from /home/stormkiernan/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in
require' from /home/stormkiernan/.rvm/gems/[email protected]/gems/ruby_core_source-0.1.5/lib/contrib/uri_ext.rb:11:in' from /home/stormkiernan/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in
require' from /home/stormkiernan/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:inrequire' from /home/stormkiernan/.rvm/gems/[email protected]/gems/ruby_core_source-0.1.5/lib/ruby_core_source.rb:6:in
' from rubygems/custom_require>:33:inrequire' from rubygems/custom_require>:33:in
rescue in require' from rubygems/custom_require>:29:inrequire' from extconf.rb:2:in
' Gem files will remain installed in /home/stormkiernan/.rvm/gems/[email protected]/gems/linecache19-0.5.12 for inspection. Results logged to /home/stormkiernan/.rvm/gems/[email protected]/gems/linecache19-0.5.12/ext/trace_nums/gem_make.out
現在,我與提示之前,爲了這個錯誤:
The gem ruby-debug-base19x required by the debugger is not currently installed. Would you like to install it?
我回應「是」,它試圖(並且我認爲失敗)下載軟件所需的任何必要的依賴關係。窗口標題是「安裝寶石」。在此窗口關閉後立即收到上述錯誤。
我需要做什麼?
編輯:紅寶石信封
RubyGems Environment:
- RUBYGEMS VERSION: 1.8.10
- RUBY VERSION: 1.9.2 (2011-07-09 patchlevel 290) [x86_64-linux]
- INSTALLATION DIRECTORY: /home/stormkiernan/.rvm/gems/ruby-1.9.2-p290
- RUBY EXECUTABLE: /home/stormkiernan/.rvm/rubies/ruby-1.9.2-p290/bin/ruby
- EXECUTABLE DIRECTORY: /home/stormkiernan/.rvm/gems/ruby-1.9.2-p290/bin
- RUBYGEMS PLATFORMS:
- ruby
- x86_64-linux
- GEM PATHS:
- /home/stormkiernan/.rvm/gems/ruby-1.9.2-p290
- /home/stormkiernan/.rvm/gems/[email protected]
- GEM CONFIGURATION:
- :update_sources => true
- :verbose => true
- :benchmark => false
- :backtrace => false
- :bulk_threshold => 1000
- REMOTE SOURCES:
- http://rubygems.org/
編輯#2顯示錯誤:
$ gem install ruby-debug-base19x Fetching: linecache19-0.5.12.gem (100%) Building native extensions. This could take a while... ERROR: Error installing ruby-debug-base19x: ERROR: Failed to build gem native extension.
/home/stormkiernan/.rvm/rubies/ruby-1.9.2-p290/bin/ruby
extconf.rb * extconf.rb failed * Could not create Makefile due to some reason, probably lack of necessary libraries and/or headers. Check the mkmf.log file for more details. You may need configuration options.
Provided configuration options: --with-opt-dir --without-opt-dir --with-opt-include --without-opt-include=${opt-dir}/include --with-opt-lib --without-opt-lib=${opt-dir}/lib --with-make-prog --without-make-prog --srcdir=. --curdir --ruby=/home/stormkiernan/.rvm/rubies/ruby-1.9.2-p290/bin/ruby :29:in
require': no such file to load -- ruby_core_source (LoadError) from <internal:lib/rubygems/custom_require>:29:in
require' from extconf.rb:2:in `'Gem files will remain installed in /home/stormkiernan/.rvm/gems/ruby-1.9.2-p290/gems/linecache19-0.5.12 for inspection. Results logged to /home/stormkiernan/.rvm/gems/ruby-1.9.2-p290/gems/linecache19-0.5.12/ext/trace_nums/gem_make.out
這兩個都沒有工作:錯誤:執行gem時(Gem :: FilePermissionError) 您沒有寫入/var/lib/gems/1.8目錄的權限。我試圖在超級用戶模式下做同樣的事情,但它告訴我:錯誤:安裝ruby-debug-base19x時出錯:linecache19需要Ruby版本> = 1.9.2。這當然不應該是可能的,因爲在那之前我曾使用RVM成功安裝了ruby 1.9.2 ... –
gem環境顯示什麼? – jschorr
嘗試rvm 1.9.2 - 默認,然後上面的寶石安裝 – jschorr