[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: How to use remove-on-upgrade to remove a configuration file?



Ludovic Rousseau:
> Hello,
> 
> I am fixing Debian bug #990154.
> 
> After some work I am able to remove the obsolete conf file using:
> rm_conffile /etc/reader.conf.d/0comments 1.9.3-2~ pcscd
> in debian/pcscd.maintscript
> 
> Nice.
> Now I would like to use the method documented in deb-conffiles
> https://manpages.debian.org/unstable/dpkg-dev/deb-conffiles.5.en.html
> 
> I would need to add in the DEBIAN/conffiles of the pcscd package the line:
> remove-on-upgrade /etc/reader.conf.d/0comments
> 
> But how do I generate a .deb package with this extra line?
> What is the magic dh command or file to do that?
> Where is it documented?
> 
> I tried to use a file debian/pcscd.conffiles but this file is no more
> used with debhelper version 12
> https://manpages.debian.org/buster/debhelper/dh_installdeb.1.en.html
> 
> I searched for occurrences of "remove-on-upgrade" in
> https://codesearch.debian.net/ but I only find references to dpkg source
> code.
> No Debian package is using or has used "remove-on-upgrade"?
> 
> Thanks
> 

Hi Ludovic,

You cannot use that feature yet as it would break during upgrade. The
dpkg version in stable does not support the feature.  Which is also why
there is no debhelper feature to support it yet.

Thanks,
~Niels


Reply to: