[dslinux-devel] bash instead of sh in Makefile.xsh
Nanomad
condellog at gmail.com
Wed Jun 6 17:21:55 CEST 2007
On 6/6/07, Stefan Sperling <stsp at stsp.name> wrote:
> On Wed, Jun 06, 2007 at 04:18:39PM +0200, Nanomad wrote:
> > Since ubuntu makes use of dash instead of plain sh (don't ask me
> > why...). This leads to a corss-compilation shell prompt like:
> > -xsh- \w >
> > which is pretty ugly.
> > I suggest to make Makefile.xsh run bash instead of sh. Very simple to
> > adopt and with no drawbacks (AFAIK).
> >
> >
> > --- Makefile.xsh (revisione 1783)
> > +++ Makefile.xsh (copia locale)
> > @@ -27,4 +27,4 @@
> > @echo "------------------------------------------------------------------------"
> > @(echo "$(PATH)" | grep toolchain) 2>&1 >/dev/null || \
> > echo "Remember to put the toolchain binaries in your PATH!"
> > - @env PS1=" -xsh- \w > " /bin/sh
> > + @env PS1=" -xsh- \w > " /bin/bash --posix
>
> What about this instead?
>
> Index: Makefile.xsh
> ===================================================================
> --- Makefile.xsh (revision 1776)
> +++ Makefile.xsh (working copy)
> @@ -27,4 +27,4 @@
> @echo "------------------------------------------------------------------------"
> @(echo "$(PATH)" | grep toolchain) 2>&1 >/dev/null || \
> echo "Remember to put the toolchain binaries in your PATH!"
> - @env PS1=" -xsh- \w > " /bin/sh
> + @env PS1=" -xsh- \w > " $$SHELL
>
> --
> stefan
> http://stsp.name PGP Key: 0xF59D25F0
>
if $SHELL is bash, the PS1 part won't do anything without the --posix
part. If we add --posix and $SHELL does not like it, the makefile will
fail.
--
Official Ubuntu GNU/Linux Translator
Currently Running:
ZenWalk Linux (Slackware) on Desktop PC (P4 1.4Ghz)
Ubuntu "Feisty" on Laptop (Centrino 2Ghz)
More information about the dslinux-devel
mailing list