1

I upgraded from Trusty to Xenial following the step by step proposed by Ubuntu, but I could not install QGIS LTR again (following qgis.org instructions that I am very used to, having installed qgis on many ubuntu computer), being blocked by two broken packages. Tried sudo autoremove and purge with terminal, and if Synaptic immediately detects them as being broken, it cannot remove them. Here are the details provided by 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:

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.