<div dir="ltr"><div class="gmail_extra"><br><div class="gmail_quote">On 22 January 2016 at 09:50, Andreas Müller <span dir="ltr">&lt;<a href="mailto:schnitzeltony@googlemail.com" target="_blank">schnitzeltony@googlemail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div id=":17h4" class="" style="overflow:hidden">although opkg 0.2 -&gt; 0.3 is long ago I noticed a change in behaviour<br>
when updating a package:<br>
<br>
* 0.2.x did not call pkg_prerm<br>
* 0.3.x calls pkg_prerm<br>
<br>
Is calling pkg_prerm a valid behaviour when updating a package?</div></blockquote></div><br></div><div class="gmail_extra">opkg is copying what dpkg does [1], which makes sense considering opkg is basically a dpkg clone.  It passes variables to the script so you can identify if the context is &quot;i&#39;m being deleted&quot; or &quot;i&#39;m being upgraded&quot;.</div><div class="gmail_extra"><br></div><div class="gmail_extra">This changed in <a href="http://git.yoctoproject.org/cgit/cgit.cgi/opkg/commit/?id=a8555d352d2851ee1482b74b57ba9eacfb354c18">http://git.yoctoproject.org/cgit/cgit.cgi/opkg/commit/?id=a8555d352d2851ee1482b74b57ba9eacfb354c18</a> if you want more context.</div><div class="gmail_extra"><br></div><div class="gmail_extra">[1] <a href="https://www.debian.org/doc/debian-policy/ch-maintainerscripts.html">https://www.debian.org/doc/debian-policy/ch-maintainerscripts.html</a> is what dpkg does, fwiw.<br></div><div class="gmail_extra"><br></div><div class="gmail_extra">Ross</div></div>