packaging updates from mksh:
authortg <tg@mirbsd.org>
Sun, 4 Dec 2011 14:45:59 +0000 (14:45 +0000)
committertg <tg@mirbsd.org>
Sun, 4 Dec 2011 14:45:59 +0000 (14:45 +0000)
• use dh_prep if it exists
• update maintainer scripts from jupp
• nicer comment in source.lintian-overrides

debian/changelog
debian/postinst
debian/postrm
debian/rules
debian/source.lintian-overrides

index 0f69f0d..69097e0 100644 (file)
@@ -1,10 +1,12 @@
 cvs (2:1.12.13+real-7) xunstable; urgency=low
 
   * Add lintian override for rcslock contrib script
-  * debian/rules: cleanup (remove install/check, dh_installdirs)
+  * debian/rules: cleanup (remove install/check, dh_installdirs;
+    switch to dh_prep if extant)
   * Use -Wl,--as-needed for the link to appease dpkg-shlibdebs
+  * Update maintainer scripts from template jupp (better comments)
 
- -- Thorsten Glaser <tg@mirbsd.de>  Sat, 12 Nov 2011 00:05:27 +0000
+ -- Thorsten Glaser <tg@mirbsd.de>  Sun, 04 Dec 2011 14:45:09 +0000
 
 cvs (2:1.12.13+real-6) unstable; urgency=low
 
index a342b42..7c15325 100644 (file)
@@ -1,12 +1,32 @@
-#! /bin/sh
-# $MirOS: contrib/hosted/tg/deb/cvs/debian/postinst,v 1.3 2010/09/19 18:47:49 tg Exp $
+#!/bin/sh
+# $MirOS: contrib/hosted/tg/deb/cvs/debian/postinst,v 1.4 2011/12/04 14:45:58 tg Exp $
 
 set -e
 
+# This maintainer script can be called the following ways:
+#
+# * new-postinst "configure" [$most_recently_configured_version]
+# The package is unpacked; all dependencies are unpacked and, when there
+# are no circular dependencies, configured.
+#
+# * old-postinst "abort-upgrade" $new_version
+# * conflictors-postinst "abort-remove" "in-favour" $package
+#      $new_version
+# * postinst "abort-remove"
+# * deconfigureds-postinst "abort-deconfigure" "in-favour"
+#      $failed_install_package $fip_version ["removing"
+#      $conflicting_package $cp_version]
+# The package is unpacked; all dependencies are at least Half-Installed,
+# previously been configured, and not removed. In some error situations,
+# dependencies may not be even fully unpacked.
+#
+# * postinst "triggered" "${triggers[*]}"
+# For trigger-only calls, i.e. if "configure" is not called.
+
 # upgrade case from Debian CVS
 nukes='/etc/cvs.conf /etc/cvs-cron.conf /etc/cvs-pserver.conf /etc/cron.weekly/cvs'
 for x in $nukes; do
-       test -e $x || continue
+       test -e "$x" || continue
        rm -f $nukes
        test -x /usr/sbin/update-inetd && update-inetd --remove "^cvspserver"
        break
@@ -20,8 +40,11 @@ configure)
 abort-upgrade|abort-remove|abort-deconfigure)
        ;;
 
+triggered)
+       ;;
+
 *)
-       echo "postinst called with unknown argument '$1'" >&2
+       echo >&2 "postinst called with unknown subcommand '$1'"
        exit 1
        ;;
 esac
index a675a95..156587f 100644 (file)
@@ -1,20 +1,42 @@
-#! /bin/sh
-# $MirOS: contrib/hosted/tg/deb/cvs/debian/postrm,v 1.3 2011/06/11 04:22:48 tg Exp $
+#!/bin/sh
+# $MirOS: contrib/hosted/tg/deb/cvs/debian/postrm,v 1.4 2011/12/04 14:45:59 tg Exp $
 
 set -e
 
+# This maintainer script can be called the following ways:
+#
+# * postrm "remove"
+# * postrm "purge"
+# * old-postrm "upgrade" $new_version
+# * disappearers-postrm "disappear" $overwriter $o_version
+# The package's files have been removed or replaced; only Essential pak-
+# kages may be available; skip gracefully actions requiring Depends.
+#
+# * new-postrm "failed-upgrade" $old_version
+# Called when 'old-postrm "upgrade"' fails; the new package is unpacked,
+# Essential packages and Pre-Depends are available; the latter have been
+# configured and never removed but may be Unpacked or Half-Configured.
+#
+# * new-postrm "abort-install" [$old_version]
+# * new-postrm "abort-upgrade" $old_version
+# Called when preinst fails; package is not unpacked. Essential packages
+# and (unpacked or Half-Configured) Pre-Depends are available.
+
 case $1 in
+remove)
+       ;;
+
 purge)
        rm -f /etc/cvs.conf /etc/cvs-cron.conf /etc/cvs-pserver.conf /etc/cron.weekly/cvs
        test -x /usr/sbin/update-inetd && update-inetd --remove "^cvspserver"
        (delgroup --system --only-if-empty _cvsadmin || :)
        ;;
 
-remove|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear)
+upgrade|disappear|failed-upgrade|abort-install|abort-upgrade)
        ;;
 
 *)
-       echo >&2 "postrm called with unknown argument '$1'"
+       echo >&2 "postrm called with unknown subcommand '$1'"
        exit 1
        ;;
 esac
index 01426b2..2e1b3fd 100755 (executable)
@@ -1,5 +1,5 @@
 #!/usr/bin/make -f
-# $MirOS: contrib/hosted/tg/deb/cvs/debian/rules,v 1.11 2011/11/12 00:11:22 tg Exp $
+# $MirOS: contrib/hosted/tg/deb/cvs/debian/rules,v 1.12 2011/12/04 14:45:59 tg Exp $
 #-
 # -*- makefile -*-
 # Sample debian/rules that uses debhelper.
@@ -101,7 +101,7 @@ clean:
 debian/.install_stamp: debian/.build_stamp
        dh_testdir
        dh_testroot
-       dh_clean -k
+       if test -x "$$(which dh_prep)"; then dh_prep; else dh_clean -k; fi
        -rm -rf debian/stagedir
        mkdir -p debian/stagedir/clogs
        cd debian/builddir && \
index e6a0be9..d7eb776 100644 (file)
@@ -1,7 +1,8 @@
-# $MirOS: contrib/hosted/tg/deb/cvs/debian/source.lintian-overrides,v 1.3 2011/05/06 23:46:19 tg Exp $
+# $MirOS: contrib/hosted/tg/deb/cvs/debian/source.lintian-overrides,v 1.4 2011/12/04 14:45:59 tg Exp $
 
-# we know, who cares, this is the way this package works
-cvs source: direct-changes-in-diff-but-no-patch-system *
+# desired method of keeping changes is CVS
+# as long as etch backports are required
+#mksh source: direct-changes-in-diff-but-no-patch-system *
 
 # not my fault
 cvs source: source-contains-cvs-control-dir zlib/CVS