Package: dpkg
Version: 1.18.7
Severity: serious
Justification: Prevents the installation of a packages/leaves package
in a broken state.
Hi,
Installing a new version of the package imagemagick is failing:
#dpkg -i /var/cache/apt/archives/imagemagick_8%3a6.9.2.10+dfsg-2_all.deb
(Reading database ... 431189 files and directories currently installed.)
Preparing to unpack .../imagemagick_8%3a6.9.2.10+dfsg-2_all.deb ...
dpkg-query: no packages found matching imagemagick:all
dpkg-query: package 'imagemagick' is not installed
Use dpkg --info (= dpkg-deb --info) to examine archive files,
and dpkg --contents (= dpkg-deb --contents) to list their contents.
dpkg-query: package 'imagemagick' is not installed
Use dpkg --info (= dpkg-deb --info) to examine archive files,
and dpkg --contents (= dpkg-deb --contents) to list their contents.
dpkg-query: package 'imagemagick' is not installed
Use dpkg --info (= dpkg-deb --info) to examine archive files,
and dpkg --contents (= dpkg-deb --contents) to list their contents.
dpkg-query: package 'imagemagick' is not installed
Use dpkg --info (= dpkg-deb --info) to examine archive files,
and dpkg --contents (= dpkg-deb --contents) to list their contents.
dpkg-query: package 'imagemagick' is not installed
Use dpkg --info (= dpkg-deb --info) to examine archive files,
and dpkg --contents (= dpkg-deb --contents) to list their contents.
dpkg-maintscript-helper: error: directory '/usr/share/doc/imagemagick' contains
files not owned by package imagemagick:all, cannot switch to symlink
dpkg: error processing archive
/var/cache/apt/archives/imagemagick_8%3a6.9.2.10+dfsg-2_all.deb (--install):
subprocess new pre-installation script returned error exit status 1
Errors were encountered while processing:
/var/cache/apt/archives/imagemagick_8%3a6.9.2.10+dfsg-2_all.deb
The current status of the package imagemagick from dpkg -l is:
ii imagemagick 8:6.9.1.2-1 amd64 image manipulation
programs -- binaries
The problematic output appears to be coming from
dpkg-maintscript-helper, invoked with the following dpkg environment
variables, and command line:
DPKG_ROOT=
DPKG_MAINTSCRIPT_DEBUG=1
DPKG_MAINTSCRIPT_ARCH=all
DPKG_RUNNING
_VERSION=1.18.7
DPKG_MAINTSCRIPT_NAME=preinst
DPKG_MAINTSCRIPT_PACKAGE=im
agemagick
DPKG_ADMINDIR=/var/lib/dpkg
#dpkg-maintscript-helper dir_to_symlink /usr/share/doc/imagemagick
/usr/share/doc/imagemagick-6-common 8:6.9.2.10+dfsg-2~ -- upgrade 8:6.9.1.2-1
8:6.9.2.10+dfsg-2
The problem seems to be that dpkg-maintscript-helper is expecting that
the already installed version is of the same architecture as given in
DPKG_MAINTSCRIPT_ARCH. It is unclear to me if this is a deficiency of
dpkg-maintscript-helper or the caller.
Thanks,
Matthew W.S. Bell