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

Bug#881432: marked as done (debian-policy: Please clarify postinst invocation upon first installation)



Your message dated Fri, 17 Nov 2017 00:35:36 +0100
with message-id <1510874283@msgid.manchmal.in-ulm.de>
and subject line Re: Bug#881432: debian-policy: Please clarify postinst invocation upon first installation
has caused the Debian Bug report #881432,
regarding debian-policy: Please clarify postinst invocation upon first installation
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact owner@bugs.debian.org
immediately.)


-- 
881432: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=881432
Debian Bug Tracking System
Contact owner@bugs.debian.org with problems
--- Begin Message ---
Package: debian-policy
Version: 4.1.1.1
Severity: wishlist

Hello,

the question of how to tell in postinst whether this is an upgrade or a
first installation comes up every now and then. Again yesterday in
#debian-mentors. Therefore I'm asking for a clarifcation in

6.5. Summary of ways maintainer scripts are called

in the paragraph after

"postinst configure most-recently-configured-version"

Suggested wording:

| If this package was prevously uninstalled, the
| "most-recently-configured-version" string is empty.

Reading src/configure.c in dpkg, this should be technically correct.

Also testing for an empty $2 in postinst is common according to
codesearch[1].

Regards,
    Christoph

[1] https://codesearch.debian.net/search?q=-z+%22%5C%242%22+path%3Adebian%2F*.postinst

Attachment: signature.asc
Description: Digital signature


--- End Message ---
--- Begin Message ---
Sean Whitton wrote...

> Sorry, I spoke too soon.  I withdraw my second.  Currently we have:
> 
> > If there is no most recently configured version ``dpkg`` will pass a
> > null argument.
> 
> This seems to cover your case, but maybe you don't think it's
> sufficient?

Upon a second read: This is sufficient, so closing.

It might seem the text you quoted is in the wrong place but that's not
true: There is "6.5. Summary of ways maintainer scripts are called". And
that one is in the following sections called "Details".

One might suggest to add some "For details, see below" in the first
paragraphs of 6.5 but I think that's fairly close to pampering.

    Christoph

Attachment: signature.asc
Description: Digital signature


--- End Message ---

Reply to: