Control: tags -1 + patch Hello!
Please see attached debdiff for my attempt at fixing this bug report as well as fixing up basic LSB compatibility of the init script. I'm not a user of live-tools so don't really know how it should work, but as I understood the init script I saw no point for it to be run in rcS as it does *nothing* on start. The only purpose for it is to run the live-media-eject command before shutdown, right?! I thus severely lowered the dependencies in live-tools.service and installed it in multi-user.target rather than sysinit.target. The only requirement left is that it's run before shutdown(.target). Feedback on the above would be much appreciated. Regards, Andreas Henriksson
diff -Nru live-tools-20151214/debian/changelog live-tools-20151214+nmu1/debian/changelog --- live-tools-20151214/debian/changelog 2015-12-14 17:14:10.000000000 +0100 +++ live-tools-20151214+nmu1/debian/changelog 2016-05-26 10:47:22.000000000 +0200 @@ -1,3 +1,14 @@ +live-tools (1:20151214+nmu1) UNRELEASED; urgency=medium + + * Non-maintainer upload. + * Add a native live-tools.service unit (Closes: #796627) + * Add dh-systemd build-dependency and use "--with systemd" for above. + * Source /lib/lsb/init-functions in init script + - fixes lintian warning: init.d-script-does-not-source-init-functions + * Add lsb-base dependency because of the above. + + -- Andreas Henriksson <andr...@fatal.se> Thu, 26 May 2016 10:37:09 +0200 + live-tools (1:20151214) unstable; urgency=medium [ Carlos Zuferri ] diff -Nru live-tools-20151214/debian/control live-tools-20151214+nmu1/debian/control --- live-tools-20151214/debian/control 2015-12-14 17:11:28.000000000 +0100 +++ live-tools-20151214+nmu1/debian/control 2016-05-26 10:46:55.000000000 +0200 @@ -5,6 +5,7 @@ Uploaders: Iain R. Learmonth <i...@debian.org> Build-Depends: debhelper (>= 9), + dh-systemd (>= 1.5), Standards-Version: 3.9.6 Homepage: https://debian-live.alioth.debian.org/live-tools/ Vcs-Browser: http://anonscm.debian.org/cgit/debian-live/live-tools.git @@ -13,6 +14,7 @@ Package: live-tools Architecture: all Depends: + lsb-base, initramfs-tools, ${misc:Depends}, Suggests: diff -Nru live-tools-20151214/debian/live-tools.init live-tools-20151214+nmu1/debian/live-tools.init --- live-tools-20151214/debian/live-tools.init 2015-12-14 17:09:42.000000000 +0100 +++ live-tools-20151214+nmu1/debian/live-tools.init 2016-05-26 10:41:52.000000000 +0200 @@ -16,6 +16,8 @@ # X-Interactive: true ### END INIT INFO +. /lib/lsb/init-functions + case "${1}" in stop) if [ -e /bin/live-media-eject ] diff -Nru live-tools-20151214/debian/live-tools.service live-tools-20151214+nmu1/debian/live-tools.service --- live-tools-20151214/debian/live-tools.service 1970-01-01 01:00:00.000000000 +0100 +++ live-tools-20151214+nmu1/debian/live-tools.service 2016-05-26 10:36:24.000000000 +0200 @@ -0,0 +1,14 @@ +[Unit] +Documentation=man:live-tools(7) +Description=live-tools - System Support Scripts +DefaultDependencies=no +Before=shutdown.target +Conflicts=shutdown.target + +[Service] +Type=oneshot +RemainAfterExit=yes +ExecStop=/bin/live-medium-eject + +[Install] +WantedBy=multi-user.target diff -Nru live-tools-20151214/debian/rules live-tools-20151214+nmu1/debian/rules --- live-tools-20151214/debian/rules 2015-12-14 17:09:08.000000000 +0100 +++ live-tools-20151214+nmu1/debian/rules 2016-05-26 10:36:42.000000000 +0200 @@ -1,7 +1,7 @@ #!/usr/bin/make -f %: - dh ${@} --parallel + dh ${@} --parallel --with systemd override_dh_auto_install: dh_auto_install