V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
kerie
V2EX  ›  Ruby on Rails

rvm安装ror遇到的一个错误

  •  
  •   kerie · 2011-06-26 12:46:52 +08:00 · 5613 次点击
    这是一个创建于 4685 天前的主题,其中的信息可能已经有所发展或是发生改变。
    ubuntu下用rvm安装ror时出现了如下错误:

    $ gem install rails
    ERROR: Loading command: install (LoadError)
    no such file to load -- zlib
    ERROR: While executing gem ... (NameError)
    uninitialized constant Gem::Commands::InstallCommand

    搜索好像很多人遇到这个问题,昨天折腾了一天也没弄好。有没有人遇到同样的问题?是我步骤不对还是其他地方错了?如果上面的错误描述不够我可以给出更多的细节,请教
    5 条回复    1970-01-01 08:00:00 +08:00
    chloerei
        1
    chloerei  
       2011-06-26 13:25:22 +08:00
    rvm notes, 有一些依赖要装
    chloerei
        2
    chloerei  
       2011-06-26 13:26:49 +08:00
    之后重装所需的ruby版本
    kerie
        3
    kerie  
    OP
       2011-06-26 13:40:04 +08:00
    @chloerei
    # For Ruby (MRI & ree) you should install the following OS dependencies:
    ruby: /usr/bin/apt-get install build-essential bison openssl libreadline6 libreadline6-dev curl git-core zlib1g zlib1g-dev libssl-dev libyaml-dev libsqlite3-0 libsqlite3-dev sqlite3 libxml2-dev libxslt-dev autoconf libc6-dev ncurses-dev
    这些也都安装了,然后重新运行了
    $ rvm install 1.9.2
    $ rvm --default ruby-1.9.2
    $ ruby -v
    ruby 1.9.2p180 (2011-02-18 revision 30909) [i686-linux]
    然后gem install rails遇到同样的错误
    chloerei
        4
    chloerei  
       2011-06-26 13:43:11 +08:00
    @kerie 重装1.9.2
    kerie
        5
    kerie  
    OP
       2011-06-26 13:57:47 +08:00
    @chloerei 好了,谢谢啦~
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   3700 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 27ms · UTC 10:42 · PVG 18:42 · LAX 03:42 · JFK 06:42
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.