Bug#880921: libopencv-dev: removal of libopencv-dev makes files disappear from libhighgui-dev
Andreas Beckmann
anbe at debian.org
Sun Nov 5 17:39:45 UTC 2017
Package: libopencv-dev
Version: 3.2.0+dfsg-3
Severity: serious
User: debian-qa at lists.debian.org
Usertags: piuparts replaces-without-breaks
Hi,
during a test with piuparts and DOSE tools I noticed your package causes
removal of files that also belong to another package.
This is caused by using Replaces without corresponding Breaks.
The installation sequence to reproduce this problem is
apt-get install libhighgui-dev/stretch
# (1)
apt-get install libopencv-dev/buster
apt-get remove libopencv-dev
# (2)
The list of installed files at points (1) and (2) should be identical,
but the following files have disappeared:
/usr/include/opencv/highgui.h
This is a serious bug violating policy 7.6, see
https://www.debian.org/doc/debian-policy/ch-relationships.html#s-replaces
and also see the footnote that describes this incorrect behavior
https://www.debian.org/doc/debian-policy/footnotes.html#f53
The libopencv-dev package has the following relationships with libhighgui-dev:
Conflicts: libhighgui-dev (<= 2.4.9.1+dfsg-2.1)
Breaks:
Replaces: libhighgui-dev
* The Conflicts version obviously predates the moving around of highgui.h
* The Replaces should be versioned identical to the corresponding Breaks (or Conflicts)
* Breaks is preferred over Conflicts for moving files between packages since it makes apt's job easier
* There are more unversioned Replaces with versioned Conflicts, these should be made versioned, too
>From the attached log (scroll to the bottom...):
5m57.4s DEBUG: Modified(user, group, mode, size, target): /var/lib/dpkg/info/libhighgui-dev:amd64.list expected(root, root, - 100644, 261, None) != found(root, root, - 100644, 231, None)
5m57.4s INFO: Warning: Package purging left files on system:
/etc/fonts/conf.d/10-hinting-slight.conf -> /usr/share/fontconfig/conf.avail/10-hinting-slight.conf not owned
5m57.4s ERROR: FAIL: After purging files have disappeared:
/usr/include/opencv/highgui.h owned by: libopencv-dev
5m57.4s ERROR: FAIL: After purging files have been modified:
/var/lib/dpkg/info/libhighgui-dev:amd64.list not owned
cheers,
Andreas
-------------- next part --------------
A non-text attachment was scrubbed...
Name: libopencv3.2-java=3.2.0+dfsg-3_libopencv3.3-java=3.3.0+dfsg-1~exp0.log.gz
Type: application/gzip
Size: 57200 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/debian-science-maintainers/attachments/20171105/0b486ac0/attachment-0001.bin>
More information about the debian-science-maintainers
mailing list