Hi Paul, On Tue, 2021-11-02 at 21:22 +0100, Paul Gevers wrote: > ... > I don't follow at all. Sorry, I don't catch what do you mean here, probably due to my non native English. Did you not accept the new solution, or is my explanation above not clear at all and confusing? If you don't like the new solution, it is fine with me. We can try to fix the current one. Otherwise, please let me know and I can try to explain it a bit more. > We're doing diversions in maintainer scripts and > we forget to properly keep track of our diversions. The list of diverted files is created automatically during the build process in lazarus-src.preinst.[1] The very same list is created for lazarus-src.postrm.[2] > With the new > upstream version, apparently some files got dropped and the knowledge of > the diversions got lost in the process. This means that somehow, the lazarus-src.postrm was not called. > I think we can easily manually > drop the diversions now by adding them here [1], while contemplating a > saner and automated way of handling the underlying problem. In the current case, lazarus-src.postrm is not called or is called but does not fall in the list of tests we are doing (called with upgrade?). However, in the past we did not remove the old lazarus when the new one is installed (we were able to have 2.0.10 and 2.0.12). Now we allow this only for major releases, not maintenance ones. So next time, soon, when 2.2 will be there, the upgrade will not happen in the same way. So if upgrading from 2.0.10 to 2.0.x we should remove diversions, but not if we go to from 2.0.10 to 2.y with y > 0.
That was why I proposed to completely replace this mechanism with an other one that let it handled automatically with dpkg, but maybe we can just fix the logic in [3]. [1] https://salsa.debian.org/pascal-team/lazarus/-/blob/master/debian/rules#L411 [2] https://salsa.debian.org/pascal-team/lazarus/-/blob/master/debian/rules#L423 [3] https://salsa.debian.org/pascal-team/lazarus/-/blob/master/debian/lazarus-src.postrm.in#L7 -- Cheers, Abou Al Montacir
signature.asc
Description: This is a digitally signed message part