可执行文件缺少库

use*_*406 2 10.04 bash shared-library executable

我下载了一个可执行文件到我的 Ubuntu 10.04 上,但我无法运行,因为它缺少一个库。我也试过用 CMake 编译源代码。这是我的终端输出:

zack@zack-laptop:~/Desktop$ ./MultiMC
./MultiMC: error while loading shared libraries: libssl.so.1.0.0:
cannot open shared object file: No such file or directory
Run Code Online (Sandbox Code Playgroud)

我想我需要 libssl 1.0 来运行这个文件,但我不确定。有什么帮助吗?

@Jim Salter:输出lsb_release -d ; apt-file update ; apt-file search libssl.so.1.0.0是:

Description:    Ubuntu 10.04.4 LTS
apt-file is now using the user's cache directory.
If you want to switch back to the system-wide cache directory,
 run 'apt-file purge'
Downloading complete file http://us.archive.ubuntu.com/ubuntu/dists/lucid/Contents-i386.gz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 16.8M  100 16.8M    0     0   275k      0  0:01:02  0:01:02 --:--:--  171k
Downloading complete file http://us.archive.ubuntu.com/ubuntu/dists/lucid-updates/Contents-i386.gz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 15.4M  100 15.4M    0     0   228k      0  0:01:09  0:01:09 --:--:--  346k
Downloading Index http://us.archive.ubuntu.com/ubuntu/dists/lucid/Contents-i386.diff/Index:
No Index available.
Downloading complete file http://us.archive.ubuntu.com/ubuntu/dists/lucid/Contents-i386.gz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
File is up-to-date.
Downloading Index http://us.archive.ubuntu.com/ubuntu/dists/lucid-updates/Contents-i386.diff/Index:
No Index available.
Downloading complete file http://us.archive.ubuntu.com/ubuntu/dists/lucid-updates/Contents-i386.gz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0 15.4M    0     0    0     0      0      0 --:--:--  0:00:03 --:--:--     0
File is up-to-date.
Downloading Index http://us.archive.ubuntu.com/ubuntu/dists/lucid/Contents-i386.diff/Index:
No Index available.
Downloading complete file http://us.archive.ubuntu.com/ubuntu/dists/lucid/Contents-i386.gz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
File is up-to-date.
Downloading Index http://us.archive.ubuntu.com/ubuntu/dists/lucid-updates/Contents-i386.diff/Index:
No Index available.
Downloading complete file http://us.archive.ubuntu.com/ubuntu/dists/lucid-updates/Contents-i386.gz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:--  0:00:01 --:--:--     0
File is up-to-date.
Ignoring source without Contents File:
  http://archive.canonical.com/ubuntu/dists/lucid/Contents-i386.gz
Downloading complete file http://security.ubuntu.com/ubuntu/dists/lucid-security/Contents-i386.gz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 12.2M  100 12.2M    0     0   303k      0  0:00:41  0:00:41 --:--:--  367k
Downloading Index http://security.ubuntu.com/ubuntu/dists/lucid-security/Contents-i386.diff/Index:
No Index available.
Downloading complete file http://security.ubuntu.com/ubuntu/dists/lucid-security/Contents-i386.gz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0 12.2M    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
File is up-to-date.
Downloading Index http://security.ubuntu.com/ubuntu/dists/lucid-security/Contents-i386.diff/Index:
No Index available.
Downloading complete file http://security.ubuntu.com/ubuntu/dists/lucid-security/Contents-i386.gz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0 12.2M    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
File is up-to-date.
Ignoring source without Contents File:
  http://dl.google.com/linux/chrome/deb/dists/stable/Contents-i386.gz
Ignoring source without Contents File:
  http://ppa.launchpad.net/nilarimogard/webupd8/ubuntu/dists/lucid/Contents-i386.gz
Run Code Online (Sandbox Code Playgroud)

Jim*_*ter 7

you@box:~$ locate libssl.so.1.0.0

在我的机器上,这会返回/lib/i386-linux-gnu/libssl.so.1.0.0/lib/x86_64-linux-gnu/libssl.so.1.0.0。所以。你试图运行的这个东西 - 是 32 位代码还是 64 位代码?假设是前者:

you@box:~/Desktop$ mkdir ~/MultiMC
you@box:~/Desktop$ mv MultiMC ~/MultiMC
you@box:~/Desktop$ cd ~/MultiMC
you@box:~/MultiMC$ ln -s /lib/i386-linux-gnu/libssl.so.1.0.0 ./
you@box:~/MultiMC$ ./MultiMC
Run Code Online (Sandbox Code Playgroud)

鲍勃应该是你的叔叔。(问题是您的“MultiMC”不知道在哪里查找库,即使它实际上存在于您的系统中。理论上,如果您可以访问源代码 - 或者这只是一个开始的脚本与 - 您也可以编辑应用程序本身以在正确的位置查找库。)

如果你一开始就没有libssl.so.1.0.0呢?那么,在这种情况下,您几乎肯定会这样做。但也许会有另一个它需要的库,但在你满足了这个库之后就找不到了,结果你还没有那个库……

you@box:~/MultiMC$ sudo apt-get install apt-file
you@box:~/MultiMC$ sudo apt-file update
you@box:~/MultiMC$ sudo apt-file search libssl.so.1.0.0
Run Code Online (Sandbox Code Playgroud)

然后你可以安装任何包含你需要的库的包。 不过,请务必先检查一下您是否已经拥有该库,但不知道在哪里可以找到它!=)