歡迎來到Linux教程網
Linux教程網
Linux教程網
Linux教程網
Linux教程網 >> Linux基礎 >> Linux教程 >> Linux(Debian) 安裝軟件,缺少動態連接庫.so

Linux(Debian) 安裝軟件,缺少動態連接庫.so

日期:2017/2/28 14:24:28   编辑:Linux教程

Linux(Debian) 安裝軟件,缺少動態連接庫.so

有以下幾種提示:
1.缺少動態連接庫.so-cannot open shared object file:No such file or directory
2.缺少動態連接庫.so.0-cannot open shared object file:No such file or directory
3.缺少動態連接庫.so.1-cannot open shared object file:No such file or directory

可以直接: # sudo ldconfig

再編譯,如果不行,按一下方法做:

總結下來主要有3種方法:

1. 用ln將需要的so文件鏈接到/usr/lib或者/lib這兩個默認的目錄下邊
ln -s /where/you/install/lib/*.so /usr/libsudo ldconfig

2.修改LD_LIBRARY_PATH

export LD_LIBRARY_PATH=/where/you/install/lib:$LD_LIBRARY_PATHsudo ldconfig

3.修改/etc/ld.so.conf,然後刷新

vim /etc/ld.so.conf
add /where/you/install/lib

sudo ldconfig

Copyright © Linux教程網 All Rights Reserved