1

Rubyデバッガーのインストール中に次のエラーが発生します

gemfileに追加しました

 gem 'ruby-debug19', :require => 'ruby-debug'

そして走る

 bundle install

Installing linecache19 (0.5.12) with native extensions
   Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.
   /usr/local/bin/ruby extconf.rb
   checking for vm_core.h... no
   checking for vm_core.h... no
   *** 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=/usr/local/bin/ruby
   --with-ruby-dir
   --without-ruby-dir
   --with-ruby-include
   --without-ruby-include=${ruby-dir}/include
   --with-ruby-lib
   --without-ruby-lib=${ruby-dir}/lib

エラーの理由は何ですか

デバッガーのインストール方法..???

4

3 に答える 3

2

まず、環境変数に DevKit のパスを設定する必要があります

次に実行します

gem install linecache19
gem install ruby-debug-base19
gem install ruby-debug-ide

コマンドプロンプトから

これがうまくいきますように

于 2012-09-05T06:12:49.943 に答える
1

RVM Web サイトから:

ruby-debug19 のインストールに問題がある場合は、次のコマンドでインストールしてみてください。

$ rvm reinstall 1.9.3 --patch debug --force-autoconf
$ gem install ruby-debug19 -- --with-ruby-include="${MY_RUBY_HOME/rubies/src}"
于 2012-09-04T06:34:31.297 に答える
1

「Ubuntu では、ネイティブ コンパイル ステップで ruby​​ 1.9.2 ソースがダウンロードされ、現在のユーザーがおそらく書き込みアクセス権を持っていないディレクトリに展開しようとします。」- ダレン (参照: http://isitruby19.com/linecache19 )

この場合は、 を試してくださいsudo bundle install


問題がファイルの依存関係を解決できないことである場合はvm_core.h、特定のバージョンと ruby​​ ソースへのパスを使用してインストールを実行できます。

sudo -E gem install linecache19 -v=0.5.11 -- --with-ruby-include=path_to/ruby-1.9.1-p378/
sudo -E gem install ruby-debug-base19 -v=0.11.23 -- --with-ruby-include=path_to/ruby-1.9.1-p378/
sudo -E gem install ruby-debug-ide -v=0.4.9 -- --with-ruby-include=path_to/ruby-1.9.1-p378/

参考: http: //isitruby19.com/linecache19

path_to/ruby-1.9.1-p378/を、Ruby をインストールした場所へのパスに置き換えてください。

Ruby をインストールした場所を確認するには、次のコマンドを実行してみてください。

which ruby
于 2012-09-04T06:29:18.453 に答える