On Sat, Feb 23, 2008 at 11:06:52AM +0100, Ralf Wildenhues wrote:
> * Ralf Wildenhues wrote on Fri, Feb 22, 2008 at 06:47:54PM CET:
> > 
> > 2) NetBSD ksh has a bug.  At least I *think* that is a bug, I haven't
> > checked SUSv3 yet.  This:
> >   foo=foo; t='[ ]'; case " foo bar " in *$t$foo$t*) echo yes;; esac

It seems NetBSD ksh ( == @(#)PD KSH v5.2.14 99/07/13.2) has lots of bugs.
(I should have remembered make uses sh which works, but gmake/autotools
choose bash over ksh over sh (is that right?))

quartz% sh
$ foo=foo; t='[ ]'; case " foo bar " in *$t$foo$t*) echo yes;; esac
yes
$ exit
quartz% ksh
$ echo $KSH_VERSION
@(#)PD KSH v5.2.14 99/07/13.2
$ set -o posix
$ foo=foo; t='[ ]'; case " foo bar " in *$t$foo$t*) echo yes;; esac
$ set +o posix
$ foo=foo; t='[ ]'; case " foo bar " in *$t$foo$t*) echo yes;; esac
$ exit

I think I am sounding like a broken record!
PR/26493

http://mail-index.netbsd.org/current-users/2004/07/27/0013.html
http://mail-index.netbsd.org/current-users/2004/07/27/0014.html
http://mail-index.netbsd.org/current-users/2004/07/28/0004.html
http://mail-index.netbsd.org/current-users/2004/07/30/0006.html
 
http://mail-index.netbsd.org/current-users/2004/08/31/0008.html
 
http://mail-index.netbsd.org/tech-pkg/2005/02/18/0000.html

http://mail-index.netbsd.org/current-users/2005/05/13/0016.html
 
http://mail-index.netbsd.org/current-users/2006/09/13/0008.html usw.

> > should IMHO print yes, but doesn't with this shell.
> 
> This violates POSIX.  Can you please file a bug report with NetBSD?

I'll add another one to the list.

> I've applied this patch to master, and likewise (without the
> keep_testdirs bits) to branch-1-10.  For now I don't know of
> a better way to automatically test for this issue than to
> encourage users to try MAKE=gmake.

... or pick sh over (pd)ksh?


Cheers,

Patrick


Reply via email to