Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-12 Thread Eitan Adler
On 12 November 2012 13:52, Paul Smith wrote: > On Mon, 2012-11-12 at 13:11 -0500, Eitan Adler wrote: >> #!/bin/sh which is mandated to exist by POSIX > > Actually, unless there's been a change, POSIX doesn't mandate that the > POSIX shell appear as /bin/sh. Okay. Taking a deeper look here, I'm w

Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-12 Thread Paul Smith
On Mon, 2012-11-12 at 13:11 -0500, Eitan Adler wrote: > #!/bin/sh which is mandated to exist by POSIX Actually, unless there's been a change, POSIX doesn't mandate that the POSIX shell appear as /bin/sh. Unfortunately, this means that systems are free to provide definitively non-POSIX /bin/sh an

Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-12 Thread Eitan Adler
On 12 November 2012 13:11, Eitan Adler wrote: > On 12 November 2012 13:04, Mike Frysinger wrote: >> yes, when people tell you forcing asinine behavior is wrong, you label them >> trolls. i guess that's how you "win" arguments. > > Claiming that systems without /bin/bash are "crap" shows a level

Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-12 Thread Eitan Adler
On 12 November 2012 13:04, Mike Frysinger wrote: > yes, when people tell you forcing asinine behavior is wrong, you label them > trolls. i guess that's how you "win" arguments. Claiming that systems without /bin/bash are "crap" shows a level of naivete that only someone new to the open source wo

Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-12 Thread Mike Frysinger
On Monday 12 November 2012 06:03:37 Andrew Stubbs wrote: > Running "sh -x test.sh" shows that the gcc command producing the error: > > + CCACHE_DISABLE=1 gcc -c test1.c -o reference_test1.o -O -O > gcc: error trying to exec 'cc1': execvp: No such file or directory > > I don't understand what's wr

Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-12 Thread Mike Frysinger
On Saturday 10 November 2012 05:08:40 Joel Rosdahl wrote: > On 10 November 2012 06:45, Mike Frysinger wrote: > > i see old style portable code in there that could easily be modernized to > > recent POSIX > > Please don't strive to do that. Solaris's /bin/sh isn't POSIX. autoconf searches well kn

Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-12 Thread Mike Frysinger
On Sunday 11 November 2012 06:31:14 Eitan Adler wrote: > On 11 November 2012 00:46, Mike Frysinger wrote: > > On Saturday 10 November 2012 00:41:52 Eitan Adler wrote: > >> On 10 November 2012 00:41, Mike Frysinger wrote: > >> > if the script is written in bash and is intended to be, then > >> > /b

Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-12 Thread Eitan Adler
On 12 November 2012 13:00, Eitan Adler wrote: > On 12 November 2012 06:03, Andrew Stubbs wrote: >> Running "sh -x test.sh" shows that the gcc command producing the error: >> >> + CCACHE_DISABLE=1 gcc -c test1.c -o reference_test1.o -O -O >> gcc: error trying to exec 'cc1': execvp: No such file or

Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-12 Thread Eitan Adler
On 12 November 2012 06:03, Andrew Stubbs wrote: > Running "sh -x test.sh" shows that the gcc command producing the error: > > + CCACHE_DISABLE=1 gcc -c test1.c -o reference_test1.o -O -O > gcc: error trying to exec 'cc1': execvp: No such file or directory > > I don't understand what's wrong with t

Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-12 Thread Andrew Stubbs
On 11/11/12 11:31, Eitan Adler wrote: Mike, http://www.technollama.co.uk/wordpress/wp-content/uploads/2011/05/obvious-troll.jpg Insulting respected members of the Linux community will get you nowhere. I realise that some might call you the same, and BSD also, so you should know better. An

Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-11 Thread Eitan Adler
On 11 November 2012 00:46, Mike Frysinger wrote: > On Saturday 10 November 2012 00:41:52 Eitan Adler wrote: >> On 10 November 2012 00:41, Mike Frysinger wrote: >> > if the script is written in bash and is intended to be, then >> > /bin/bash is the correct answer. >> >> Absolutely false. /usr/local

Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-10 Thread Mike Frysinger
On Saturday 10 November 2012 00:41:52 Eitan Adler wrote: > On 10 November 2012 00:41, Mike Frysinger wrote: > > if the script is written in bash and is intended to be, then > > /bin/bash is the correct answer. > > Absolutely false. /usr/local/bin or /opt/bin might be the correct location. if you

Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-10 Thread Joel Rosdahl
On 10 November 2012 06:45, Mike Frysinger wrote: > i see old style portable code in there that could easily be modernized to > recent POSIX Please don't strive to do that. Solaris's /bin/sh isn't POSIX. -- Joel ___ ccache mailing list ccache@lists.samb

Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-09 Thread Mike Frysinger
On Monday 05 November 2012 12:55:10 Andrew Stubbs wrote: > The test script fails with shells other than bash. At least dash > doesn't work. could you post the exact errors you see ? i see old style portable code in there that could easily be modernized to recent POSIX and plenty of quoting issu

Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-09 Thread Eitan Adler
On 10 November 2012 00:41, Mike Frysinger wrote: > ironic considering you're espousing a change to support crap systems that > aren't relevant. I won't comment on this. > if the script is written in bash and is intended to be, then > /bin/bash is the correct answer. Absolutely false. /usr/local

Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-09 Thread Mike Frysinger
On Tuesday 06 November 2012 11:53:12 Eitan Adler wrote: > On 6 November 2012 04:54, Andrew Stubbs wrote: > > While it is true that "/usr/bin/env bash" is more portable than > > "/bin/bash", I also don't like it as much. > > > > If I run a "#!/bin/bash" script without bash installed I get: > > /

Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-07 Thread Joel Rosdahl
On 5 November 2012 18:55, Andrew Stubbs wrote: > The test script fails with shells other than bash. At least dash > doesn't work. test.sh is intended to work even on Solaris's /bin/sh, which is even more restricted than dash. Current test.sh on master and maint works well with dash for me. Plea

Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-07 Thread Andrew Stubbs
On 06/11/12 16:53, Eitan Adler wrote: Perhaps you should get a better version of env? Perhaps I should! I'm running Ubuntu 12.10, so I'm surprised about that. But even if I did there would be many others with the same issue. The followup to this discussion indicates that /bin/sh seems to be

Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-06 Thread Eitan Adler
On 6 November 2012 04:54, Andrew Stubbs wrote: > > While it is true that "/usr/bin/env bash" is more portable than "/bin/bash", > I also don't like it as much. > > If I run a "#!/bin/bash" script without bash installed I get: > > /bin/bash: bad interpreter: No such file or directory > > If I try

Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-06 Thread Andrew Stubbs
On 06/11/12 10:05, g@free.fr wrote: On my debian stable machine (x86 32 bits), I set sh as a symlink to dash and changed my script to emit SHELL='/bin/dash' test is ok with 3.1.8 (ccache is statically linked to glibc in my configuration). I looked with checkbashims on test.sh git version a

Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-06 Thread g . esp
- Mail original - > De: "Andrew Stubbs" > À: "g esp" > Cc: ccache@lists.samba.org > Envoyé: Mardi 6 Novembre 2012 10:55:23 > Objet: Re: [ccache] [PATCH] Use bash for test.sh. > > On 05/11/12 22:35, g@free.fr wrote: > > ccache-3.1.8 &

Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-06 Thread Andrew Stubbs
On 05/11/12 22:35, g@free.fr wrote: ccache-3.1.8 'make check' work with dash, no? There's no problem with configure or make, only with test.sh. Andrew ___ ccache mailing list ccache@lists.samba.org https://lists.samba.org/mailman/listinfo/ccache

Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-06 Thread Andrew Stubbs
On 05/11/12 17:58, Eitan Adler wrote: -#!/bin/sh +#!/bin/bash This line is buggy: please http://blog.eitanadler.com/2012/10/binbash-considered-harmful.html for why. I ideally the non-portable bashims get fixed but if not the shebang line must be "/usr/bin/env bash" not /bin/bash. While it i

Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-05 Thread g . esp
- Mail original - > De: "Andrew Stubbs" > À: ccache@lists.samba.org > Envoyé: Lundi 5 Novembre 2012 18:55:10 > Objet: [ccache] [PATCH] Use bash for test.sh. > > The test script fails with shells other than bash. At least dash > doesn't work. > > Signed-off-by: Andrew Stubbs > --- >

Re: [ccache] [PATCH] Use bash for test.sh.

2012-11-05 Thread Eitan Adler
On 5 November 2012 12:55, Andrew Stubbs wrote: > The test script fails with shells other than bash. At least dash > doesn't work. > > Signed-off-by: Andrew Stubbs > --- > test.sh |2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/test.sh b/test.sh > index 4c78617..a334f6