cannot load such file — zlib even after using rvm pkg install zlib

前端 未结 6 2018
臣服心动
臣服心动 2020-11-29 00:19

I installed zlib package and ruby 1.9.3 using rvm, but whenever I try to install gems it says cannot load such file -- zlib

The commands I used to insta

6条回答
  •  死守一世寂寞
    2020-11-29 00:40

    I ended up installing zlib from apt-get and then reinstalling ruby to not use the rvm directory for zlib.

    Here's how do:

    $ sudo apt-get install zlib1g-dev
    $ rvm reinstall 1.9.3
    

    [Edit] As commenter @chrisfinne mentions, on CentOS/RedHat based systems:

    $ sudo yum install zlib-devel
    $ rvm reinstall 1.9.3
    

提交回复
热议问题