ubuntu14.04 vim 丢失 libruby1.8.so.1.8
也忘记自己当初做了什么, 升级到了 Ubuntu14.04以后, Vim 打开不了了.出现的错误是:
vim: error while loading shared libraries: libruby1.8.so.1.8: cannot open shared object file: No such file or directory
ldd 了一下 vim. 结果是:
➜ ~ ldd /usr/bin/vim
linux-vdso.so.1 => (0x00007fff8ebfe000)
libgtk-x11-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0 (0x00007f3dd7bfa000)
libgdk-x11-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libgdk-x11-2.0.so.0 (0x00007f3dd7948000)
libgdk_pixbuf-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libgdk_pixbuf-2.0.so.0 (0x00007f3dd7726000)
libpango-1.0.so.0 => /usr/lib/x86_64-linux-gnu/libpango-1.0.so.0 (0x00007f3dd74d9000)
libgobject-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0 (0x00007f3dd7288000)
libglib-2.0.so.0 => /lib/x86_64-linux-gnu/libglib-2.0.so.0 (0x00007f3dd6f7f000)
libSM.so.6 => /usr/lib/x86_64-linux-gnu/libSM.so.6 (0x00007f3dd6d77000)
libICE.so.6 => /usr/lib/x86_64-linux-gnu/libICE.so.6 (0x00007f3dd6b5b000)
libXt.so.6 => /usr/lib/x86_64-linux-gnu/libXt.so.6 (0x00007f3dd68f4000)
libX11.so.6 => /usr/lib/x86_64-linux-gnu/libX11.so.6 (0x00007f3dd65bf000)
libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f3dd62b9000)
libtinfo.so.5 => /lib/x86_64-linux-gnu/libtinfo.so.5 (0x00007f3dd608f000)
libselinux.so.1 => /lib/x86_64-linux-gnu/libselinux.so.1 (0x00007f3dd5e6c000)
libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f3dd5c68000)
libpython2.7.so.1.0 => /usr/lib/x86_64-linux-gnu/libpython2.7.so.1.0 (0x00007f3dd5700000)
libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f3dd54e2000)
libruby1.8.so.1.8 => not found
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f3dd511b000)
libgmodule-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libgmodule-2.0.so.0 (0x00007f3dd4f17000)
libpangocairo-1.0.so.0 => /usr/lib/x86_64-linux-gnu/libpangocairo-1.0.so.0 (0x00007f3dd4d0a000)
libXfixes.so.3 => /usr/lib/x86_64-linux-gnu/libXfixes.so.3 (0x00007f3dd4b03000)
libatk-1.0.so.0 => /usr/lib/x86_64-linux-gnu/libatk-1.0.so.0 (0x00007f3dd48e1000)
libcairo.so.2 => /usr/lib/x86_64-linux-gnu/libcairo.so.2 (0x00007f3dd45d6000)
libgio-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libgio-2.0.so.0 (0x00007f3dd4262000)
libpangoft2-1.0.so.0 => /usr/lib/x86_64-linux-gnu/libpangoft2-1.0.so.0 (0x00007f3dd404d000)
libfontconfig.so.1 => /usr/lib/x86_64-linux-gnu/libfontconfig.so.1 (0x00007f3dd3e11000)
libXrender.so.1 => /usr/lib/x86_64-linux-gnu/libXrender.so.1 (0x00007f3dd3c06000)
libXinerama.so.1 => /usr/lib/x86_64-linux-gnu/libXinerama.so.1 (0x00007f3dd3a03000)
libXi.so.6 => /usr/lib/x86_64-linux-gnu/libXi.so.6 (0x00007f3dd37f2000)
libXrandr.so.2 => /usr/lib/x86_64-linux-gnu/libXrandr.so.2 (0x00007f3dd35e8000)
libXcursor.so.1 => /usr/lib/x86_64-linux-gnu/libXcursor.so.1 (0x00007f3dd33de000)
libXcomposite.so.1 => /usr/lib/x86_64-linux-gnu/libXcomposite.so.1 (0x00007f3dd31db000)
libXdamage.so.1 => /usr/lib/x86_64-linux-gnu/libXdamage.so.1 (0x00007f3dd2fd7000)
libXext.so.6 => /usr/lib/x86_64-linux-gnu/libXext.so.6 (0x00007f3dd2dc5000)
libthai.so.0 => /usr/lib/x86_64-linux-gnu/libthai.so.0 (0x00007f3dd2bbb000)
libffi.so.6 => /usr/lib/x86_64-linux-gnu/libffi.so.6 (0x00007f3dd29b3000)
libpcre.so.3 => /lib/x86_64-linux-gnu/libpcre.so.3 (0x00007f3dd2775000)
libuuid.so.1 => /lib/x86_64-linux-gnu/libuuid.so.1 (0x00007f3dd256f000)
libxcb.so.1 => /usr/lib/x86_64-linux-gnu/libxcb.so.1 (0x00007f3dd2350000)
/lib64/ld-linux-x86-64.so.2 (0x00007f3dd8256000)
libz.so.1 => /lib/x86_64-linux-gnu/libz.so.1 (0x00007f3dd2136000)
libutil.so.1 => /lib/x86_64-linux-gnu/libutil.so.1 (0x00007f3dd1f33000)
libfreetype.so.6 => /usr/lib/x86_64-linux-gnu/libfreetype.so.6 (0x00007f3dd1c90000)
libpixman-1.so.0 => /usr/lib/x86_64-linux-gnu/libpixman-1.so.0 (0x00007f3dd19e6000)
libpng12.so.0 => /lib/x86_64-linux-gnu/libpng12.so.0 (0x00007f3dd17c0000)
libxcb-shm.so.0 => /usr/lib/x86_64-linux-gnu/libxcb-shm.so.0 (0x00007f3dd15bc000)
libxcb-render.so.0 => /usr/lib/x86_64-linux-gnu/libxcb-render.so.0 (0x00007f3dd13b3000)
librt.so.1 => /lib/x86_64-linux-gnu/librt.so.1 (0x00007f3dd11ab000)
libresolv.so.2 => /lib/x86_64-linux-gnu/libresolv.so.2 (0x00007f3dd0f8f000)
libharfbuzz.so.0 => /usr/lib/x86_64-linux-gnu/libharfbuzz.so.0 (0x00007f3dd0d3a000)
libexpat.so.1 => /lib/x86_64-linux-gnu/libexpat.so.1 (0x00007f3dd0b10000)
libdatrie.so.1 => /usr/lib/x86_64-linux-gnu/libdatrie.so.1 (0x00007f3dd0908000)
libXau.so.6 => /usr/lib/x86_64-linux-gnu/libXau.so.6 (0x00007f3dd0704000)
libXdmcp.so.6 => /usr/lib/x86_64-linux-gnu/libXdmcp.so.6 (0x00007f3dd04fd000)
libgraphite2.so.3 => /usr/lib/x86_64-linux-gnu/libgraphite2.so.3 (0x00007f3dd02e1000)
其中 libruby1.8.so.1.8 => not found
然后我查看了一下 ruby 的依赖.
➜ ~ ldd /home/zhanghb/.rvm/rubies/ruby-2.0.0-p247/bin/ruby
linux-vdso.so.1 => (0x00007fff05597000)
libruby.so.2.0 => /home/zhanghb/.rvm/rubies/ruby-2.0.0-p247/bin/../lib/libruby.so.2.0 (0x00007f89188d9000)
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f89184f4000)
libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f89182d6000)
librt.so.1 => /lib/x86_64-linux-gnu/librt.so.1 (0x00007f89180ce000)
libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f8917ec9000)
libcrypt.so.1 => /lib/x86_64-linux-gnu/libcrypt.so.1 (0x00007f8917c90000)
libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f891798a000)
/lib64/ld-linux-x86-64.so.2 (0x00007f8918d57000)
其中有一个 libruby.so.2.0
这还不是最后的问题, 问题是我登上自己的 linode 服务器, 也是 ubuntu14.04, 但是 ldd vim 以后 发现和本地机器的结果根本不一样. 结果是:
➜ ~ ldd /usr/bin/vim
linux-vdso.so.1 => (0x00007fff9dec8000)
libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f6d189fd000)
libtinfo.so.5 => /lib/x86_64-linux-gnu/libtinfo.so.5 (0x00007f6d187d4000)
libselinux.so.1 => /lib/x86_64-linux-gnu/libselinux.so.1 (0x00007f6d185b0000)
libacl.so.1 => /lib/x86_64-linux-gnu/libacl.so.1 (0x00007f6d183a8000)
libgpm.so.2 => /usr/lib/x86_64-linux-gnu/libgpm.so.2 (0x00007f6d181a1000)
libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f6d17f9c000)
libpython2.7.so.1.0 => /usr/lib/x86_64-linux-gnu/libpython2.7.so.1.0 (0x00007f6d17a35000)
libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f6d17817000)
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f6d17450000)
libpcre.so.3 => /lib/x86_64-linux-gnu/libpcre.so.3 (0x00007f6d17212000)
/lib64/ld-linux-x86-64.so.2 (0x00007f6d18d0b000)
libattr.so.1 => /lib/x86_64-linux-gnu/libattr.so.1 (0x00007f6d1700d000)
libz.so.1 => /lib/x86_64-linux-gnu/libz.so.1 (0x00007f6d16df3000)
libutil.so.1 => /lib/x86_64-linux-gnu/libutil.so.1 (0x00007f6d16bf0000)
所以, 为什么会缺失了 libruby1.8.so.1.8 , 还有 ,linode 上面和我本地机器的 vim 依赖为什么差别这么多呢?
leenll
10 years, 1 month ago