首页 > 解决方案 > 为 python3-lxml build-dep 添加源 URI

问题描述

我正在尝试运行以下命令:apt-get build-dep python3-lxml.

我得到以下输出:E: You must put some 'source' URIs in your sources.list

这是输出cat /etc/apt/sources.list

deb http://deb.debian.org/debian stretch main contrib non-free
#deb-src http://deb.debian.org/debian stretch main contrib non-free

deb http://deb.debian.org/debian stretch-updates main contrib non-free
#deb-src http://deb.debian.org/debian stretch-updates main contrib non-free

deb http://deb.debian.org/debian-security stretch/updates main contrib non-free
#deb-src http://deb.debian.org/debian-security stretch/updates main contrib non-free

#deb http://deb.debian.org/debian stretch-backports main contrib non-free
##deb-src http://deb.debian.org/debian stretch-backports main contrib non-free

#Kernel source (repos.rcn-ee.com) : https://github.com/RobertCNelson/linux-stable-rcn-ee
#
#git clone https://github.com/RobertCNelson/linux-stable-rcn-ee
#cd ./linux-stable-rcn-ee
#git checkout `uname -r` -b tmp
#
deb [arch=armhf] http://repos.rcn-ee.com/debian/ stretch main
#deb-src [arch=armhf] http://repos.rcn-ee.com/debian/ stretch main

几个问题:

  1. 我应该如何修改这个文件来添加源?
  2. 之后需要跑步apt update吗?
  3. 你怎么知道要添加什么 URI?

先感谢您!

标签: debianlxmlaptdebian-stretch

解决方案


1.您可以/etc/apt/sources.list使用任何文本编辑器编辑您的文件。只需打开它并取消注释以开头的所需行deb-src(即删除#前面的deb-src),保存并关闭它。

2.是的,之后你必须运行apt update

3.所需的 url 已经存在于您的sources.list文件中。


这是有关Debian sources.list的官方文档,以及有关存档类型debdeb-src)的一些特定信息。

这里有一些关于Debian Repositories的附加信息。


推荐阅读