(qb) Make $CROSS_COMPILE affect target OS detection

This commit is contained in:
Higor Eurípedes 2014-09-16 16:44:33 -03:00
parent 8620cef48a
commit 600af88507

View File

@ -6,15 +6,26 @@ TEMP_EXE=.tmp
ECHOBUF="Checking operating system"
#echo -n "Checking operating system"
case "$(uname)" in
'Linux') OS='Linux';;
*'BSD') OS='BSD';;
'Darwin') OS='Darwin';;
'MINGW32'*) OS='MinGW';;
'CYGWIN'*) OS='Cygwin';;
'Haiku') OS='Haiku';;
*) OS="Win32";;
esac
if [ -n "$CROSS_COMPILE" ]; then
case "$CROSS_COMPILE" in
*'-mingw32'*) OS='Win32';;
*);;
esac
fi
if [ -z "$OS" ]; then
case "$(uname)" in
'Linux') OS='Linux';;
*'BSD') OS='BSD';;
'Darwin') OS='Darwin';;
'MINGW32'*) OS='MinGW';;
'CYGWIN'*) OS='Cygwin';;
'Haiku') OS='Haiku';;
*) OS="Win32";;
esac
fi
echo "$ECHOBUF ... $OS"
# Checking for working C compiler