configure: do not rely on pathsearch if full executable path provided.

This issue was pointed out by Mark Callaghan. Fixes #90.
ck_pring
Samy Al Bahra 8 years ago
parent 24d26965d1
commit f8d5022030

4
configure vendored

@ -561,10 +561,12 @@ else
fi
printf "Finding suitable compiler........"
if test ! -x "${CC}"; then
CC=`pathsearch "${CC:-cc}"`
if test -z "$CC" -o ! -x "$CC"; then
CC=`pathsearch "${CC:-gcc}"`
fi
fi
assert "$CC" "not found"
cat << EOF > .1.c
@ -596,7 +598,7 @@ int main(void) {
EOF
$CC -o .1 .1.c
COMPILER=`./.1`
COMPILER=`./.1 2> /dev/null`
r=$?
rm -f .1.c .1

Loading…
Cancel
Save