[pacman-dev] [PATCH] libalpm: Explicitly run install scriptlets in bash.

Loui Chang louipc.ist at gmail.com
Mon Aug 3 14:04:09 EDT 2009

On Tue 28 Jul 2009 13:03 -0500, Aaron Griffin wrote:
> On Tue, Jul 28, 2009 at 12:59 PM, Xavier<shiningxc at gmail.com> wrote:
> > On Tue, Jul 28, 2009 at 7:54 PM, Aaron Griffin<aaronmgriffin at gmail.com> wrote:
> >>
> >> Another thought would be to make the scriptlet executable and pass the
> >> "function" as an arg to the script, this way we can support
> >> #!/bin/bash and #!/bin/sh as well as a myriad of other things
> >
> > Then we need to put back the 3 magic lines in the few scripts where
> > they were removed, don't we?
> >
> > In any cases, it shouldn't be difficult to do that change
> > automatically on all scriptlets in the repo.
> > And either way, I think this should be done. Either remove these lines
> > from all scriptlets, or make sure all scriptlets have them.
> Yeah, I'm not advocating it, just saying it's a possibility. I think I
> might actually like Loui's proposal, although it needs to be more
> complex:
> Check for ROOTDIR/bin/bash, if it exists, use it
> Else, check for ROOTDIR/bin/sh and use THAT if it exists
> If none exist, warn and carry on

Maybe this would be better as an Arch Linux only patch, if there's an
intention of making current scripts dash compatible.

More information about the pacman-dev mailing list