1

我在 ubuntu 13.04 上使用 rvm

使用 ruby​​ 1.9.3,irb 工作正常。我可以输入命令,按回车,按向上,命令又出现了。但是,使用 ruby​​ 2.0.0 和 jruby 1.7.3,向上箭头根本没有任何作用。据我所知,readline 已正确安装。

版本信息:

# ruby -v
  jruby 1.7.3 (1.9.3p385) 2013-02-21 dac429b on OpenJDK 64-Bit Server VM 1.7.0_21-b02 [linux-amd64]

# irb -v
  irb 0.9.6(09/06/30)
4

1 回答 1

0

尝试:

$ rvm use 2.0.0
$ find $MY_RUBY_HOME -name readline*
/home/mpapis/.rvm/rubies/ruby-2.0.0-p0/lib64/ruby/2.0.0/x86_64-linux/readline.so
$ ldd /home/mpapis/.rvm/rubies/ruby-2.0.0-p0/lib64/ruby/2.0.0/x86_64-linux/readline.so
    linux-vdso.so.1 (0x00007fff7e576000)
    libruby.so.2.0 => /home/mpapis/.rvm/rubies/ruby-2.0.0-p0/lib64/libruby.so.2.0 (0x00007fc41de05000)
    libreadline.so.6 => /lib64/libreadline.so.6 (0x00007fc41db96000)
    libncurses.so.5 => /lib64/libncurses.so.5 (0x00007fc41d970000)
    libpthread.so.0 => /lib64/libpthread.so.0 (0x00007fc41d754000)
    librt.so.1 => /lib64/librt.so.1 (0x00007fc41d54b000)
    libdl.so.2 => /lib64/libdl.so.2 (0x00007fc41d347000)
    libcrypt.so.1 => /lib64/libcrypt.so.1 (0x00007fc41d10b000)
    libm.so.6 => /lib64/libm.so.6 (0x00007fc41ce0c000)
    libc.so.6 => /lib64/libc.so.6 (0x00007fc41ca5f000)
    /lib64/ld-linux-x86-64.so.2 (0x00007fc41e49f000)
    libtinfo.so.5 => /lib64/libtinfo.so.5 (0x00007fc41c82c000)
于 2013-07-09T04:55:41.050 回答