可能重複安裝Ruby 1.9.3:
Ruby 1.9.2 and Rails 3 cannot open rails console使用RVM在Ubuntu
我已經安裝了RVM和Ruby 1.9.2,無論是正常工作。使用rvm版本1.10.2。我之前安裝了rvm軟件包readline/zlib,但現在我在使用readline時遇到了很大的麻煩。我試圖在rvm中安裝ruby 1.9.3,但我總是最終沒有找到readline。
我試圖按照不同的解決方案:
rvm remove 1.9.3
rvm pkg install readline
rvm install 1.9.3 --with-readline-dir=$rvm_path/usr/ \
--with-zlib-dir=$rvm_path/usr/
rvm use 1.9.3
rvmsudo gem install bundler
bundle install (all gems installed fine)
rails c/rails s
.rvm/rubies/ruby-1.9.3-p0/lib/ruby/1.9.1/irb/completion.rb:9:in `require': \
cannot load such file -- readline (LoadError)
我有libreadline-DEV(第6版,當前的)安裝(一切由那些包非常需要)
我也試過以下:當然不是產生
.rvm/src/ruby-1.9.3-p0/ext/readline]$ ruby extconf.rb
checking for tgetnum() in -lncurses... yes
checking for readline/readline.h... yes
checking for readline/history.h... yes
checking for readline() in -lreadline... no
checking for readline() in -ledit... no
checking for editline/readline.h... no
.rvm/src/ruby-1.9.3-p0/ext/readline]$ ruby extconf.rb \
--with-readline-dir=/home/claudiocontin/.rvm/usr/
checking for tgetnum() in -lncurses... yes
checking for readline/readline.h... yes
checking for readline/history.h... yes
checking for readline() in -lreadline... no
checking for readline() in -ledit... no
checking for editline/readline.h... no
.rvm/src/ruby-1.9.3-p0/ext/readline]$ ruby extconf.rb \
--with-readline-lib=/home/claudiocontin/.rvm/usr/
checking for tgetnum() in -lncurses... yes
checking for readline/readline.h... yes
checking for readline/history.h... yes
checking for readline() in -lreadline... no
checking for readline() in -ledit... no
checking for editline/readline.h... no
的Makefile ...
apt-get install libreadline-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
libreadline-dev is already the newest version.
想法?
如何在ubuntu 12.04上手動安裝libreadline5-dev?網上沒有太多關於這個。 – user938363
@ user938363 apt-get install就像這樣:'sudo apt-get install libreadline5-dev'然後按照上圖所示進行編譯。 –