On Tue, Jun 12, 2012 at 08:12:05PM -0300, Daniel Kahn Gillmor wrote: > I'd prefer a conversion to dh, so that i don't have to maintain the > duplication of dh_installcatalogs.
Thanks for your quick reply. I did the conversion and attached a debdiff. Some remarks: * Build depend on the first version of debhelper, that closes #477751. * Things that "just work" (such as dh_installman, dh_installdocs) were converted. * Other things were retained (dh_compress only compresses big files). * dh_installcatatalogs creates a conffile in /etc/sgml, thus we solve #656170. * I verified that 1.36-2.1 installs and purges cleanly. * I verified that it upgrades cleanly from 1.36-2. * I verified that only gzip compressed files differ. * The diff reduces 30 lines (if you exclude changelog). :-) Please review my changes. Can I also ask you to upload them? Helmut
diff -Nru xml2rfc-1.36/debian/changelog xml2rfc-1.36/debian/changelog --- xml2rfc-1.36/debian/changelog 2012-01-17 06:07:41.000000000 +0100 +++ xml2rfc-1.36/debian/changelog 2012-06-15 18:00:33.000000000 +0200 @@ -1,3 +1,11 @@ +xml2rfc (1.36-2.1) unstable; urgency=low + + * Non-maintainer upload. + * Convert to debhelper 9. + * Especially use dh_installcatalogs. (Closes: #674911, #656170) + + -- Helmut Grohne <hel...@subdivi.de> Fri, 15 Jun 2012 16:53:42 +0200 + xml2rfc (1.36-2) unstable; urgency=low * added postrm script to purge /etc/sgml/xml2rfc.cat{,.old} diff -Nru xml2rfc-1.36/debian/compat xml2rfc-1.36/debian/compat --- xml2rfc-1.36/debian/compat 1970-01-01 01:00:00.000000000 +0100 +++ xml2rfc-1.36/debian/compat 2012-06-15 18:00:21.000000000 +0200 @@ -0,0 +1 @@ +9 diff -Nru xml2rfc-1.36/debian/control xml2rfc-1.36/debian/control --- xml2rfc-1.36/debian/control 2011-11-18 22:35:03.000000000 +0100 +++ xml2rfc-1.36/debian/control 2012-06-15 18:00:17.000000000 +0200 @@ -1,13 +1,14 @@ Source: xml2rfc Section: non-free/text Priority: optional +Build-Depends: debhelper (>= 9.20120528) Maintainer: Daniel Kahn Gillmor <d...@fifthhorseman.net> Standards-Version: 3.9.2 Homepage: http://xml.resource.org/ Package: xml2rfc Architecture: all -Depends: tcl8.5 | tclsh, sgml-base +Depends: tcl8.5 | tclsh, ${misc:Depends} Suggests: wish Description: XML-based formatting tool for RFCs This package provides xml2rfc, a tool which creates text, HTML and diff -Nru xml2rfc-1.36/debian/postinst xml2rfc-1.36/debian/postinst --- xml2rfc-1.36/debian/postinst 2011-11-18 22:35:03.000000000 +0100 +++ xml2rfc-1.36/debian/postinst 1970-01-01 01:00:00.000000000 +0100 @@ -1,10 +0,0 @@ -#!/bin/sh -set -e -if [ "$1" = configure ] -then - CENCAT=/etc/sgml/xml2rfc.cat - ORDCAT=/usr/share/sgml/xml2rfc/catalog - update-catalog --add $CENCAT $ORDCAT - update-catalog --add --super $CENCAT -fi -exit 0 diff -Nru xml2rfc-1.36/debian/postrm xml2rfc-1.36/debian/postrm --- xml2rfc-1.36/debian/postrm 2012-01-17 06:03:15.000000000 +0100 +++ xml2rfc-1.36/debian/postrm 1970-01-01 01:00:00.000000000 +0100 @@ -1,8 +0,0 @@ -#!/bin/sh -set -e -if [ "$1" = purge ] -then - CENCAT=/etc/sgml/xml2rfc.cat - rm -f ${CENCAT} ${CENCAT}.old -fi -exit 0 diff -Nru xml2rfc-1.36/debian/prerm xml2rfc-1.36/debian/prerm --- xml2rfc-1.36/debian/prerm 2011-11-18 22:35:03.000000000 +0100 +++ xml2rfc-1.36/debian/prerm 1970-01-01 01:00:00.000000000 +0100 @@ -1,10 +0,0 @@ -#!/bin/sh -set -e -if [ "$1" = remove ] -then - CENCAT=/etc/sgml/xml2rfc.cat - ORDCAT=/usr/share/sgml/xml2rfc/catalog - update-catalog --remove --super $CENCAT - update-catalog --remove $CENCAT $ORDCAT -fi -exit 0 diff -Nru xml2rfc-1.36/debian/rules xml2rfc-1.36/debian/rules --- xml2rfc-1.36/debian/rules 2012-01-17 06:07:03.000000000 +0100 +++ xml2rfc-1.36/debian/rules 2012-06-15 17:32:24.000000000 +0200 @@ -1,6 +1,6 @@ #!/usr/bin/make -f -STAGING = debian/tmp +STAGING = debian/xml2rfc DOCDIR_REL = usr/share/doc/xml2rfc DOCDIR = $(STAGING)/$(DOCDIR_REL) @@ -13,47 +13,40 @@ touch build-stamp clean: - -rm -f build-stamp debian/files - -rm -rf $(STAGING) + rm -f build-stamp + dh_clean install: build rm -rf $(STAGING) - install -d $(STAGING)/DEBIAN install -d $(STAGING)/usr/bin - install -d $(STAGING)/usr/share/man/man1 install -d $(STAGING)/usr/share/sgml/xml2rfc/dtd install -d $(DOCDIR)/examples - install -m 755 debian/postinst $(STAGING)/DEBIAN/ - install -m 755 debian/prerm $(STAGING)/DEBIAN/ - install -m 755 debian/postrm $(STAGING)/DEBIAN/ - - install -m 644 debian/copyright $(DOCDIR)/ - install -m 644 debian/changelog $(DOCDIR)/changelog.Debian - gzip -9 $(DOCDIR)/changelog.Debian install -m 644 *.txt *.html $(DOCDIR) - install -m 644 debian/IETF-Trust-License-Policy.txt $(DOCDIR) gzip -9 $(DOCDIR)/*.txt $(DOCDIR)/*.html install -m 644 *.xml $(DOCDIR)/examples gzip -9 $(DOCDIR)/examples/* install -m 755 xml2rfc.tcl $(STAGING)/usr/bin/xml2rfc - install -m 644 debian/xml2rfc.1 $(STAGING)/usr/share/man/man1/ - gzip -9 $(STAGING)/usr/share/man/man1/xml2rfc.1 - install -m 644 debian/catalog $(STAGING)/usr/share/sgml/xml2rfc/ install -m 644 rfc2629.dtd $(STAGING)/usr/share/sgml/xml2rfc/dtd/ install -m 644 rfc2629-xhtml.ent $(STAGING)/usr/share/sgml/xml2rfc/dtd/ install -m 644 rfc2629-other.ent $(STAGING)/usr/share/sgml/xml2rfc/dtd/ + dh_installdocs + dh_installchangelogs + dh_installman + dh_installcatalogs + dh_compress + dh_fixperms # Build architecture-independent files here. binary-indep: build install - dpkg-gencontrol -isp -pxml2rfc - chown -R root.root $(STAGING) - chmod -R g-ws $(STAGING) - dpkg --build debian/tmp .. + dh_installdeb + dh_gencontrol + dh_md5sums + dh_builddeb # Build architecture-dependent files here. diff -Nru xml2rfc-1.36/debian/xml2rfc.docs xml2rfc-1.36/debian/xml2rfc.docs --- xml2rfc-1.36/debian/xml2rfc.docs 1970-01-01 01:00:00.000000000 +0100 +++ xml2rfc-1.36/debian/xml2rfc.docs 2012-06-15 17:27:55.000000000 +0200 @@ -0,0 +1 @@ +debian/IETF-Trust-License-Policy.txt diff -Nru xml2rfc-1.36/debian/xml2rfc.manpages xml2rfc-1.36/debian/xml2rfc.manpages --- xml2rfc-1.36/debian/xml2rfc.manpages 1970-01-01 01:00:00.000000000 +0100 +++ xml2rfc-1.36/debian/xml2rfc.manpages 2012-06-15 17:19:27.000000000 +0200 @@ -0,0 +1 @@ +debian/xml2rfc.1 diff -Nru xml2rfc-1.36/debian/xml2rfc.sgmlcatalogs xml2rfc-1.36/debian/xml2rfc.sgmlcatalogs --- xml2rfc-1.36/debian/xml2rfc.sgmlcatalogs 1970-01-01 01:00:00.000000000 +0100 +++ xml2rfc-1.36/debian/xml2rfc.sgmlcatalogs 2012-06-15 17:23:24.000000000 +0200 @@ -0,0 +1 @@ +debian/catalog /usr/share/sgml/xml2rfc/catalog