Package: release.debian.org Severity: normal User: release.debian....@packages.debian.org Usertags: unblock
Hi, I have fixed #767646, concerning non-policy compliance of the CONFFILE handling in postinst. Now the /etc/miniupnpd/miniupnpd.conf is copied form /usr/share in the postinst instead of being a CONFFILE. Also, I fixed the fact that the default file was copied from /usr/share/doc instead of /usr/share/miniupnpd. The debdiff is attached. Please unblock package miniupnpd/1.8.20140523-3
diff -Nru miniupnpd-1.8.20140523/debian/changelog miniupnpd-1.8.20140523/debian/changelog --- miniupnpd-1.8.20140523/debian/changelog 2014-07-14 07:09:06.000000000 +0000 +++ miniupnpd-1.8.20140523/debian/changelog 2014-11-04 09:01:40.000000000 +0000 @@ -1,3 +1,12 @@ +miniupnpd (1.8.20140523-3) unstable; urgency=medium + + * Do not install the configuration file in /etc/miniupnpd, use /usr/share + instead, so that miniupnpd.conf isn't CONFFILE (Closes: #767646). + * Do not use /usr/share/doc/miniupnpd/examples to get our default config + file, which isn't policy compliant, but use /usr/share/miniupnpd. + + -- Thomas Goirand <z...@debian.org> Tue, 04 Nov 2014 16:35:36 +0800 + miniupnpd (1.8.20140523-2) unstable; urgency=medium * Removed $all from init script. diff -Nru miniupnpd-1.8.20140523/debian/miniupnpd.config miniupnpd-1.8.20140523/debian/miniupnpd.config --- miniupnpd-1.8.20140523/debian/miniupnpd.config 2014-07-14 07:09:06.000000000 +0000 +++ miniupnpd-1.8.20140523/debian/miniupnpd.config 2014-11-04 09:01:40.000000000 +0000 @@ -10,9 +10,9 @@ if [ -r /etc/default/miniupnpd ] ; then . /etc/default/miniupnpd else - if [ -r /usr/share/doc/miniupnpd/examples/miniupnpd.default ] ; then + if [ -r /usr/share/miniupnpd/miniupnpd.default ] ; then if ! [ -e /etc/default/miniupnpd ] ; then - cp /usr/share/doc/miniupnpd/examples/miniupnpd.default /etc/default/miniupnpd + cp /usr/share/miniupnpd/miniupnpd.default /etc/default/miniupnpd fi fi fi diff -Nru miniupnpd-1.8.20140523/debian/miniupnpd.postinst miniupnpd-1.8.20140523/debian/miniupnpd.postinst --- miniupnpd-1.8.20140523/debian/miniupnpd.postinst 2014-07-14 07:09:06.000000000 +0000 +++ miniupnpd-1.8.20140523/debian/miniupnpd.postinst 2014-11-04 09:01:40.000000000 +0000 @@ -32,8 +32,10 @@ echo "Something is wrong: /etc/miniupnpd exists, but is not a directory!" exit 1 fi + # Make sure we have a /etc/miniupnpd/miniupnpd.conf if ! [ -e ${CONFFILE} ] ; then - cp -f /usr/share/doc/miniupnpd/examples/miniupnpd.conf /etc/miniupnpd + mkdir -p /etc/miniupnpd + cp -f /usr/share/miniupnpd/miniupnpd.conf /etc/miniupnpd fi # This postinst will generate a random uuid for miniupnpd diff -Nru miniupnpd-1.8.20140523/debian/miniupnpd.postrm miniupnpd-1.8.20140523/debian/miniupnpd.postrm --- miniupnpd-1.8.20140523/debian/miniupnpd.postrm 2014-07-14 07:09:06.000000000 +0000 +++ miniupnpd-1.8.20140523/debian/miniupnpd.postrm 2014-11-04 09:01:40.000000000 +0000 @@ -6,6 +6,9 @@ if [ "$1" = "purge" ]; then rm -f /etc/miniupnpd/miniupnpd.conf rm -f /etc/default/miniupnpd + if [ -e /etc/miniupnpd ] ; then + rmdir --ignore-fail-on-non-empty /etc/miniupnpd || true + fi fi #DEBHELPER# diff -Nru miniupnpd-1.8.20140523/debian/rules miniupnpd-1.8.20140523/debian/rules --- miniupnpd-1.8.20140523/debian/rules 2014-07-14 07:09:06.000000000 +0000 +++ miniupnpd-1.8.20140523/debian/rules 2014-11-04 09:01:40.000000000 +0000 @@ -11,6 +11,12 @@ override_dh_auto_install: make -j1 -f Makefile.linux install DESTDIR=$(CURDIR)/debian/miniupnpd AM_UPDATE_INFO_DIR=no + # Move the miniupnpd.conf in /usr/share so it's not marked as CONFFILE + mkdir -p $(CURDIR)/debian/miniupnpd/usr/share/miniupnpd + mv $(CURDIR)/debian/miniupnpd/etc/miniupnpd/miniupnpd.conf $(CURDIR)/debian/miniupnpd/usr/share/miniupnpd/miniupnpd.conf + + # Copy the /etc/default/miniupnpd to /usr/share + cp $(CURDIR)/debian/examples/miniupnpd.default $(CURDIR)/debian/miniupnpd/usr/share/miniupnpd override_dh_auto_clean: #dh_auto_clean