Use configure's 'host' variable for mingw detection

Otherwise a real mingw on Windows may not be detected correctly.
This commit is contained in:
Moritz Bunkus 2009-12-20 12:15:42 +01:00
parent a022734a63
commit 34754808de

View File

@ -3,11 +3,14 @@ dnl Check for mingw
dnl
AC_CACHE_CHECK([if being compiled with mingw32],
[ac_cv_mingw32],[
if test "x`$CXX --version | grep -i mingw`" = "x" ; then
ac_cv_mingw32=no
else
ac_cv_mingw32=yes
fi])
case $host in
*mingw*)
ac_cv_mingw32=yes
;;
*)
ac_cv_mingw32=no
;;
esac])
if test "x$ac_cv_mingw32" = "xyes"; then
export MINGW=1