我刚刚安装了Kali,并且尝试使用apt update && apt upgrade -y
运行完整的更新。但是问题是我在ruby-http-parser
软件包中总是遇到错误,我该怎么办?
root@kali:~# apt update && apt upgrade -y
Hit:1 http://kali.download/kali kali-rolling InRelease
Reading package lists... Done
Building dependency tree
Reading state information... Done
2070 packages can be upgraded. Run 'apt list --upgradable' to see them.
Reading package lists... Done
Building dependency tree
Reading state information... Done
Calculating upgrade... Done
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:
ruby-http-parser.rb : Conflicts: ruby-http-parser but 1.2.1-4+b1 is to be installed
E: Broken packages
这是/var/lib/dpkg/status
Package: ruby-http-parser.rb
Status: install ok installed
Priority: optional
Section: ruby
Installed-Size: 46
Maintainer: Debian Ruby Extras Maintainers <pkg-ruby-extras-maintainers@lists.alioth.debian.org>
Architecture: amd64
Source: ruby-http-parser.rb (0.6.0-4)
Version: 0.6.0-4+b3
Depends: ruby (>= 1:2.5~0), libc6 (>= 2.4), libgmp10, libhttp-parser2.8 (>= 2.1), libruby2.5 (>= 2.5.0~preview1), ruby (<< 1:2.6~)
Suggests: ruby-http-parser.rb-doc
Conflicts: ruby-http-parser
Description: Simple callback-based HTTP request/response parser
A simple callback-based HTTP request/response parser for writing http servers,
clients and proxies.
.
It is built on top of Joyent's libhttp-parser and it's Java port.
Homepage: http://github.com/tmm1/http_parser.rb
答案 0 :(得分:1)
我遇到了同样的问题。我能够解决这个问题。
通过查看您提供的数据,它在执行apt upgrade
时启动。
代替apt upgrade
使用apt-get upgrade
升级。
此外,这是一个ruby依赖错误,因此您可以使用
apt-get install ruby-http-parser.rb
它将尝试安装ruby-http-parser依赖项。我能够使用上面的步骤来解决。
现在,apt upgrade
也可以使用。
编辑: 如果仍然不起作用。尝试安装以下依赖项。
apt-get install gcc-9-base libgcc-9-dev libc6-dev
这些是我面临的各种依赖关系。 注意:有时它会要求以libgcc-8-dev的依赖关系,然后去安装libgcc-8-dev而不是libgcc-9-dev。