X-Git-Url: http://andersk.mit.edu/gitweb/gssapi-openssh.git/blobdiff_plain/66b36cd64a297e8fb55e05d0747b944a971eadec..799ae497fc1f308e76517858d866bdd27b56cdd8:/openssh/contrib/findssl.sh diff --git a/openssh/contrib/findssl.sh b/openssh/contrib/findssl.sh index a4e8f4c..128db74 100644 --- a/openssh/contrib/findssl.sh +++ b/openssh/contrib/findssl.sh @@ -89,6 +89,25 @@ LD_LIBRARY_PATH=${LD_LIBRARY_PATH:=$DEFAULT_LIBPATH} LIBRARY_PATH=${LIBRARY_PATH:=$DEFAULT_LIBPATH} export LIBPATH LD_LIBRARY_PATH LIBRARY_PATH +# not all platforms have a 'which' command +if which ls >/dev/null 2>/dev/null; then + : which is defined +else + which () { + saveIFS="$IFS" + IFS=: + for p in $PATH; do + if test -x "$p/$1" -a -f "$p/$1"; then + IFS="$saveIFS" + echo "$p/$1" + return 0 + fi + done + IFS="$saveIFS" + return 1 + } +fi + # # Search for OpenSSL headers and print versions #