无法移除的损坏依赖项阻止 QGIS 在从 Trusty 升级的 Xenial 上安装

无法移除的损坏依赖项阻止 QGIS 在从 Trusty 升级的 Xenial 上安装

我按照 Ubuntu 建议的步骤从 Trusty 升级到 Xenial,但我无法再次安装 QGIS LTR(按照我非常熟悉的 qgis.org 说明,因为我在许多 ubuntu 计算机上安装过 qgis),因为有两个损坏的软件包阻止了我。尝试使用终端执行 sudo autoremove 和 purge,如果 Synaptic 立即检测到它们已损坏,则无法删除它们。以下是 Synaptic 提供的详细信息:

(Reading database ... 248305 files and directories currently installed.)
Removing python-qgis-common (1:2.14.5+24xenial) ...
Could not find platform independent libraries <prefix>
Could not find platform dependent libraries <exec_prefix>
Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]
ImportError: No module named site
dpkg: error processing package python-qgis-common (--remove):
 subprocess installed pre-removal script returned error exit status 1
Could not find platform independent libraries <prefix>
Could not find platform dependent libraries <exec_prefix>
Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]
ImportError: No module named site
dpkg: error while cleaning up:
 subprocess installed post-installation script returned error exit status 1
dpkg: python-matplotlib: dependency problems, but removing anyway as you requested:
 python-qgis-common depends on python-matplotlib.

Removing python-matplotlib (1.5.1-1ubuntu1) ...
Could not find platform independent libraries <prefix>
Could not find platform dependent libraries <exec_prefix>
Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]
ImportError: No module named site
dpkg: error processing package python-matplotlib (--remove):
 subprocess installed pre-removal script returned error exit status 1
Errors were encountered while processing:
 python-qgis-common
 python-matplotlib
E: Sub-process /usr/bin/dpkg returned an error code (1)
A package failed to install.  Trying to recover:

相关内容