FS#20557 - Use bash in scriplet calls
Attached to Project:
Pacman
Opened by Andrej Gelenberg (nikel) - Saturday, 21 August 2010, 17:44 GMT
Last edited by Allan McRae (Allan) - Sunday, 22 April 2012, 11:22 GMT
Opened by Andrej Gelenberg (nikel) - Saturday, 21 August 2010, 17:44 GMT
Last edited by Allan McRae (Allan) - Sunday, 22 April 2012, 11:22 GMT
|
Details
Use /bin/bash for all scriplets (for example .INSTALL and
other). At the moment scriptlets are called with /bin/sh and
some sriptlets assume that /bin/sh is bash. If you set
/bin/sh to dash some of the .INSTALL scripts fail due syntax
error. So my patch run all stuff with bash, so you don't
need to rewrite all install-scripts to get it dash
compatible.
Why dash as /bin/sh: https://wiki.ubuntu.com/DashAsBinSh. |
This task depends upon
Closed by Allan McRae (Allan)
Sunday, 22 April 2012, 11:22 GMT
Reason for closing: Fixed
Additional comments about closing: Scriplet shell can be selected at configure time: commit 3ba53918
Sunday, 22 April 2012, 11:22 GMT
Reason for closing: Fixed
Additional comments about closing: Scriplet shell can be selected at configure time: commit 3ba53918
0001-run-commands-in-_alpm_ru...
http://code.toofishes.net/cgit/xavier/pacman.git/log/?h=working
But now I finally found the last reference I have on the topic (this issue has been discussed many times already) :
http://mailman.archlinux.org/pipermail/pacman-dev/2010-May/010914.html
and as you can see, Dan and Allan would like to avoid forcing the need of bash in pacman.
But rather allowing to put this at the top of all our scriptlets :
#!/bin/bash
I have no idea what work was done on that, just wait for a status update.
My other task was defer this until such a decision is formally made, what install scripts should be sh complain (or not): http://bugs.archlinux.org/task/20464.
IMHO it would be better, if all install scripts should be sh complain (with dash as /bin/sh it would make all stuff bit faster). I could fix the install scripts in abs, if this help.
I can help with init scripts too, to get them work with dash.
(greetings from FrOSCon)
BTW, the initscripts use #!/bin/bash and rely heavily on bash specific features (and are moving further in that direction).