Re: Problems found by piuparts
On Thu, 23 Feb 2006, Frank Küster wrote:
> Don Armstrong <email@example.com> wrote:
> > On Wed, 22 Feb 2006, Frank Küster wrote:
> >> Adeodato Simó <firstname.lastname@example.org> wrote:
> >> > Correct, so one would put in foo.postrm:
> >> >
> >> > rmdir --ignore-fail-on-non-empty /usr/local/lib/foo
> >> That's not sufficient, because /usr/local may be mounted ro, and
> >> therefore the command may fail even if the directory is empty.
> >> rmdir --ignore-fail-on-non-empty /usr/local/lib/foo || true
> > So you're suggesting that it's better to fail silently instead of
> > failing loudly?
> Yes, please read Policy 9.1.2.
Hrm, right... it just seems totally wrong to me for the package to
create the directories and then not fail if removing them fails, since
presumably the removal could fail for reasons unrelated to /usr/local
being r/o. [Perhaps the ideal solution to resolve both of these issues
is to have the script complain bitterly if it can't remove the
directories and they exist, but not fail.]
If you wish to strive for peace of soul, then believe; if you wish to
be a devotee of truth, then inquire.
-- Friedrich Nietzsche