Hi all,
I'm packaging dkms [1] (ITP #481590), and it needs to install a script into
init.d.
I have a ./debian/dkms_autoinstaller.init, which should be placed
in /etc/init.d/ by dh_installinit. And it does its job. But dh_installinit
manpage also states:
It also automatically generates the postinst and postrm and prerm
commands needed to set up the symlinks in /etc/rc*.d/ and to start and
stop the init scripts.
This is not actually true, at least in my case. And this is why I'm asking for
help here.
After a "debuild", lintian warns:
W: dkms:
script-in-etc-init.d-not-registered-via-update-rc.d /etc/init.d/dkms_autoinstaller
N:
N: The package installs an /etc/init.d script which is not registered in
N: the postinst script. This is usually a bug, unless you omit the links
N: intentionally for some reason or create the links some other way.
N:
I supposed dh_installinit did that!
So, I tried grabbing clean postinst and postrm
from /usr/share/debhelper/dh_make/debian/, and left only the #DEBHELPER#. This
didn't work either.
After this, I tried calling
/usr/sbin/update-rc.d dkms_autoinstaller defaults
in the "configure" case of the postinst, and:
/usr/sbin/update-rc.d -f dkms_autoinstaller remove
in postrm. But lintian is still warning about that. Oh, well, lintian throwed
an error as well:
E: dkms:
postrm-contains-additional-updaterc.d-calls /etc/init.d/dkms_autoinstaller
N:
N: The postrm de-registers an /etc/init.d script which has not been
N: registered in the postinst script before.
N:
On my system:
# find /etc/ -name "*dkms_autoinstaller*"
# LANG=C dpkg -i dkms_2.0.19-1_all.deb
Selecting previously deselected package dkms.
(Reading database ... 199996 files and directories currently installed.)
Unpacking dkms (from dkms_2.0.19-1_all.deb) ...
Setting up dkms (2.0.19-1) ...
Adding system startup for /etc/init.d/dkms_autoinstaller ...
/etc/rc0.d/K20dkms_autoinstaller -> ../init.d/dkms_autoinstaller
/etc/rc1.d/K20dkms_autoinstaller -> ../init.d/dkms_autoinstaller
/etc/rc6.d/K20dkms_autoinstaller -> ../init.d/dkms_autoinstaller
/etc/rc3.d/S20dkms_autoinstaller -> ../init.d/dkms_autoinstaller
/etc/rc4.d/S20dkms_autoinstaller -> ../init.d/dkms_autoinstaller
/etc/rc5.d/S20dkms_autoinstaller -> ../init.d/dkms_autoinstaller
Processing triggers for man-db ...
# find /etc/ -name "*dkms_autoinstaller*"
/etc/rc0.d/K20dkms_autoinstaller
/etc/rc1.d/K20dkms_autoinstaller
/etc/rc3.d/S20dkms_autoinstaller
/etc/rc4.d/S20dkms_autoinstaller
/etc/rc5.d/S20dkms_autoinstaller
/etc/rc6.d/K20dkms_autoinstaller
/etc/init.d/dkms_autoinstaller
# LANG=C apt-get --purge remove dkms
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be REMOVED:
dkms*
0 upgraded, 0 newly installed, 1 to remove and 1 not upgraded.
After this operation, 266kB disk space will be freed.
Do you want to continue [Y/n]?
(Reading database ... 200034 files and directories currently installed.)
Removing dkms ...
0
Removing any system startup links for /etc/init.d/dkms_autoinstaller ...
/etc/rc0.d/K20dkms_autoinstaller
/etc/rc1.d/K20dkms_autoinstaller
/etc/rc3.d/S20dkms_autoinstaller
/etc/rc4.d/S20dkms_autoinstaller
/etc/rc5.d/S20dkms_autoinstaller
/etc/rc6.d/K20dkms_autoinstaller
Purging configuration files for dkms ...
Removing any system startup links for /etc/init.d/dkms_autoinstaller ...
Processing triggers for man-db ...
#
That seems working. Is lintian broken? Or am I missing something really
obvious?
Kindly,
David
[1] http://linux.dell.com/projects.shtml#dkms
--
. ''`. Debian maintainer | http://wiki.debian.org/DavidPaleino
: :' : Linuxer #334216 --|-- http://www.hanskalabs.net/
`. `'` GPG: 1392B174 ----|---- http://snipr.com/qa_page
`- 2BAB C625 4E66 E7B8 450A C3E1 E6AA 9017 1392 B174
Attachment:
signature.asc
Description: PGP signature