pirosikick's diary

君のハートにunshift

rubyを1.9.2にあげたらgemでエラーが出るようになった。

Ruby1.8.7から1.9.2へバージョンアップ(CentOS5.5) - 俺の作業ログ
↑でRubyを1.8.7から1.9.2に上げました。

gemを使うとこのようなエラーが出ます。

$ gem -v
<internal:lib/rubygems/custom_require>:29: [BUG] Segmentation fault
ruby 1.9.2p0 (2010-08-18 revision 29036) [x86_64-linux]

-- control frame ----------
c:0005 p:---- s:0018 b:0018 l:000017 d:000017 CFUNC  :require
c:0004 p:0013 s:0014 b:0014 l:000013 d:000013 METHOD <internal:lib/rubygems/custom_require>:29
c:0003 p:0011 s:0009 b:0009 l:0013c8 d:000280 EVAL   /usr/bin/gem:8
c:0002 p:---- s:0004 b:0004 l:000003 d:000003 FINISH
c:0001 p:0000 s:0002 b:0002 l:0013c8 d:0013c8 TOP   
---------------------------
-- Ruby level backtrace information ----------------------------------------
/usr/bin/gem:8:in `<main>'
<internal:lib/rubygems/custom_require>:29:in `require'
<internal:lib/rubygems/custom_require>:29:in `require'

セグメンテーション違反です

とりあえずもう1度RubyGemsを入れなおしてみます。

$ cd /usr/local/src
$ sudo wget http://rubyforge.org/frs/download.php/70696/rubygems-1.3.7.tgz
$ sudo tar  xzvf rubygems-1.3.7.tgz
$ cd rubygems-1.3.7
$ sudo ruby setup.rb config

最後1行で同じエラーが出力されます。

$ sudo ruby setup.rb config
<internal:lib/rubygems/custom_require>:29: [BUG] Segmentation fault
ruby 1.9.2p0 (2010-08-18 revision 29036) [x86_64-linux]

-- control frame ----------
c:0005 p:---- s:0019 b:0019 l:000018 d:000018 CFUNC  :require
c:0004 p:0013 s:0015 b:0015 l:000014 d:000014 METHOD <internal:lib/rubygems/custom_require>:29
c:0003 p:0216 s:0010 b:0010 l:000eb8 d:001328 EVAL   setup.rb:24
c:0002 p:---- s:0004 b:0004 l:000003 d:000003 FINISH
c:0001 p:0000 s:0002 b:0002 l:000eb8 d:000eb8 TOP   
---------------------------
-- Ruby level backtrace information ----------------------------------------
setup.rb:24:in `<main>'
<internal:lib/rubygems/custom_require>:29:in `require'
<internal:lib/rubygems/custom_require>:29:in `require'

セグメンテーション違反です

404 Not Found

↑こちらが詳しいようですが、よくわからん。。どうしよアワワ ヽ(´Д`;≡;´Д`)丿 アワワ

Ruby1.9.1を入れてみる

Rubyが1.9.1なら動くのかも。。。入れてみよう!

$ cd /usr/local/src
$ sudo wget ftp://ftp.ruby-lang.org/pub/ruby/1.9/ruby-1.9.1-p430.tar.gz
$ sudo tar zxvf ruby-1.9.1-p430.tar.gz
$ sudo cd ruby-1.9.1-p430
$ sudo ./configure --prefix=/usr
$ sudo make
$ sudo make install

ああ、だめだ、makeでこけるぞ。

./miniruby: symbol lookup error: /usr/lib/ruby/1.9.1/x86_64-linux/enc/encdb.so: undefined symbol: rb_enc_set_base
make: *** [.rbconfig.time] エラー 127

今日は遅いので明日またやります!おやすみ!!