Martin Vaeth <mar...@mvath.de> wrote: > Joerg Schilling <joerg.schill...@fokus.fraunhofer.de> wrote: > > > > bash vs. POSIX, as bash tried to ignore long existing > > rules just because the bash maintainer did not understand them. > > Are there really several? I know only one such example:
One is that "sh -ce cmd" did not exit on error for some kind of commands. This is where I have been able to convince the bash maintainer together with David Korn for bash-4.0. This was a nightmare for make. Another is e.g. that bash makes job control for commands in scripts or commands from "sh -ce cmd". This is another nightmare for make, as this prevents layered makefiles from terminating when ^C is typed as some comands run in different process groups. Smake for this reason has a special autoconf test for /bin/sh being bash and tries to manually kill(2) the dependencies if they are run by bash. > bash insists on compound commands ("{ ... }" or "( ... )") > for the function body while according to POSIX also > non-compound commmands can form the body, e.g. > > hello() echo "hello world" > > is a valid function definition according to POSIX > (and thus works in dash or also zsh) but not in bash: > Rumors say that the bash maintainer intentionally > excluded this due to some misinterpretation of the > POSIX formulation. This is valid in the Bourne Shell already, so it is something that can be seen as very basic. Jörg -- EMail:jo...@schily.net (home) Jörg Schilling D-13353 Berlin joerg.schill...@fokus.fraunhofer.de (work) Blog: http://schily.blogspot.com/ URL: http://cdrecord.org/private/ http://sourceforge.net/projects/schilytools/files/'