Bug#910480: ghc: missing Breaks+Replaces+Provides for newly bundled libraries
Ilias Tsitsimpis
iliastsi at debian.org
Thu Oct 18 10:56:52 BST 2018
On Sun, Oct 07, 2018 at 02:43AM, Andreas Beckmann wrote:
> during a test with piuparts I noticed your package failed to install
> because it tries to overwrite other packages files without declaring a
> Breaks+Replaces relation.
Hi Andreas,
Thank you for reporting this and for providing the corresponding
Breaks+Replaces+Provides entries.
There seems to exist the debian/provided_substvars script which tries to
add Provides+Conflicts for ghc's bundled libraries, but for some reason
mtl is explicitly ignored. I am not sure why this (as well as other
packages) are being ignored, so I have CC-ed Joachim who wrote that
script.
As for libghc-parsec3-dev, the corresponding library is parsec, so the
d/provided_substvars script incorrectly adds Provides+Conflicts for
libghc-parsec-dev.
Attached is a patch which tries to fix the above problems by making the
following changes:
* Remove all ignored libraries except for ghc, although I believe we
can safely remove that too, and Provide/Conflict libghc-ghc-dev.
@nomeata please comment on whether this is the right approach.
* Turn Provides into versioned Provides, which are supported since
dpkg 1.17.11 and apt 1.0.7. See #761219 on a discussion about
documenting versioned Provides in debian-policy.
* Take into account renamed packages, such as parsec3.
* Add versioned Replaces.
* Turn Conflicts into versioned Conflicts.
Currently, the script adds non-versioned Conflicts, which means that
a newer version of a library cannot be installed. I assume this was
the case with libghc-cabal-dev, and that is why the script
explicitly has a `@no_conflict = ('cabal')` and the corresponding
versioned Conflict is hard-coded in d/control.
Note that I didn't replace Conflicts with Breaks. According to
policy[1], Conflicts should be used:
* when two packages provide the same file and will continue to do so,
* in conjunction with Provides when only one package providing a given
virtual facility may be unpacked at a time,
* in other cases where one must prevent simultaneous installation of
two packages for reasons that are ongoing (not fixed in a later
version of one of the packages) or that must prevent both packages
from being unpacked at the same time, not just configured.
and I couldn't be sure if any of the above apply to our case.
I have also attached the output of `dpkg -I` for ghc, ghc-prof and
ghc-doc, built with these changes, as well as diffs with the current
versions available in unstable (8.4.3+dfsg1-2+b1).
@debian-haskell, please review both the patch and the corresponding
outut, and let me know if I should commit/upload them.
[1] https://www.debian.org/doc/debian-policy/ch-relationships.html#conflicting-binary-packages-conflicts
--
Ilias
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ghc.patch
Type: text/x-diff
Size: 3375 bytes
Desc: not available
URL: <http://alioth-lists.debian.net/pipermail/pkg-haskell-maintainers/attachments/20181018/884d7ab8/attachment-0001.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ghc_info.diff
Type: text/x-diff
Size: 5859 bytes
Desc: not available
URL: <http://alioth-lists.debian.net/pipermail/pkg-haskell-maintainers/attachments/20181018/884d7ab8/attachment-0003.diff>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ghc-prof_info.diff
Type: text/x-diff
Size: 3219 bytes
Desc: not available
URL: <http://alioth-lists.debian.net/pipermail/pkg-haskell-maintainers/attachments/20181018/884d7ab8/attachment-0004.diff>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ghc-doc_info.diff
Type: text/x-diff
Size: 1701 bytes
Desc: not available
URL: <http://alioth-lists.debian.net/pipermail/pkg-haskell-maintainers/attachments/20181018/884d7ab8/attachment-0005.diff>
-------------- next part --------------
new Debian package, version 2.0.
size 67624004 bytes: control archive=68108 bytes.
5200 bytes, 23 lines control
242774 bytes, 2916 lines md5sums
1924 bytes, 57 lines * postinst #!/bin/sh
558 bytes, 29 lines * preinst #!/bin/sh
1055 bytes, 41 lines * prerm #!/bin/sh
45 bytes, 1 lines triggers
Package: ghc
Version: 8.4.3+dfsg1-3
Architecture: amd64
Maintainer: Debian Haskell Group <pkg-haskell-maintainers at lists.alioth.debian.org>
Installed-Size: 733051
Pre-Depends: dpkg (>= 1.16.1)
Depends: gcc, libgmp-dev, libffi-dev, libbsd-dev, libc6-dev, libncurses5-dev, libatomic1 (>= 4.8), libc6 (>= 2.27), libffi6 (>= 3.0.4), libgmp10, libtinfo6 (>= 6)
Suggests: perl, ghc-prof, ghc-doc, haskell-doc, llvm-6.0
Conflicts: ghc-dynamic (<< 7.8), ghc6 (<< 7), libghc-array-dev (<< 0.5.2.0+), libghc-base-dev (<< 4.11.1.0+), libghc-binary-dev (<< 0.8.5.1+), libghc-bytestring-dev (<< 0.10.8.2+), libghc-cabal-dev (<< 2.2.0.1+), libghc-containers-dev (<< 0.5.11.0+), libghc-deepseq-dev (<< 1.4.3.0+), libghc-directory-dev (<< 1.3.1.5+), libghc-filepath-dev (<< 1.4.2+), libghc-ghc-boot-dev (<< 8.4.3+), libghc-ghc-boot-th-dev (<< 8.4.3+), libghc-ghc-compact-dev (<< 0.1.0.0+), libghc-ghc-prim-dev (<< 0.5.2.0+), libghc-ghci-dev (<< 8.4.3+), libghc-haskeline-dev (<< 0.7.4.2+), libghc-hpc-dev (<< 0.6.0.3+), libghc-integer-gmp-dev (<< 1.0.2.0+), libghc-mtl-dev (<< 2.2.2+), libghc-parsec3-dev (<< 3.1.13.0+), libghc-pretty-dev (<< 1.1.3.6+), libghc-process-dev (<< 1.6.3.0+), libghc-rts-dev (<< 1.0+), libghc-stm-dev (<< 2.4.5.0+), libghc-template-haskell-dev (<< 2.13.0.0+), libghc-terminfo-dev (<< 0.4.1.1+), libghc-text-dev (<< 1.2.3.0+), libghc-time-dev (<< 1.8.0.2+), libghc-transformers-dev (<< 0.5.5.0+), libghc-unix-dev (<< 2.7.2.2+), libghc-xhtml-dev (<< 3000.2.2.1+)
Breaks: cabal-install (<< 1.22), ghc-doc (<< 7.10), ghc-haddock (<< 7.10), haskell-devscripts (<< 0.8.13)
Replaces: ghc-dynamic (<< 7.8), ghc-haddock (<< 7.10), ghc6 (<< 7), libghc-array-dev (<< 0.5.2.0+), libghc-base-dev (<< 4.11.1.0+), libghc-binary-dev (<< 0.8.5.1+), libghc-bytestring-dev (<< 0.10.8.2+), libghc-cabal-dev (<< 2.2.0.1+), libghc-containers-dev (<< 0.5.11.0+), libghc-deepseq-dev (<< 1.4.3.0+), libghc-directory-dev (<< 1.3.1.5+), libghc-filepath-dev (<< 1.4.2+), libghc-ghc-boot-dev (<< 8.4.3+), libghc-ghc-boot-th-dev (<< 8.4.3+), libghc-ghc-compact-dev (<< 0.1.0.0+), libghc-ghc-prim-dev (<< 0.5.2.0+), libghc-ghci-dev (<< 8.4.3+), libghc-haskeline-dev (<< 0.7.4.2+), libghc-hpc-dev (<< 0.6.0.3+), libghc-integer-gmp-dev (<< 1.0.2.0+), libghc-mtl-dev (<< 2.2.2+), libghc-parsec3-dev (<< 3.1.13.0+), libghc-pretty-dev (<< 1.1.3.6+), libghc-process-dev (<< 1.6.3.0+), libghc-rts-dev (<< 1.0+), libghc-stm-dev (<< 2.4.5.0+), libghc-template-haskell-dev (<< 2.13.0.0+), libghc-terminfo-dev (<< 0.4.1.1+), libghc-text-dev (<< 1.2.3.0+), libghc-time-dev (<< 1.8.0.2+), libghc-transformers-dev (<< 0.5.5.0+), libghc-unix-dev (<< 2.7.2.2+), libghc-xhtml-dev (<< 3000.2.2.1+)
Provides: ghc-dynamic, ghc-ghci, ghc-haddock, haddock, haddock-interface-33, haskell-compiler, libghc-array-dev (= 0.5.2.0), libghc-array-dev-0.5.2.0-001d5, libghc-base-dev (= 4.11.1.0), libghc-base-dev-4.11.1.0-9da3f, libghc-binary-dev (= 0.8.5.1), libghc-binary-dev-0.8.5.1-758db, libghc-bytestring-dev (= 0.10.8.2), libghc-bytestring-dev-0.10.8.2-76943, libghc-cabal-dev (= 2.2.0.1), libghc-cabal-dev-2.2.0.1-cb731, libghc-containers-dev (= 0.5.11.0), libghc-containers-dev-0.5.11.0-77951, libghc-deepseq-dev (= 1.4.3.0), libghc-deepseq-dev-1.4.3.0-00d8f, libghc-directory-dev (= 1.3.1.5), libghc-directory-dev-1.3.1.5-e563d, libghc-filepath-dev (= 1.4.2), libghc-filepath-dev-1.4.2-f8b35, libghc-ghc-boot-dev (= 8.4.3), libghc-ghc-boot-dev-8.4.3-8ac28, libghc-ghc-boot-th-dev (= 8.4.3), libghc-ghc-boot-th-dev-8.4.3-796c0, libghc-ghc-compact-dev (= 0.1.0.0), libghc-ghc-compact-dev-0.1.0.0-cc5a7, libghc-ghc-dev-8.4.3-d21e3, libghc-ghc-prim-dev (= 0.5.2.0), libghc-ghc-prim-dev-0.5.2.0-39dc2, libghc-ghci-dev (= 8.4.3), libghc-ghci-dev-8.4.3-44bc3, libghc-haskeline-dev (= 0.7.4.2), libghc-haskeline-dev-0.7.4.2-5a0ca, libghc-hpc-dev (= 0.6.0.3), libghc-hpc-dev-0.6.0.3-832fb, libghc-integer-gmp-dev (= 1.0.2.0), libghc-integer-gmp-dev-1.0.2.0-8c626, libghc-mtl-dev (= 2.2.2), libghc-mtl-dev-2.2.2-3cf3b, libghc-parsec-dev-3.1.13.0-a9638, libghc-parsec3-dev (= 3.1.13.0), libghc-pretty-dev (= 1.1.3.6), libghc-pretty-dev-1.1.3.6-24259, libghc-process-dev (= 1.6.3.0), libghc-process-dev-1.6.3.0-abb0c, libghc-rts-dev (= 1.0), libghc-rts-dev-1.0-, libghc-stm-dev (= 2.4.5.0), libghc-stm-dev-2.4.5.0-cd8cc, libghc-template-haskell-dev (= 2.13.0.0), libghc-template-haskell-dev-2.13.0.0-1ce4a, libghc-terminfo-dev (= 0.4.1.1), libghc-terminfo-dev-0.4.1.1-80248, libghc-text-dev (= 1.2.3.0), libghc-text-dev-1.2.3.0-be4c3, libghc-time-dev (= 1.8.0.2), libghc-time-dev-1.8.0.2-97696, libghc-transformers-dev (= 0.5.5.0), libghc-transformers-dev-0.5.5.0-633c3, libghc-unix-dev (= 2.7.2.2), libghc-unix-dev-2.7.2.2-5200b, libghc-xhtml-dev (= 3000.2.2.1), libghc-xhtml-dev-3000.2.2.1-59af4
Section: haskell
Priority: optional
Homepage: https://haskell.org/ghc/
Description: The Glasgow Haskell Compilation system
The Glorious Glasgow Haskell Compilation system (GHC) is a compiler for
Haskell.
.
Haskell is "the" standard lazy functional programming language. The language
definition and additional documentation can be found in the `haskell-doc'
package. Alternatively, there is an online version at
http://haskell.org/onlinereport/.
-------------- next part --------------
new Debian package, version 2.0.
size 44845756 bytes: control archive=33848 bytes.
2969 bytes, 25 lines control
114317 bytes, 1362 lines md5sums
Package: ghc-prof
Source: ghc
Version: 8.4.3+dfsg1-3
Architecture: amd64
Maintainer: Debian Haskell Group <pkg-haskell-maintainers at lists.alioth.debian.org>
Installed-Size: 562744
Depends: ghc (= 8.4.3+dfsg1-3)
Conflicts: ghc6-prof (<< 7)
Replaces: ghc6-prof (<< 7)
Provides: libghc-array-prof (= 0.5.2.0), libghc-array-prof-0.5.2.0-001d5, libghc-base-prof (= 4.11.1.0), libghc-base-prof-4.11.1.0-9da3f, libghc-binary-prof (= 0.8.5.1), libghc-binary-prof-0.8.5.1-758db, libghc-bytestring-prof (= 0.10.8.2), libghc-bytestring-prof-0.10.8.2-76943, libghc-cabal-prof (= 2.2.0.1), libghc-cabal-prof-2.2.0.1-cb731, libghc-containers-prof (= 0.5.11.0), libghc-containers-prof-0.5.11.0-77951, libghc-deepseq-prof (= 1.4.3.0), libghc-deepseq-prof-1.4.3.0-00d8f, libghc-directory-prof (= 1.3.1.5), libghc-directory-prof-1.3.1.5-e563d, libghc-filepath-prof (= 1.4.2), libghc-filepath-prof-1.4.2-f8b35, libghc-ghc-boot-prof (= 8.4.3), libghc-ghc-boot-prof-8.4.3-8ac28, libghc-ghc-boot-th-prof (= 8.4.3), libghc-ghc-boot-th-prof-8.4.3-796c0, libghc-ghc-compact-prof (= 0.1.0.0), libghc-ghc-compact-prof-0.1.0.0-cc5a7, libghc-ghc-prim-prof (= 0.5.2.0), libghc-ghc-prim-prof-0.5.2.0-39dc2, libghc-ghc-prof-8.4.3-d21e3, libghc-ghci-prof (= 8.4.3), libghc-ghci-prof-8.4.3-44bc3, libghc-haskeline-prof (= 0.7.4.2), libghc-haskeline-prof-0.7.4.2-5a0ca, libghc-hpc-prof (= 0.6.0.3), libghc-hpc-prof-0.6.0.3-832fb, libghc-integer-gmp-prof (= 1.0.2.0), libghc-integer-gmp-prof-1.0.2.0-8c626, libghc-mtl-prof (= 2.2.2), libghc-mtl-prof-2.2.2-3cf3b, libghc-parsec-prof-3.1.13.0-a9638, libghc-parsec3-prof (= 3.1.13.0), libghc-pretty-prof (= 1.1.3.6), libghc-pretty-prof-1.1.3.6-24259, libghc-process-prof (= 1.6.3.0), libghc-process-prof-1.6.3.0-abb0c, libghc-rts-prof (= 1.0), libghc-rts-prof-1.0-, libghc-stm-prof (= 2.4.5.0), libghc-stm-prof-2.4.5.0-cd8cc, libghc-template-haskell-prof (= 2.13.0.0), libghc-template-haskell-prof-2.13.0.0-1ce4a, libghc-terminfo-prof (= 0.4.1.1), libghc-terminfo-prof-0.4.1.1-80248, libghc-text-prof (= 1.2.3.0), libghc-text-prof-1.2.3.0-be4c3, libghc-time-prof (= 1.8.0.2), libghc-time-prof-1.8.0.2-97696, libghc-transformers-prof (= 0.5.5.0), libghc-transformers-prof-0.5.5.0-633c3, libghc-unix-prof (= 2.7.2.2), libghc-unix-prof-2.7.2.2-5200b, libghc-xhtml-prof (= 3000.2.2.1), libghc-xhtml-prof-3000.2.2.1-59af4
Section: haskell
Priority: optional
Homepage: https://haskell.org/ghc/
Description: Profiling libraries for the Glasgow Haskell Compilation system
The Glorious Glasgow Haskell Compilation system (GHC) is a compiler for
Haskell.
.
Haskell is "the" standard lazy functional programming language. The language
definition and additional documentation can be found in the `haskell-doc'
package. Alternatively, there is an online version at
http://haskell.org/onlinereport/.
.
This package contains additional profiling libraries. They are only needed,
if you want to take a closer look on where exactly your program burns CPU
cycles.
-------------- next part --------------
new Debian package, version 2.0.
size 14763232 bytes: control archive=77352 bytes.
2106 bytes, 27 lines control
380105 bytes, 3536 lines md5sums
1399 bytes, 44 lines * postinst #!/bin/sh
466 bytes, 21 lines * preinst #!/bin/sh
1420 bytes, 43 lines * prerm #!/bin/sh
87 bytes, 2 lines triggers
Package: ghc-doc
Source: ghc
Version: 8.4.3+dfsg1-3
Architecture: all
Maintainer: Debian Haskell Group <pkg-haskell-maintainers at lists.alioth.debian.org>
Installed-Size: 228704
Pre-Depends: dpkg (>= 1.16.1)
Depends: haddock-interface-33, perl, libjs-mathjax
Suggests: haskell-doc
Conflicts: ghc (<= 7.0.3-1), ghc6-doc (<< 7)
Breaks: libghc-terminfo-doc (<< 0.3.2.5-4), libghc-transformers-doc (<< 0.3.0.0-6), libghc-xhtml-doc (<< 3000.2.1-5)
Replaces: ghc6-doc (<< 7), libghc-terminfo-doc (<< 0.3.2.5-4), libghc-transformers-doc (<< 0.3.0.0-6), libghc-xhtml-doc (<< 3000.2.1-5)
Provides: libghc-array-doc (= 0.5.2.0), libghc-base-doc (= 4.11.1.0), libghc-binary-doc (= 0.8.5.1), libghc-bytestring-doc (= 0.10.8.2), libghc-cabal-doc (= 2.2.0.1), libghc-containers-doc (= 0.5.11.0), libghc-deepseq-doc (= 1.4.3.0), libghc-directory-doc (= 1.3.1.5), libghc-filepath-doc (= 1.4.2), libghc-ghc-boot-doc (= 8.4.3), libghc-ghc-boot-th-doc (= 8.4.3), libghc-ghc-compact-doc (= 0.1.0.0), libghc-ghc-prim-doc (= 0.5.2.0), libghc-ghci-doc (= 8.4.3), libghc-haskeline-doc (= 0.7.4.2), libghc-hpc-doc (= 0.6.0.3), libghc-integer-gmp-doc (= 1.0.2.0), libghc-mtl-doc (= 2.2.2), libghc-parsec3-doc (= 3.1.13.0), libghc-pretty-doc (= 1.1.3.6), libghc-process-doc (= 1.6.3.0), libghc-rts-doc (= 1.0), libghc-stm-doc (= 2.4.5.0), libghc-template-haskell-doc (= 2.13.0.0), libghc-terminfo-doc (= 0.4.1.1), libghc-text-doc (= 1.2.3.0), libghc-time-doc (= 1.8.0.2), libghc-transformers-doc (= 0.5.5.0), libghc-unix-doc (= 2.7.2.2), libghc-xhtml-doc (= 3000.2.2.1)
Section: doc
Priority: optional
Homepage: https://haskell.org/ghc/
Description: Documentation for the Glasgow Haskell Compilation system
The Glorious Glasgow Haskell Compilation system (GHC) is a compiler for
Haskell.
.
Haskell is "the" standard lazy functional programming language. The language
definition and additional documentation can be found in the `haskell-doc'
package. Alternatively, there is an online version at
http://haskell.org/onlinereport/.
.
This package includes HTML, DVI and PS versions of the SGML-based
documentation around GHC.
More information about the Pkg-haskell-maintainers
mailing list