gpt4 book ai didi

ruby - 如何使用 readline 支持重新安装 ruby​​?

转载 作者:数据小太阳 更新时间:2023-10-29 07:11:12 25 4
gpt4 key购买 nike

我已经按照 https://github.com/wayneeseguin/rvm#installation 上的说明通过 RVM 安装了 Ruby .

有关信息,我有所有文件(readline-5.2.tar.gz、readline-6.2.tar.gz、ruby-1.9.3-p327.tar.bz2、rubygems-1.8.24.tgz、 wayneeseguin-rvm-stable.tgz 和 yaml-0.1.4.tar.gz) 在 ~/.rvm/archives 目录中,我不想在任何目录中重新下载它们方式。

当我这样做时:

sudo /usr/bin/apt-get install build-essential openssl libreadline6 libreadline6-dev curl git-core zlib1g zlib1g-dev libssl-dev libyaml-dev libsqlite3-dev sqlite3 libxml2-dev libxslt-dev autoconf libc6-dev ncurses-dev automake libtool bison subversion pkg-config

我得到:

Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'libxslt1-dev' instead of 'libxslt-dev'
Note, selecting 'libncurses5-dev' instead of 'ncurses-dev'
libtool is already the newest version.
sqlite3 is already the newest version.
libxslt1-dev is already the newest version.
libc6-dev is already the newest version.
openssl is already the newest version.
git-core is already the newest version.
subversion is already the newest version.
zlib1g is already the newest version.
libncurses5-dev is already the newest version.
curl is already the newest version.
libreadline6 is already the newest version.
libyaml-dev is already the newest version.
autoconf is already the newest version.
pkg-config is already the newest version.
libxml2-dev is already the newest version.
build-essential is already the newest version.
libssl-dev is already the newest version.
libreadline6-dev is already the newest version.
automake is already the newest version.
zlib1g-dev is already the newest version.
bison is already the newest version.
libsqlite3-dev is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

我什至做过:

$ rvm pkg install readline
$ rvm reinstall 1.9.2 --with-readline-dir=$rvm_path/usr

但我仍然在 irb 上看到这个:

Readline was unable to be required, if you need completion or history install readline then reinstall the ruby. You may follow 'rvm notes' for dependencies and/or read the docs page https://rvm.io/packages/readline/ . Be sure you 'rvm remove X ; rvm install X' to re-compile your ruby with readline support after obtaining the readline libraries.

我已经完成了 4-5 次重新安装过程。

最佳答案

关于

rvm reinstall 1.9.3

一旦安装了基本依赖项(如 build essentials 等),您就可以这样做。我遇到了类似的问题,我不得不安装一些依赖项,然后重新安装 ruby​​ 就成功了。

下面的依赖列表

sudo apt-get install build-essential openssl libreadline6 libreadline6-dev curl git-core \
zlib1g zlib1g-dev libssl-dev libyaml-dev libsqlite3-dev sqlite3 libxml2-dev libxslt1-dev \
autoconf libc6-dev libncurses5-dev automake libtool bison subversion pkg-config

关于ruby - 如何使用 readline 支持重新安装 ruby​​?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/13965491/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com