Bug#1000879: orphan-sysvinit-scripts: Remove iwd init script
Matthew Vernon
matthew at debian.org
Sun Dec 5 12:53:45 GMT 2021
On 01/12/2021 08:51, Jonas Smedegaard wrote:
> Quoting Job Bautista (2021-12-01 04:11:38)
>> Matthew Vernon wrote:
>>> On 30/11/2021 15:50, Job Bautista wrote:
>>>> Package: orphan-sysvinit-scripts
>>>> Version: 0.10
>>>> Severity: normal
>>>> X-Debbugs-Cc: jobbautista9 at protonmail.com
>>>
>>>> Please remove iwd's init script, as it's added now in iwd 1.20-2.
>>>
>>> This will need some co-ordination, I think; orphan-sysvinit-scripts
>>> uses ucf to manage /etc/init.d/iwd (as a link to
>>> /usr/share/orphan-sysvinit-scripts/iwd).
>>>
>>> Are you planning on using ucf to manage this file?
>>>
>>> [this is relevant because ucfr --purge will fail if iwd has taken
>>> over, and it would probably be better for iwd to take over the
>>> registration with ucf itself. If you're not using ucf I think we can
>>> simply ucfr --purge and ucf --purge]
>>
>> Hello, I don't think iwd uses ucf to manage the init script.
>> /etc/init.d/iwd is not a soft link but a real file. I'm not 100% sure
>> about this though as I'm not the package maintainer of iwd, so I'm
>> CC'ing him to this bug right now.
>
> Not sure what the real question is here, and whether I am asked or just
> kindly informed via cc.
I think a bit of both :) I think the correct change is for
orphan-sysvinit-scripts to have the following added to postrm, and then
for the version of iwd which contains the sysvinit script to Conflicts:
orphan-sysvinit-scripts <0.11 (which is the version that will have this
change in, assuming it's correct):
diff --git a/debian/postrm b/debian/postrm
index f217ce8..db29a52 100644
--- a/debian/postrm
+++ b/debian/postrm
@@ -21,6 +21,22 @@ case "$1" in
fi
;;
+ upgrade)
+ if which ucfq >/dev/null ; then
+ if [ -e /etc/init.d/iwd ]; then
+ if ucfq -w /etc/init.d/iwd | grep -q orphan-sysvinit-scripts
+ then
+ if which ucf >/dev/null ; then
+ ucf --purge /etc/init.d/iwd
+ fi
+ if which ucfr >/dev/null ; then
+ ucfr --purge orphan-sysvinit-scripts /etc/init.d/iwd
+ fi
+ fi
+ fi
+ fi
+
+ ;;
esac
That should remove any ucf associations of /etc/init.d/iwd ; it leaves
the file in place (which I think is the right answer for conffiles like
this), but it'll be treated like a conffile by dpkg, so that should all
work OK.
Does that sound good? If so I'll get this uploaded in the next day or so.
Regards,
Matthew
More information about the Debian-init-diversity
mailing list