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

Re: Shipping /bin/sh [Re: Moving bash from essential/required to important?]

Bastian Blank <waldi@debian.org> writes:

> On Thu, Apr 07, 2011 at 12:16:02PM +0200, Goswin von Brederlow wrote:
>> Carsten Hey <carsten@debian.org> writes:
>> > System shells would (de)register themselves by calling add-system-shell
>> > in postinst and remove-system-shell in prerm.  'system-shell' would also
>> > be a virtual package provided by bash, dash and so on.  Although I don't
>> How would that work with (c)debootstrap/multistrap when creating a
>> chroot for a foreign architecture? No maintainer script will be run in
>> those cases nor can they be run in general.
> We have the same problem with awk since ages. We should fix both
> problems together. Therefor I propose the following:
> - An essential or pseudo-essential (dependency or pre-dependency from an
>   essential package) may include a new maintainer script.
> - This must be a /bin/sh script.
> - It may be called after the initial unpack of the bootstrap process.
> - It must be called outside of the new root, so it can assume that it
>   can execute some essential commands.

You then need a way to pass the location of the chroot to the new
maintainer script. So a slightly different (or extended) interface
compare to pre/posrinst/rm. But this might do as a general solution for
both /bin/sh and /usr/bin/awk. Both could have a (lets call it)
DEBIAN/bootstrap scrtipt.

> The other solution is to hardcode the setup like the awk link.
>> Some package needs to initially ship a /bin/sh binary or symlink, which
>> I would think dash should do (being the default sh). And the registering
>> in postinst could then later replace this with the proper mechanism
>> (which would still just be a symlink to dash by default I guess).
> This means that we will get a diversion just to please the bootstrap.
> Bastian

Indeed. But no pre-bootstrap script neccessary. Is there a debootstrap
for windows (or similar) that would have problems executing a /bin/sh


Reply to: