Hi,

I have uploaded the proposed change (also attached to this mail) to
DELAYED/5 in accordance with DevRef. Please let me know if I should
delay it any longer.

Helmut
diff --minimal -Nru gzip-1.12/debian/changelog gzip-1.12/debian/changelog
--- gzip-1.12/debian/changelog  2022-04-10 04:22:26.000000000 +0200
+++ gzip-1.12/debian/changelog  2024-03-09 18:04:58.000000000 +0100
@@ -1,3 +1,10 @@
+gzip (1.12-1.1) sid; urgency=medium
+
+  * Non-maintainer upload.
+  * Move files to /usr (closes: #1059533)
+
+ -- Helmut Grohne <hel...@subdivi.de>  Sat, 09 Mar 2024 18:04:58 +0100
+
 gzip (1.12-1) sid; urgency=high
 
   * new upstream release
diff --minimal -Nru gzip-1.12/debian/control gzip-1.12/debian/control
--- gzip-1.12/debian/control    2022-04-10 04:05:08.000000000 +0200
+++ gzip-1.12/debian/control    2024-03-09 18:04:57.000000000 +0100
@@ -16,6 +16,7 @@
 Pre-Depends: ${shlibs:Depends}
 Depends: dpkg (>= 1.15.4) | install-info
 Suggests: less
+Conflicts: zutils (<< 1.13-2~)
 Description: GNU compression utilities
  This package provides the standard GNU file compression utilities, which
  are also the default compression tools for Debian.  They typically operate
diff --minimal -Nru gzip-1.12/debian/dirs gzip-1.12/debian/dirs
--- gzip-1.12/debian/dirs       2022-04-09 04:15:18.000000000 +0200
+++ gzip-1.12/debian/dirs       2024-03-09 18:04:57.000000000 +0100
@@ -1,3 +1,2 @@
-bin
 usr/share/info
 usr/share/man/man1
diff --minimal -Nru gzip-1.12/debian/gzip.postinst 
gzip-1.12/debian/gzip.postinst
--- gzip-1.12/debian/gzip.postinst      1970-01-01 01:00:00.000000000 +0100
+++ gzip-1.12/debian/gzip.postinst      2024-03-09 18:04:57.000000000 +0100
@@ -0,0 +1,22 @@
+#!/bin/sh
+
+set -e
+
+# begin-remove-after: released:forky
+if [ "$1" = configure ]; then
+       for tool in zcat zcmp zdiff zegrep zfgrep zgrep; do
+               if [ "$(dpkg-divert --truename "/usr/bin/$tool")" = 
"/usr/bin/$tool.usr-is-merged" ] &&
+                       [ "$(dpkg-divert --listpackage "/usr/bin/$tool")" = 
zutils ]; then
+                       # This diversion was added by preinst and. This
+                       # indicates that zutils was unpacked at preinst time
+                       # and is now removed. Thus we clean up the diversion.
+                       echo "Removing duplicated diversion of /bin/$tool after 
zutils is removed."
+                       dpkg-divert --rename --package zutils \
+                               --divert "/usr/bin/$tool.usr-is-merged" \
+                               --remove "/usr/bin/$tool"
+               fi
+       done
+fi
+# end-remove-after
+
+#DEBHELPER#
diff --minimal -Nru gzip-1.12/debian/gzip.preinst gzip-1.12/debian/gzip.preinst
--- gzip-1.12/debian/gzip.preinst       1970-01-01 01:00:00.000000000 +0100
+++ gzip-1.12/debian/gzip.preinst       2024-03-09 18:04:57.000000000 +0100
@@ -0,0 +1,22 @@
+#!/bin/sh
+
+set -e
+
+# begin-remove-after: released:forky
+if [ "$1" = upgrade ] || [ "$1" = install ]; then
+       for tool in zcat zcmp zdiff zegrep zfgrep zgrep; do
+               if [ "$(dpkg-divert --truename "/bin/$tool")" = 
"/bin/$tool.gzip" ] &&
+                       [ "$(dpkg-divert --listpackage "/bin/$tool")" = zutils 
] &&
+                       [ "$(dpkg-divert --truename "/usr/bin/$tool")" = 
"/usr/bin/$tool" ]; then
+                       # A pre-/usr-move diversion is installed by zutils.
+                       echo "Mitigating diversion of /bin/$tool on behalf of 
zutils"
+                       dpkg-divert --no-rename --package zutils \
+                               --divert "/usr/bin/$tool.usr-is-merged" \
+                               --add "/usr/bin/$tool"
+               fi
+       done
+fi
+# end-remove-after
+
+
+#DEBHELPER#
diff --minimal -Nru gzip-1.12/debian/rules gzip-1.12/debian/rules
--- gzip-1.12/debian/rules      2022-04-09 04:15:18.000000000 +0200
+++ gzip-1.12/debian/rules      2024-03-09 18:04:57.000000000 +0100
@@ -47,9 +47,9 @@
 _topdir=$(call shellescape,$(shell pwd))
 
 CONFIGURE_ARGS=                --prefix=/usr \
-                       --bindir=/bin \
-                       --infodir=${_topdir}/debian/gzip/usr/share/info \
-                       --mandir=${_topdir}/debian/gzip/usr/share/man \
+                       --bindir=/usr/bin \
+                       --infodir=/usr/share/info \
+                       --mandir=/usr/share/man \
                        --disable-silent-rules
 
 ifneq (${DEB_BUILD_ARCH},${DEB_HOST_ARCH})
@@ -130,9 +130,7 @@
        dh_testroot
        dh_prep
        dh_installdirs
-       ${MAKE} -C builddir install \
-           prefix=${_topdir}/debian/gzip/usr \
-           bindir=${_topdir}/debian/gzip/bin
+       ${MAKE} -C builddir install DESTDIR=${_topdir}/debian/gzip
        dh_testdir -a
        dh_testroot -a
        dh_installdocs -a README* TODO NEWS

Reply via email to