dash, getconf and a POSIX sh
Jim Lowe
jhl at infionline.net
Sun Nov 25 02:28:17 GMT 2007
Making /bin/sh be 'dash' is fine except that (because
'dash' is a mere aspiring POSIX shell) the following
method to locate the POSIX shell is broken because it resolves
back to '/bin/dash'.
PATH=`getconf PATH` which sh
To fix this you may have to have a new directory,
for example, /usr/posix/bin, that contains 'sh' as a symlink to
/bin/bash, then make `getconf PATH` return /usr/posix/bin:/bin/:/usr/bin
Now "PATH=`getconf PATH` which sh" will be '/bin/bash' and you can
tell everyone how to find a POSIX shell on an Ubuntu system
For more backup on this
See http://www.opengroup.org/platform/resolutions/bwg2000-004.html
More information about the ubuntu-devel
mailing list