Ticket #2183 (closed defect: fixed)
configure "test -e" is not portable
|Reported by:||havatv||Owned by:||dmorissette|
|Severity:||normal||Keywords:||configure test portable|
test -e, as used in the AGG section of configure, is not considered
It causes configure to fail on my Solaris 2.7 system (/bin/sh).
To enable configure scripts to support cross-compilation, they shouldn't do anything that tests features of the build system instead of the host system. But occasionally you may find it necessary to check whether some arbitrary file exists. To do so, use test -f' or test -r'. Do not use test -x', because 4.3BSD does not have it. Do not use test -e' either, because Solaris /bin/sh lacks it. To test for symbolic links on systems that have them, use test -h' rather than test -L'; either form conforms to Posix 1003.1-2001, but older shells like Solaris 8 /bin/sh support only -h.