子进程错误

子进程错误

在安装启蒙期间,我要求运行以下命令:

sudo apt-get install -f

这导致子进程错误,这对我来说是无法理解的。

Reading package lists... Done
Building dependency tree       
Reading state information... Done
Correcting dependencies... Done
The following packages were automatically installed and are no longer required:
  libefl-data libelementary-bin libelementary1
Use 'apt-get autoremove' to remove them.
The following extra packages will be installed:
  libefl-bin
The following packages will be upgraded:
  libefl-bin
1 upgraded, 0 newly installed, 0 to remove and 1 not upgraded.
7 not fully installed or removed.
Need to get 0 B/470 kB of archives.
After this operation, 396 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
(Reading database ... 289041 files and directories currently installed.)
Preparing to unpack .../libefl-bin_201602061431-31496~ubuntu14.04.1_amd64.deb ...
Unpacking libefl-bin (201602061431-31496~ubuntu14.04.1) over (1.17.0-0trusty0) ...
dpkg: error processing archive /var/cache/apt/archives/libefl-bin_201602061431-31496~ubuntu14.04.1_amd64.deb (--unpack):
 trying to overwrite '/usr/share/mime/packages/edje.xml', which is also in package libefl-data 1.17.0-0trusty0
dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Processing triggers for shared-mime-info (1.2-0ubuntu3) ...
Unknown media type in type 'all/all'
Unknown media type in type 'all/allfiles'
Unknown media type in type 'uri/mms'
Unknown media type in type 'uri/mmst'
Unknown media type in type 'uri/mmsu'
Unknown media type in type 'uri/pnm'
Unknown media type in type 'uri/rtspt'
Unknown media type in type 'uri/rtspu'
Errors were encountered while processing:
 /var/cache/apt/archives/libefl-bin_201602061431-31496~ubuntu14.04.1_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

知道造成这个问题的原因是什么吗?

答案1

就像错误信息说的那样:

dpkg: error processing archive /var/cache/apt/archives/libefl-bin_201602061431-31496~ubuntu14.04.1_amd64.deb (--unpack):
 trying to overwrite '/usr/share/mime/packages/edje.xml', which is also in package libefl-data 1.17.0-0trusty0  

也就是说,您要求安装libefl-bin_201602061431-31496~ubuntu14.04.1_amd64.deblibefl二进制包)。

在尝试解压软件包(安装的一部分)时,它注意到软件包libefl-bin...正在尝试覆盖(替换)文件,/usr/share/mime/packages/edje.xml该文件是libefl-data 1.17.0-0trusty0软件包的一部分。如果两个不同的软件包尝试安装同一个文件,其中一个会不高兴。

您可以先卸载libefl-data(版本1.17.0-0trusty0)(可能最安全),或者像@Ron:所说的那样,使用强制选项。 的版本libefl-bin...与 的版本相同libefl-data吗? 看起来不像。 它们会愉快地互操作吗? 我不这么认为。 如果您libefl-data先卸载,则安装libefl-bin...将引入兼容的版本libefl-data(如果需要)。

答案2

在大多数情况下,强制覆盖文件应该可以解决问题:

sudo dpkg -i --force-overwrite /var/cache/apt/archives/libefl-bin_201602061431-31496~ubuntu14.04.1_amd64.deb
sudo apt-get install -f

相关内容