在 Xenial 上安装 dpkg-dev

在 Xenial 上安装 dpkg-dev

正在尝试使用 Ubuntu xenial 来运行 php,但我需要获取特定扩展的 php 源代码。尝试这样做时,我得到:

$ sudo apt-get source php7.0

> dpkg-source: not found

谷歌搜索显示应该包含在内dpkg-dev,它似乎是为 ubuntu 16.x 列出的,但我收到错误:

$ sudo apt-get install dpkg-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
Package dpkg-dev is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Package 'dpkg-dev' has no installation candidate

我不确定我遗漏了什么。现在还有其他东西可以提供 dpkg-source 吗?

编辑:输出sudo apt update

Hit:1 http://us.archive.ubuntu.com/ubuntu xenial InRelease
Reading package lists... Done
Building dependency tree
Reading state information... Done
All packages are up to date.

这是我的来源列表:

deb-src http://us.archive.ubuntu.com/ubuntu/ xenial main

答案1

已解决,通过将以下内容添加到我的/etc/apt/sources.list

deb http://us.archive.ubuntu.com/ubuntu/ xenial main

相关内容