动态链接库找不到 : error while loading shared libraries: libgsl.so.0: cannot open shared object file: No such file or directory
问题:
运行gsl(GNU scientific Library)的函数库,用
gcc erf.c -I/usr/local/include -L/usr/local/lib64 -L/usr/local/lib -g -Wall --std=gnu99 -lgsl -lgslcblas -o m.o
编译,之后运行./m.o
提示error while loading shared libraries: libgsl.so.0: cannot open shared object file: No such file or directory
解决方法:
在shell下
ldd m.o
输出:
~/test/c $ldd m.o
linux-vdso.so.1 => (0x00007fff3d5ff000)
libgsl.so.0 => not found
libgslcblas.so.0 => not found
libc.so.6 => /lib64/libc.so.6 (0x00007f7420c3b000)
/lib64/ld-linux-x86-64.so.2 (0x00007f7420fdd000)
说明libgsl和libgslcblas.so找不到
sudo ldconfig
ldconfig的作用是:Configure Dynamic Linker Run Time Bindings.
然后再次运行ldd m.o
~/test/c $ldd m.o
linux-vdso.so.1 => (0x00007fff62bad000)
libgsl.so.0 => /usr/local/lib/libgsl.so.0 (0x00007f6968a01000)
libgslcblas.so.0 => /usr/local/lib/libgslcblas.so.0 (0x00007f69687ce000)
libc.so.6 => /lib64/libc.so.6 (0x00007f6968439000)
libm.so.6 => /lib64/libm.so.6 (0x00007f69681b5000)
已经成功运行
问题出现原因:
刚刚安装好gsl后,由于gsl的动态链接库没有及时刷新导致识别不到。
动态链接库找不到 : error while loading shared libraries: libgsl.so.0: cannot open shared object file: No such file or directory的更多相关文章
- nginx检查报错 error while loading shared libraries: libprofiler.so.0: cannot open shared object file: No such file or directory
在centos7.3上编译安装nginx-1.12.2 启动测试出错 [root@web02 local]# /usr/local/nginx/sbin/nginx -t /usr/local/ngi ...
- svnadmin:error while loading shared libraries: libaprutil-1.so.0:cannot open shared object file: No such file or directory
wdcp下安装svn后一直提示 svnadmin:error while loading shared libraries: libaprutil-1.so.0:cannot open shared ...
- ./filezilla: error while loading shared libraries: libpng12.so.0: cannot open shared object file: No such file or directory
opensuse系统 在filezilla官网下载压缩文件解压运行后报 ./filezilla: error while loading shared libraries: libpng12.so.0 ...
- error while loading shared libraries: libpthread.so.0: cannot open shared object file: No such file
安装rac10g,出现例如以下错误: [root@rac2 oracle]# /u01/product/crs/root.sh WARNING: directory '/u01/product' is ...
- 运行错误:error while loading shared libraries: xxx.so.0:cannot open shared object file: No such file or
链接时可以通过-L和-l来指定自己的库,因此链接可以通过,但是运行时,系统仍无法找到指定的库,需要简单配置一下. 解决方法: 可以直接在将自己的库所在路径添加到/etc/ld.so.conf文件中.但 ...
- opensuse13.1 安装chrome报 error while loading shared libraries:libudev.so.0:cannot open shared object file:no file or directory
1 opensuse13.1 安装chrome时 先用rpm -ivh --test **.rpm 测试安装 安装上缺少的文件 2 但是安装测试通过 却不能启动 原因 缺少一个文件 libudev ...
- error while loading shared libraries: libpcre.so.0的解决办法
error while loading shared libraries: libpcre.so.0的解决办法 http://blog.csdn.net/xjkwq1qq/article/detail ...
- Nginx启动错误:error while loading shared libraries: libpcre.so.0
今天测试的时候,启动一个其他机器预编译好的nginx到目标测试机器(OEL 7.4)启动的时候,报了下列错误: /usr/local/nginx/sbin/nginx: error while loa ...
- gm: error while loading shared libraries: libpng15.so.15: cannot open shared object file: No such file or directory
安装gm库产生问题 解决方案: # cat /etc/ld.so.confinclude ld.so.conf.d/*.conf# echo "/usr/local/lib" &g ...
随机推荐
- Codeforces Round #200 (Div. 1)D. Water Tree dfs序
D. Water Tree Time Limit: 1 Sec Memory Limit: 256 MB 题目连接 http://codeforces.com/contest/343/problem/ ...
- JavaScript学习笔记之下拉选择框的操作
对于下拉框的操作十分繁多,这几天项目须要就总结一下 一.动态构建option 有时候我们须要动态构建下拉选择框里面的值,这里我们就要用到 var varItem = new Option(" ...
- android133 360 06 一键锁频,清楚数据
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools= ...
- (转) 如何在JavaScript与ActiveX之间传递数据1
本文研究如何在JS等脚本语言与ActiveX控件之间通信,如何传递各种类型的参数,以及COM的IDispatch接口.使用类似的方法,可以推广到其他所有脚本型语言,如LUA,AutoCad等.本文将研 ...
- Java基础知识强化之网络编程笔记20:Android网络通信之 Android常用OAuth登录和分享
1. 申请百度开发者账号及百度OAuth简介. (1)申请开发者账号: http://developer.baidu.com/ (2)创建项目: http://developer.baidu.com ...
- Web页面向后台提交数据的方式和选择
1.通过表单提交 这是HTML支持最传统的提交方法,需要创建表单,然后表单包含各种类型的表单元素,还要有一个提交按钮,通过提交按钮来提交到后台,这种方式提交后页面会刷新. 2.通过网页链接提交 可以在 ...
- 关于iOS自定义返回按钮右滑返回手势失效的解决:
在viewDidLoad方法里面添加下面这一句代码即可 self.navigationController.interactivePopGestureRecognizer.delegate=(id)s ...
- show variables 详解
back_log MySQL主线程检查连接并启动一个新线程这段时间内,可以设置多少个请求可以被存在堆栈中 connect_timeout 连接超时 检测方法nmap -p3306 数据库ip dela ...
- UVA - 213 Message Decoding (输入字符串并对单个字符进行操作的输入输出)
POINT: 关于表示一个编码:利用code字符数组表示一个编码字符,其中code[len][val]表示长度为len,二进制值为val的字符: 主程序如下: #include <iostrea ...
- 类名.class与类名.this详解
类名.class 我们知道在java中,一个类在被加载的时候虚拟机就会自动的生成一个这个类的一个Class类型的“类对象”,每个类都对应着一个这样的类对象,通过这个Class类型的类对象,我 ...