Package: echolot Version: 2.1.8-6 Severity: serious Tags: patch Dear Maintainer,
Andreas Beckmann <deb...@abeckmann.de> reported in -devel that your package (as well as 27 others) ships a folder either in /var/run or /var/lock. This is forbidden by policy. Lintian detects the problem and warns as follow: /var/run may be a temporary filesystem, so any directories or files needed /there must be created dynamically at boot time. Refer to Debian Policy Manual section 9.3.2 (Writing the scripts) for details. Severity: serious, Certainty: possible Check: files, Type: binary, udeb which is why I am reporting this bug with severity serious (and there fore, release critical). Please fix your package. I have attached what I believe is a good fix the problem, however, I haven't tried it, and I haven't tested if something more for creating the necessary folder at runtime should be added. Please make sure to test before applying the patch blindly. Cheers, Thomas Goirand (zigo)
diff -u echolot-2.1.8/debian/changelog echolot-2.1.8/debian/changelog --- echolot-2.1.8/debian/changelog +++ echolot-2.1.8/debian/changelog @@ -1,3 +1,10 @@ +echolot (2.1.8-6.1) UNRELEASED; urgency=low + + * Non-maintainer upload. + * Fixes handling of the /var/run/echolot folder life cycle (Closes: #XXXXXX). + + -- Thomas Goirand <z...@debian.org> Sat, 06 Oct 2012 16:59:36 +0800 + echolot (2.1.8-6) unstable; urgency=low * In postrm during purge remove (rm -rf) /var/lib/echolot instead of diff -u echolot-2.1.8/debian/echolot.init echolot-2.1.8/debian/echolot.init --- echolot-2.1.8/debian/echolot.init +++ echolot-2.1.8/debian/echolot.init @@ -25,7 +25,8 @@ # You probably don't want to mess with stuff below this line ################################################################ -PIDFILE=/var/run/echolot/pingd.pid +RUNFLD=/var/run/echolot +PIDFILE=${RUNFLD}/pingd.pid CHECKULIMIT=1 CHECKUID=1 USER=echolot @@ -41,6 +42,13 @@ # Reads config file (will override defaults above) [ -r /etc/default/echolot ] && . /etc/default/echolot +if [ ! -d ${RUNFLD} ] ; then + mkdir -p ${RUNFLD} || true + if [ -d ${RUNFLD} ] ; then + chown ${USER}:${GROUP} ${RUNFLD} + chmod 02770 ${RUNFLD} + fi +fi wait_for_deaddaemon () { PID=$1 diff -u echolot-2.1.8/debian/echolot.postinst echolot-2.1.8/debian/echolot.postinst --- echolot-2.1.8/debian/echolot.postinst +++ echolot-2.1.8/debian/echolot.postinst @@ -30,10 +30,6 @@ if ( ! dpkg-statoverride --list /var/lib/echolot > /dev/null ); then dpkg-statoverride --update --add root echolot 02775 /var/lib/echolot fi -# and /var/run/echolot -if ( ! dpkg-statoverride --list /var/run/echolot > /dev/null ); then - dpkg-statoverride --update --add root echolot 02770 /var/run/echolot -fi #DEBHELPER# diff -u echolot-2.1.8/debian/echolot.postrm echolot-2.1.8/debian/echolot.postrm --- echolot-2.1.8/debian/echolot.postrm +++ echolot-2.1.8/debian/echolot.postrm @@ -6,6 +6,7 @@ purge) rm -rf /var/lib/echolot rm -rf /var/log/echolot + rm -rf /var/run/echolot rmdir /etc/echolot/templates 2>/dev/null || true rmdir /etc/echolot 2>/dev/null || true dpkg-statoverride --remove /var/run/echolot >/dev/null 2>&1 || true only in patch2: unchanged: --- echolot-2.1.8.orig/debian/echolot.dirs +++ echolot-2.1.8/debian/echolot.dirs @@ -1,7 +1,6 @@ usr/bin usr/share/perl5 var/lib/echolot -var/run/echolot var/log/echolot etc/echolot etc/default