Reputation: 21
I upgraded my system from ubuntu16.04 to ubuntu18.04,once I updated my system,I fond that my VIM could not be used.Whenever I use my VIM,the following mistakes will occur.
$ vim test.cpp
vim: error while loading shared libraries: libruby-2.3.so.2.3: cannot open shared object file: No such file or directory
What should I do? Help me slove this problem,thanks!
Upvotes: 0
Views: 473
Reputation: 172768
/usr/local/bin/vim
, or under your home directory), you need to recompile it.Vim typically isn't a static, standalone binary. Especially for the language interpreters (Perl, Python, Ruby), it links to them via shared libraries. You'll see some of this in the :version
output.
On the positive side, this means that any fixes and enhancements automatically get into Vim as well. On the negative side, this means that if one of those dependent libraries get upgraded (as happens during a system upgrade) and the old version is lost, you have to recompile Vim, so that the new dependencies are incorporated into it. The also implies that it's not advisable to copy a self-compiled Vim to another Linux system (unless you're sure it's on the exactly same version), and compile on each system instead.
Upvotes: 1