Bug#1042082: Please take over udev SysV init script

lorenzo plorenzo at disroot.org
Thu Aug 24 22:14:36 BST 2023


On Wed, 23 Aug 2023 14:14:37 +0100
Mark Hindley <mark at hindley.org.uk> wrote:

> Lorenzo,
> 
> On Wed, Aug 23, 2023 at 01:46:35PM +0200, lorenzo wrote:
> > Subject: [PATCH 4/5] remove x mode from udev on non-linux archs
> > 
> > initscripts postinst: remove x mode from udev script on non-linux
> > archs so that the script is skipped by update-rc.d
> > ---
> >  debian/initscripts.postinst | 5 +++++
> >  1 file changed, 5 insertions(+)
> > 
> > diff --git a/debian/initscripts.postinst
> > b/debian/initscripts.postinst index dd7c9715..202fc3fd 100755
> > --- a/debian/initscripts.postinst
> > +++ b/debian/initscripts.postinst
> > @@ -26,6 +26,11 @@ INITSCRIPTS="mountkernfs.sh udev mount-configfs
> > brightness hostname.sh mountdevs umountroot umountfs umountnfs.sh
> > sendsigs killprocs single motd \ bootlogs rc.local rmnologin"
> >  
> > +if [ "$(uname -s)" != Linux ]; then
> > +# udev is linux-any but this  package is arch:all
> > +	chmod -x /etc/init.d/udev
> > +fi
> > +
> >  for F in $INITSCRIPTS; do
> >  	if [ -x /etc/init.d/$F ]; then
> >  		update-rc.d $F defaults >/dev/null || exit $?
> > -- 
> > 2.40.1
> > 
> 
> This is the only substantive difference I can see between our trees.
> 
> However, /etc/init.d/udev contains
> 
>  [ -x $DAEMON ] || exit 0
> 
> so on non-Linux archs it will do nothing.
> 
> Is this postinst handling strictly necessary?

In the end the result is the same, so you can skip it if you prefer to
avoid adding extra code to the postinst

> 
> I agree that bin:udev needs not to use rm_conffile/remove-on-upgrade
> on /etc/init.d/udev, otherwise user modifications will be lost. That
> would have to wait for Forky.



More information about the Debian-init-diversity mailing list