about summary refs log tree commit diff
diff options
context:
space:
mode:
authorklutzy <klutzytheklutzy@gmail.com>2014-03-30 04:34:26 +0900
committerklutzy <klutzytheklutzy@gmail.com>2014-03-30 04:34:40 +0900
commitd9d197d9fcb3b796073ce58181c26c81d82147c8 (patch)
tree84236ca78bd6986ae57586ea74a1237040191dc2
parent3eb3a02c92e129e87561ebcf927543679bf7c74d (diff)
downloadrust-d9d197d9fcb3b796073ce58181c26c81d82147c8.tar.gz
rust-d9d197d9fcb3b796073ce58181c26c81d82147c8.zip
configure: Add MINGW64 OS type
MSYS2 supports `MINGW64` system for 64-bit environment. It sets
`MSYSTEM=MINGW64` environment variable, which changes output of
`uname -s` thus affects `configure` behavior.

This patch adds `MINGW64*` support for `configure`.
-rwxr-xr-xconfigure10
1 files changed, 8 insertions, 2 deletions
diff --git a/configure b/configure
index 402a3c0e0d8..90966bd57b4 100755
--- a/configure
+++ b/configure
@@ -274,6 +274,12 @@ case $CFG_OSTYPE in
     MINGW32*)
         CFG_OSTYPE=pc-mingw32
         ;;
+
+    MINGW64*)
+        # msys2, MSYSTEM=MINGW64
+        CFG_OSTYPE=w64-mingw32
+        ;;
+
 # Thad's Cygwin identifers below
 
 #   Vista 32 bit
@@ -407,7 +413,7 @@ valopt mandir "${CFG_PREFIX}/share/man" "install man pages in PATH"
 # --libdir is used to configure the installation directory.
 # FIXME: Thise needs to parameterized over target triples. Do it in platform.mk
 CFG_LIBDIR_RELATIVE=lib
-if [ "$CFG_OSTYPE" = "pc-mingw32" ]
+if [ "$CFG_OSTYPE" = "pc-mingw32" ] || [ "$CFG_OSTYPE" = "w64-mingw32" ]
 then
     CFG_LIBDIR_RELATIVE=bin
 fi
@@ -533,7 +539,7 @@ then
 fi
 
 BIN_SUF=
-if [ $CFG_OSTYPE = "pc-mingw32" ]
+if [ "$CFG_OSTYPE" = "pc-mingw32" ] || [ "$CFG_OSTYPE" = "w64-mingw32" ]
 then
     BIN_SUF=.exe
 fi