From ed44958576cd819b1faf56afaf9d9e152f0de46b Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sat, 28 May 2016 23:46:07 +0100 Subject: [PATCH] Update windows on linux build to use i686-w64-ming32 --- Tools/mkwindows.sh | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/Tools/mkwindows.sh b/Tools/mkwindows.sh index f3a20409a..8e1518750 100755 --- a/Tools/mkwindows.sh +++ b/Tools/mkwindows.sh @@ -43,10 +43,19 @@ else if test x$zip = x; then zip=zip fi - extraconfigureoptions="--host=i586-mingw32msvc --build=i686-linux" echo "Checking that mingw gcc is installed/available" - i586-mingw32msvc-gcc --version || exit 1 - i586-mingw32msvc-g++ --version || exit 1 + if [[ `which i686-w64-mingw32-gcc` ]] ; then + extraconfigureoptions="--host=i686-w64-mingw32" + i686-w64-mingw32-gcc --version || exit 1 + i686-w64-mingw32-g++ --version || exit 1 + else [[ `which i586-mingw32msvc-gcc` ]] ; then + extraconfigureoptions="--host=i586-mingw32msvc --build=i686-linux" + i586-mingw32msvc-gcc --version || exit 1 + i586-mingw32msvc-g++ --version || exit 1 + elif + echo "Could not detect mingw gcc - please install mingw-w64 package." + exit 1; + fi else if test "$cygwin"; then echo "Building native Windows executable on Cygwin"