Hi! I am having a problem, and I guess I might not be the only one who might stumble into it. When one wants to do something in new installs of the package, they usually check for $2 != "" in the postinst and put the stuff in there. So far, so good, and policy friendly because you might not create ill side effects about user expectations to no changes during upgrades. When though the stuff in between that condition is also guided by some debconf questions, people might want to have it also being run on a dpkg-reconfigure. That makes it somewhat tricky, because from what I see the postinst is called just the same way like a reinstall of the very same package version, that is, with the version number prior installed in $2. Left aside that I don't see a real chance currently to differentiate between a dpkg-reconfigure and a reinstall of the same version, it still leaves me with the problem that I would need to dynamically generate the postinst on package build to contain the exact version of the package I am building. Is my analysis flawed? Is there a way to differentiate between a reconfigure and a reinstall that I didn't see? Is there a cleaner approach to this problem than dynamically generating the postinst? Thank in advance for your thoughts, and a Cc might be nice, though I'm checking with the list archives. So long, Alfie -- char *strstr(const char *haystack, const char *needle); -- STRSTR(3) Linux Programmer's Manual
Attachment:
signature.asc
Description: Digital signature