加载共享库时出错:libgsl.so.0:无法打开共享库文件:没有这样的文件或目录 [英] error while loading shared libraries: libgsl.so.0: cannot open shared object file: No such file or directory
问题描述
我使用gsl.编译并运行.cpp文件后,遇到以下错误:
I use gsl. After I compiled my .cpp file and run it, I faced with below error:
加载共享库时出错:libgsl.so.0:无法打开共享库文件:没有这样的文件或目录
error while loading shared libraries: libgsl.so.0: cannot open shared object file: No such file or directory
我在以下地方发现了与此问题相同的问题: https://groups.google.com/forum/#!topic/cortex_var/6vluX7pP0Sk& http://www.gnu.org/software/gsl/manual/html_node/Shared-Libraries.html
I found same as this problem in: https://groups.google.com/forum/#!topic/cortex_var/6vluX7pP0Sk & Linux error while loading shared libraries: cannot open shared object file: No such file or directory & http://www.gnu.org/software/gsl/manual/html_node/Shared-Libraries.html
我已经按照上面链接中的描述进行了操作,但是错误仍然存在.谁能帮我吗?
And I have done as in the above links wrote but the error is still remained. Can anyone help me?
推荐答案
要使其正常运行,请执行以下步骤
To make it work do the following steps
启动Borne Shell
Start Borne Shell
$LD_LIBRARY_PATH= path to your gsl lib folder inside the gsl installation folder
$export LD_LIBRARY_PATH
现在运行您的可执行文件
now run your executable
应该工作正常.
这篇关于加载共享库时出错:libgsl.so.0:无法打开共享库文件:没有这样的文件或目录的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!