Ubuntu 18.04 上的 libssl-dev 依赖问题

Ben*_*ins 5 ubuntu apt

我目前正在尝试在 Ubuntu 18.04 上安装 libssl-dev,但我遇到了这个问题:

Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 libssl-dev : Depends: libssl1.1 (= 1.1.0g-2ubuntu4.3) but 1.1.1b-1 is to be installed
              Recommends: libssl-doc but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
Run Code Online (Sandbox Code Playgroud)

我已经尝试了所有常见的事情,例如更新、重新启动等。我在其他地方搜索过这个问题,但对于每个结果,答案要么不起作用,要么太旧/不相关,要么不存在。如果需要,我很乐意提供更多信息。感谢您的任何帮助。

Ben*_*ins 8

我通过运行以下命令设法解决了这个问题:

sudo apt install --reinstall libssl1.1=1.1.0g-2ubuntu4.3

sudo apt install libssl-dev
Run Code Online (Sandbox Code Playgroud)

然后我重新安装了 libssl 降级时卸载的几个包。现在一切似乎都很顺利。