[commit: testsuite] master: Detect msys2 via uname (different to msys) (6ee5303)

git at git.haskell.org git at git.haskell.org
Tue Nov 12 23:42:43 UTC 2013


Repository : ssh://git@git.haskell.org/testsuite

On branch  : master
Link       : http://ghc.haskell.org/trac/ghc/changeset/6ee5303beb6d018b542d408c2027f582e2c1437b/testsuite

>---------------------------------------------------------------

commit 6ee5303beb6d018b542d408c2027f582e2c1437b
Author: Simon Peyton Jones <simonpj at microsoft.com>
Date:   Tue Nov 12 23:41:45 2013 +0000

    Detect msys2 via uname (different to msys)
    
    uname -s
      msys gives "MINGW32"
      msys2 gives "MINGW_NT-6.2"


>---------------------------------------------------------------

6ee5303beb6d018b542d408c2027f582e2c1437b
 driver/runtests.py |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/driver/runtests.py b/driver/runtests.py
index 8ed6499..c92eaef 100644
--- a/driver/runtests.py
+++ b/driver/runtests.py
@@ -132,13 +132,16 @@ if config.use_threads == 1:
 
 config.cygwin = False
 config.msys = False
+
 if windows:
     h = os.popen('uname -s', 'r')
     v = h.read()
     h.close()
     if v.startswith("CYGWIN"):
         config.cygwin = True
-    elif v.startswith("MINGW32"):
+    elif v.startswith("MINGW"):
+# msys gives "MINGW32"
+# msys2 gives "MINGW_NT-6.2"
         config.msys = True
     else:
         raise Exception("Can't detect Windows terminal type")



More information about the ghc-commits mailing list