Bug#875913: plplot-tcl, libplplot-{java, lua}: unhandled symlink to directory conversion: /usr/share/doc/PACKAGE

Andreas Beckmann anbe at debian.org
Fri Sep 15 20:54:07 UTC 2017


Package: plplot-tcl,libplplot-java,libplplot-lua
Version: 5.13.0+dfsg-1~exp1
Severity: serious
User: debian-qa at lists.debian.org
Usertags: piuparts

Hi,

an upgrade test with piuparts revealed that your package installs files
over existing symlinks and possibly overwrites files owned by other
packages. This usually means an old version of the package shipped a
symlink but that was later replaced by a real (and non-empty)
directory. This kind of overwriting another package's files cannot be
detected by dpkg.

This was observed on the following upgrade paths:

  sid -> experimental

For /usr/share/doc/PACKAGE this may not be problematic as long as both
packages are installed, ship byte-for-byte identical files and are
upgraded in lockstep. But once one of the involved packages gets
removed, the other one will lose its documentation files, too,
including the copyright file, which is a violation of Policy 12.5:
https://www.debian.org/doc/debian-policy/ch-docs.html#s-copyrightfile

For other overwritten locations anything interesting may happen.

Note that dpkg intentionally does not replace directories with symlinks
and vice versa, you need the maintainer scripts to do this.
See in particular the end of point 4 in
https://www.debian.org/doc/debian-policy/ch-maintainerscripts.html#s-unpackphase

It is recommended to use the dpkg-maintscript-helper commands
'dir_to_symlink' and 'symlink_to_dir' (available since dpkg 1.17.14)
to perform the conversion, ideally using d/$PACKAGE.maintscript.
Do not forget to add 'Pre-Depends: ${misc:Pre-Depends}' in d/control.
See dpkg-maintscript-helper(1) and dh_installdeb(1) for details.


>From the attached log (scroll to the bottom...):

0m18.0s INFO: dirname part contains a symlink:
  /usr/share/doc/plplot-tcl/changelog.Debian.gz (plplot-tcl) != /usr/share/doc/libplplot12/changelog.Debian.gz (?)
    /usr/share/doc/plplot-tcl -> libplplot12
  /usr/share/doc/plplot-tcl/changelog.gz (plplot-tcl) != /usr/share/doc/libplplot12/changelog.gz (?)
    /usr/share/doc/plplot-tcl -> libplplot12
  /usr/share/doc/plplot-tcl/copyright (plplot-tcl) != /usr/share/doc/libplplot12/copyright (?)
    /usr/share/doc/plplot-tcl -> libplplot12

0m15.9s INFO: dirname part contains a symlink:
  /usr/share/doc/libplplot-java/changelog.Debian.gz (libplplot-java) != /usr/share/doc/libplplot12/changelog.Debian.gz (?)
    /usr/share/doc/libplplot-java -> libplplot12
  /usr/share/doc/libplplot-java/changelog.gz (libplplot-java) != /usr/share/doc/libplplot12/changelog.gz (?)
    /usr/share/doc/libplplot-java -> libplplot12
  /usr/share/doc/libplplot-java/copyright (libplplot-java) != /usr/share/doc/libplplot12/copyright (?)
    /usr/share/doc/libplplot-java -> libplplot12
  /usr/share/doc/libplplot-java/examples (libplplot-java) != /usr/share/doc/libplplot12/examples (?)
    /usr/share/doc/libplplot-java -> libplplot12
  /usr/share/doc/libplplot-java/examples/CMakeLists.txt.gz (libplplot-java) != /usr/share/doc/libplplot12/examples/CMakeLists.txt.gz (?)
    /usr/share/doc/libplplot-java -> libplplot12
  /usr/share/doc/libplplot-java/examples/Makefile.examples.in (libplplot-java) != /usr/share/doc/libplplot12/examples/Makefile.examples.in (?)
    /usr/share/doc/libplplot-java -> libplplot12
  /usr/share/doc/libplplot-java/examples/README.javademos (libplplot-java) != /usr/share/doc/libplplot12/examples/README.javademos (?)
    /usr/share/doc/libplplot-java -> libplplot12
  /usr/share/doc/libplplot-java/examples/x00.java (libplplot-java) != /usr/share/doc/libplplot12/examples/x00.java (?)
    /usr/share/doc/libplplot-java -> libplplot12
  /usr/share/doc/libplplot-java/examples/x01.java.gz (libplplot-java) != /usr/share/doc/libplplot12/examples/x01.java.gz (?)
    /usr/share/doc/libplplot-java -> libplplot12
  /usr/share/doc/libplplot-java/examples/x02.java.gz (libplplot-java) != /usr/share/doc/libplplot12/examples/x02.java.gz (?)
    /usr/share/doc/libplplot-java -> libplplot12
  /usr/share/doc/libplplot-java/examples/x03.java (libplplot-java) != /usr/share/doc/libplplot12/examples/x03.java (?)
    /usr/share/doc/libplplot-java -> libplplot12
  /usr/share/doc/libplplot-java/examples/x04.java.gz (libplplot-java) != /usr/share/doc/libplplot12/examples/x04.java.gz (?)
    /usr/share/doc/libplplot-java -> libplplot12
  /usr/share/doc/libplplot-java/examples/x05.java (libplplot-java) != /usr/share/doc/libplplot12/examples/x05.java (?)
    /usr/share/doc/libplplot-java -> libplplot12
  /usr/share/doc/libplplot-java/examples/x06.java (libplplot-java) != /usr/share/doc/libplplot12/examples/x06.java (?)
    /usr/share/doc/libplplot-java -> libplplot12
  /usr/share/doc/libplplot-java/examples/x07.java (libplplot-java) != /usr/share/doc/libplplot12/examples/x07.java (?)
    /usr/share/doc/libplplot-java -> libplplot12
...

0m15.4s INFO: dirname part contains a symlink:
  /usr/share/doc/libplplot-lua/changelog.Debian.gz (libplplot-lua:amd64) != /usr/share/doc/libplplot12/changelog.Debian.gz (?)
    /usr/share/doc/libplplot-lua -> libplplot12
  /usr/share/doc/libplplot-lua/changelog.gz (libplplot-lua:amd64) != /usr/share/doc/libplplot12/changelog.gz (?)
    /usr/share/doc/libplplot-lua -> libplplot12
  /usr/share/doc/libplplot-lua/copyright (libplplot-lua:amd64) != /usr/share/doc/libplplot12/copyright (?)
    /usr/share/doc/libplplot-lua -> libplplot12
  /usr/share/doc/libplplot-lua/examples (libplplot-lua:amd64) != /usr/share/doc/libplplot12/examples (?)
    /usr/share/doc/libplplot-lua -> libplplot12
  /usr/share/doc/libplplot-lua/examples/CMakeLists.txt (libplplot-lua:amd64) != /usr/share/doc/libplplot12/examples/CMakeLists.txt (?)
    /usr/share/doc/libplplot-lua -> libplplot12
  /usr/share/doc/libplplot-lua/examples/plplot_examples.lua.in (libplplot-lua:amd64) != /usr/share/doc/libplplot12/examples/plplot_examples.lua.in (?)
    /usr/share/doc/libplplot-lua -> libplplot12
  /usr/share/doc/libplplot-lua/examples/x00.lua (libplplot-lua:amd64) != /usr/share/doc/libplplot12/examples/x00.lua (?)
    /usr/share/doc/libplplot-lua -> libplplot12
  /usr/share/doc/libplplot-lua/examples/x01.lua.gz (libplplot-lua:amd64) != /usr/share/doc/libplplot12/examples/x01.lua.gz (?)
    /usr/share/doc/libplplot-lua -> libplplot12
  /usr/share/doc/libplplot-lua/examples/x02.lua (libplplot-lua:amd64) != /usr/share/doc/libplplot12/examples/x02.lua (?)
    /usr/share/doc/libplplot-lua -> libplplot12
  /usr/share/doc/libplplot-lua/examples/x03.lua (libplplot-lua:amd64) != /usr/share/doc/libplplot12/examples/x03.lua (?)
    /usr/share/doc/libplplot-lua -> libplplot12
  /usr/share/doc/libplplot-lua/examples/x04.lua.gz (libplplot-lua:amd64) != /usr/share/doc/libplplot12/examples/x04.lua.gz (?)
    /usr/share/doc/libplplot-lua -> libplplot12
  /usr/share/doc/libplplot-lua/examples/x05.lua (libplplot-lua:amd64) != /usr/share/doc/libplplot12/examples/x05.lua (?)
    /usr/share/doc/libplplot-lua -> libplplot12
  /usr/share/doc/libplplot-lua/examples/x06.lua (libplplot-lua:amd64) != /usr/share/doc/libplplot12/examples/x06.lua (?)
    /usr/share/doc/libplplot-lua -> libplplot12
  /usr/share/doc/libplplot-lua/examples/x07.lua (libplplot-lua:amd64) != /usr/share/doc/libplplot12/examples/x07.lua (?)
    /usr/share/doc/libplplot-lua -> libplplot12
  /usr/share/doc/libplplot-lua/examples/x08.lua.gz (libplplot-lua:amd64) != /usr/share/doc/libplplot12/examples/x08.lua.gz (?)
    /usr/share/doc/libplplot-lua -> libplplot12
...

cheers,

Andreas
-------------- next part --------------
A non-text attachment was scrubbed...
Name: plplot-tcl_5.13.0+dfsg-1~exp1.log.gz
Type: application/gzip
Size: 12239 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/debian-science-maintainers/attachments/20170915/a157a46a/attachment-0001.bin>


More information about the debian-science-maintainers mailing list