On Sun, 06 Jun 2010, Davide Brini wrote: > Some systems don't install bash or a POSIX sh in /bin, so it may also be > necessary to create symlinks on those systems. I think it's the easiest > tradeoff, and should be done anyway, because on such systems many other > #!/bin/sh or #!/bin/bash scripts are likely to break anyway.
While the assertion that you're starting from is true (installation locations of sh), OpenVPN shouldn't be a tool that requires administrators to pollute their installations with symlinks. I've posted a patch that forgoes the getconf part (I'm not sure currently if Solaris /bin/sh likes $(...) notation or insists on `...`), and just does a blunt check for /usr/xpg4/bin/sh. It's also a blunt hit in another place, it tries export FOO=bar in a subshell, which fails on Solaris 10's /bin/sh - and for instance pkitool relies on that syntax later when assigning OPENSSL. However I have no other offenders to test than Solaris 10. As a side note, not sure if it was mentioned already, I've only superficially glanced at the whole long thread, Ubuntu uses dash (Debian Almqvist shell) for /bin/sh for efficiency reasons. Finally, it appears that zsh can also emulates certain other shells, I'd recently received a FreeBSD bug report against some other (non-openvpn) software where someone was using zsh as bash replacement (for scripts that are documented to use bash and aren't easily fixed). The fun never ends ;-)
pgpxeMQtgmqlg.pgp
Description: PGP signature