繁体   English   中英

Debian Multiarch:无法同时为armhf和amd64安装python

[英]Debian multiarch: unable to install python for both armhf and amd64

对于一个正在进行的项目,我使用Debian(8)作为基本OS。 我要开发的目标是基于ARM的平台。 因此,为了方便地进行交叉编译,我使用了debian提供的多体系结构功能。

不幸的是,当我尝试为主机系统和我要交叉编译的系统安装python时,遇到了一个问题。 看来它们不能彼此相邻安装。

当我尝试使用apt-get install( apt-get install python python:armhf )为两种体系结构apt-get install python python:armhf ,出现以下错误:

Reading package lists... Done
Building dependency tree... 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:
python : Depends: python2.7 (>= 2.7.9-1~) but it is not going to be installed
      PreDepends: python-minimal (= 2.7.9-1) but it is not going to be installed
      Conflicts: python:armhf but 2.7.9-1 is to be installed
python:armhf : Conflicts: python but 2.7.9-1 is to be installed

如果我先为主机系统安装python,然后尝试为armhf安装python,则apt想要再次删除第一个python安装。

有人看过吗? 任何想法如何解决这个问题?

从Debian Jessie开始,Multiarch不允许并行安装可执行文件:

  • 软件包python包含安装到/ usr / bin的可执行文件(例如pdb,pydoc等)
  • 软件包python:armhf也包含这些可执行文件,它们也应该安装到/ usr / bin。
  • 因此,不能同时安装python和python:armhf,因为一个软件包的可执行文件将覆盖另一软件包的可执行文件。

好消息是,您不需要两个python解释器。 在您的情况下,我将只安装主机体系结构所需的python解释器(例如python:amd64)。 请注意,使用诸如sudo apt-get build-dep -a armhf PACKAGE-NAME类的命令来安装构建依赖项有时可能会失败,并且您必须猜测需要手动安装哪些软件包。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM