机器:东芝 MK1646GSX、英特尔凌动[电子邮件受保护], 2048Mb。 32位。
操作系统:Linux 精简版 3.8
我试图安装 PIDGIN 依赖项:
~> sudo apt-get build-dep pidgin
然后我得到了这个而不是安装build-dep
:
Reading package lists... Done
E: You must put some 'source' URIs in your sources.list
所以我进行了搜索,发现消息来源说我应该这样做rm -rf the sources.list
,然后apt-get update
列表就会自行创建。结果并不好,就像我预期的那样,该列表没有自动创建。之后,我制作了一个具有相同内容的新列表,我尝试确保每一行并拥有它自己deb-src
。所有线路均正确。但当我尝试安装build-dep
.该怎么办?
从 justpaste 链接复制的sources.list:
###### Ubuntu Main Repos
deb http://archive.ubuntu.com/ubuntu xenial main restricted universe multiverse
# deb-src http://archive.ubuntu.com/ubuntu xenial main restricted universe multiverse
###### Ubuntu Update Repos
deb http://archive.ubuntu.com/ubuntu xenial-security main restricted universe multiverse
# deb-src http://archive.ubuntu.com/ubuntu xenial-security main restricted universe multiverse
deb http://archive.ubuntu.com/ubuntu xenial-updates main restricted universe multiverse
# deb-src http://archive.ubuntu.com/ubuntu xenial-updates main restricted universe multiverse
deb http://archive.ubuntu.com/ubuntu xenial-proposed main restricted universe multiverse
# deb-src http://archive.ubuntu.com/ubuntu xenial-proposed main restricted universe multiverse
deb http://archive.ubuntu.com/ubuntu xenial-backports main restricted universe multiverse
# deb-src http://archive.ubuntu.com/ubuntu xenial-backports main restricted universe multiverse
###### Ubuntu Partner Repos
deb http://archive.canonical.com/ xenial partner
# deb-src http://archive.canonical.com/ xenial partner
答案1
取消注释deb-src
以下行/etc/apt/sources.list
:
sudo sed -i 's/# deb-src/deb-src/' /etc/apt/sources.list
sudo apt update
答案2
software-properties-gtk
选项“源代码”
从 GUI 中,您可以运行:
software-properties-gtk
然后在“Ubuntu软件”选项卡下单击“源代码”:
这已经添加了一些deb-src
行/etc/apt/sources.list
,现在我可以做sudo apt-get build-dep <package>
。
在 Ubuntu 16.04 至 18.04 上测试。