Ignoring GEM because its extensions are not built

前端 未结 18 1348
陌清茗
陌清茗 2020-12-04 06:35

On both my work and home computers, I recently upgraded Ruby to 2.3.1, using ruby-install. I use chruby as my Ruby switcher.

I started seei

18条回答
  •  攒了一身酷
    2020-12-04 07:18

    TL;DR - Ruby gems don't like Rubies running from symlinks or moved from where they were built (because of embedded shebangs)

    If the Ruby directory is invoked or environment vars point to a symlink'ed directory, or are copied or renamed, this message is likely. I am using chruby and was symlinking /opt/rubies/ -> /usr/local/ruby/, but Ruby's dynamic library-finding logic doesn't play well with this.

    The solution in my case was to replace the symlink with actual rubies in /opt/rubies/ and run gem pristine --all in each Ruby. For others using RVM or Rbenv, good luck with that without starting over from scratch.

    This may not be your exact issue, but hopefully it helps.

提交回复
热议问题