libm.so.6: cannot open shared object file: No such file or directory

社会主义新天地 提交于 2020-06-12 11:43:18

问题


I've install a program in Centos 6.8, While running the program, I receive error "error while loading shared libraries: libm.so.6: cannot open shared object file: No such file or directory" when I checked the linked library to the program using ldd command, I can see libm.so.6 with correct 64bit "libm.so.6 => /lib64/libm.so.6 (0x0000003a19000000)" That means, library is installed and already added in environment variable, LD_LIBRARY_PATH Another program, which uses libm.so.6, works fine. Can anyone help to solve this problem ? Thanks


回答1:


In programming, details matter.

Lets say, The program which I am trying to run is ABC and install

This is not details, this is a hypothetical. If you want useful answers, you should supply actual details that you are asked for. In particular, edit your question (instead of commenting on a different useless answer), and do this: "show the ldd command you actually ran, and its actual output."

That said, if ldd /usr/local/ABC/bin/ABC really does show libm.so.6 => /lib64/libm.so.6, then there is no way for ABC to not find libm.so.6.

Therefore we must conclude that ABC invokes some other program, and that program fails to find libm.so.6. You can confirm this guess by running:

LD_DEBUG=files,libs /usr/local/ABC/bin/ABC

This will show that ABC does find libm.so.6, what other program it invokes, and where that other program looks for libm.so.6.

It is likely that the other program is 32-bit, and looks for /lib/libm.so.6, and that you don't have 32-bit runtime libraries installed.

You can install them with yum install glibc.i686 or some such.



来源:https://stackoverflow.com/questions/39904192/libm-so-6-cannot-open-shared-object-file-no-such-file-or-directory

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!