即使有问题的库存在于 /usr/lib 中,“加载共享库时出错”

即使有问题的库存在于 /usr/lib 中,“加载共享库时出错”

我正在尝试跑步斯卡拉在我的 Linux Manjaro 笔记本电脑上,但每当我尝试运行该程序时,它都会显示以下错误:

./scala: error while loading shared libraries: libgtkada.so.2.24.4: cannot open shared object file: No such file or directory

但是,我已经验证有问题的共享对象文件存在于/usr/lib.我尝试ldconfig以 root 身份运行,但这并没有解决问题。当我运行时ldd scala,我收到的相关输出是:

...
libgtkada.so.2.24.4 => not found
...

这对我来说毫无意义,因为libgtkada.so.2.24.4它存在于我的/usr/lib文件夹中。我应该怎么做才能解决这个问题?

编辑: 的输出strace ./scala如下:

execve("./scala", ["./scala"], 0x7ffd5332dbc0 /* 23 vars */) = 0
strace: [ Process PID=7780 runs in 32 bit mode. ]
brk(NULL)                               = 0x98b7000
mmap2(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xf7726000
access("/etc/ld.so.preload", R_OK)      = -1 ENOENT (No such file or directory)
open("/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=319201, ...}) = 0
mmap2(NULL, 319201, PROT_READ, MAP_PRIVATE, 3, 0) = 0xf76d8000
close(3)                                = 0
open("/usr/lib32/tls/i686/sse2/libgtkada.so.2.24.4", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat64("/usr/lib32/tls/i686/sse2", 0xffbe4c20) = -1 ENOENT (No such file or directory)
open("/usr/lib32/tls/i686/libgtkada.so.2.24.4", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat64("/usr/lib32/tls/i686", 0xffbe4c20) = -1 ENOENT (No such file or directory)
open("/usr/lib32/tls/sse2/libgtkada.so.2.24.4", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat64("/usr/lib32/tls/sse2", 0xffbe4c20) = -1 ENOENT (No such file or directory)
open("/usr/lib32/tls/libgtkada.so.2.24.4", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat64("/usr/lib32/tls", 0xffbe4c20)    = -1 ENOENT (No such file or directory)
open("/usr/lib32/i686/sse2/libgtkada.so.2.24.4", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat64("/usr/lib32/i686/sse2", 0xffbe4c20) = -1 ENOENT (No such file or directory)
open("/usr/lib32/i686/libgtkada.so.2.24.4", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat64("/usr/lib32/i686", 0xffbe4c20)   = -1 ENOENT (No such file or directory)
open("/usr/lib32/sse2/libgtkada.so.2.24.4", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat64("/usr/lib32/sse2", 0xffbe4c20)   = -1 ENOENT (No such file or directory)
open("/usr/lib32/libgtkada.so.2.24.4", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat64("/usr/lib32", {st_mode=S_IFDIR|0755, st_size=49152, ...}) = 0
writev(2, [{iov_base="./scala", iov_len=7}, {iov_base=": ", iov_len=2}, {iov_base="error while loading shared libra"..., iov_len=36}, {iov_base=": ", iov_len=2}, {iov_base="libgtkada.so.2.24.4", iov_len=19}, {iov_base=": ", iov_len=2}, {iov_base="cannot open shared object file", iov_len=30}, {iov_base=": ", iov_len=2}, {iov_base="No such file or directory", iov_len=25}, {iov_base="\n", iov_len=1}], 10./scala: error while loading shared libraries: libgtkada.so.2.24.4: cannot open shared object file: No such file or directory
) = 126
exit_group(127)                         = ?
+++ exited with 127 +++
alex@laptop ~/S/scala-

运行echo $LD_LIBRARY_PATH不会产生任何输出。这正常吗?

相关内容