Here's a bunch of rather trivial patches against master to fix
portability issues, mostly shell ones. FWIW I did not test the
patches other than ensuring the set of testsuite errors remains
the same, and that I only did on one system.
All of the issues are ones that are encountered on some real
system, most are documented either in POSIX or in the shell
portability section of the Autoconf manual.
Cheers,
Ralf