[commit: ghc] master: Bump Win32 version. (2aaafc8)

git at git.haskell.org git at git.haskell.org
Tue Jan 24 21:49:51 UTC 2017


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

On branch  : master
Link       : http://ghc.haskell.org/trac/ghc/changeset/2aaafc8b9788e4a3447a10740479e0e7c0622cda/ghc

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

commit 2aaafc8b9788e4a3447a10740479e0e7c0622cda
Author: Ben Gamari <ben at well-typed.com>
Date:   Mon Jan 23 14:52:36 2017 -0500

    Bump Win32 version.
    
    Bump the version of `Win32` to `2.5.0.0` which is a major update and includes
    fixes for wrong alignments and wrong 64-bit types. Strangely enough this also
    seems to resolve #12713, where `T10858` was failing due to too-low allocations.
    
    The underlying type aliases have changed, so there is a potential
    for user programs not to compile anymore, but the types were incorrect.
    
    This also requires a bump in the `directory`, `Cabal`, and `process`
    submodules.
    
    Original author: Tamar Christina <tamar at zhox.com>
    
    Test Plan: ./validate
    
    Reviewers: bgamari, RyanGlScott, austin
    
    Subscribers: hvr, RyanGlScott, thomie, #ghc_windows_task_force
    
    Differential Revision: https://phabricator.haskell.org/D2938


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

2aaafc8b9788e4a3447a10740479e0e7c0622cda
 compiler/ghc.cabal.in               | 2 +-
 compiler/main/SysTools.hs           | 8 ++++++--
 ghc/ghc-bin.cabal.in                | 2 +-
 libraries/Cabal                     | 2 +-
 libraries/Win32                     | 2 +-
 libraries/directory                 | 2 +-
 libraries/process                   | 2 +-
 testsuite/tests/deriving/perf/all.T | 4 +---
 testsuite/timeout/WinCBindings.hsc  | 5 +++--
 9 files changed, 16 insertions(+), 13 deletions(-)

diff --git a/compiler/ghc.cabal.in b/compiler/ghc.cabal.in
index 63276b3..dea0be5 100644
--- a/compiler/ghc.cabal.in
+++ b/compiler/ghc.cabal.in
@@ -68,7 +68,7 @@ Library
                    hoopl      >= 3.10.2 && < 3.11
 
     if os(windows)
-        Build-Depends: Win32  == 2.3.*
+        Build-Depends: Win32  >= 2.3 && < 2.6
     else
         if flag(terminfo)
             Build-Depends: terminfo == 0.4.*
diff --git a/compiler/main/SysTools.hs b/compiler/main/SysTools.hs
index 5bd9fd1..6777194 100644
--- a/compiler/main/SysTools.hs
+++ b/compiler/main/SysTools.hs
@@ -85,7 +85,11 @@ import qualified System.Posix.Internals
 #else /* Must be Win32 */
 import Foreign
 import Foreign.C.String
-import qualified System.Win32.Info as Info
+#if MIN_VERSION_Win32(2,5,0)
+import qualified System.Win32.Types as Win32
+#else
+import qualified System.Win32.Info as Win32
+#endif
 import Control.Exception (finally)
 import Foreign.Ptr (FunPtr, castPtrToFunPtr)
 import System.Win32.Types (DWORD, LPTSTR, HANDLE)
@@ -1514,7 +1518,7 @@ getFinalPath name = do
                                                      (fILE_ATTRIBUTE_NORMAL .|. fILE_FLAG_BACKUP_SEMANTICS)
                                                      Nothing
                       let fnPtr = makeGetFinalPathNameByHandle $ castPtrToFunPtr addr
-                      path    <- Info.try "GetFinalPathName"
+                      path    <- Win32.try "GetFinalPathName"
                                     (\buf len -> fnPtr handle buf len 0) 512
                                     `finally` closeHandle handle
                       return $ Just path
diff --git a/ghc/ghc-bin.cabal.in b/ghc/ghc-bin.cabal.in
index dce6142..9c9ca0e 100644
--- a/ghc/ghc-bin.cabal.in
+++ b/ghc/ghc-bin.cabal.in
@@ -38,7 +38,7 @@ Executable ghc
                    ghc        == @ProjectVersionMunged@
 
     if os(windows)
-        Build-Depends: Win32  == 2.3.*
+        Build-Depends: Win32  >= 2.3 && < 2.6
     else
         Build-Depends: unix   == 2.7.*
 
diff --git a/libraries/Cabal b/libraries/Cabal
index 7502659..824d0ba 160000
--- a/libraries/Cabal
+++ b/libraries/Cabal
@@ -1 +1 @@
-Subproject commit 7502659b7684e057047c68886df9c061645992c6
+Subproject commit 824d0bae1aee2a25cabdcef92e5e1dd470c7dac0
diff --git a/libraries/Win32 b/libraries/Win32
index bb9469e..8d3f144 160000
--- a/libraries/Win32
+++ b/libraries/Win32
@@ -1 +1 @@
-Subproject commit bb9469ece0b882017fa7f3b51e8db1d2985d6720
+Subproject commit 8d3f144a902bd13e1c6192e62ac1b2cf7cef595d
diff --git a/libraries/directory b/libraries/directory
index 65d1d85..4a4a19d 160000
--- a/libraries/directory
+++ b/libraries/directory
@@ -1 +1 @@
-Subproject commit 65d1d85a3fc3373a425a0298d572da9cd9ee3d86
+Subproject commit 4a4a19d1c46c70ffd9a3e1c4c283e2e16214258f
diff --git a/libraries/process b/libraries/process
index 85cc1d1..0524859 160000
--- a/libraries/process
+++ b/libraries/process
@@ -1 +1 @@
-Subproject commit 85cc1d17e9550a075003a764a2429d4acde65159
+Subproject commit 0524859137fc01bdb2a4833fd0aa6b23a48c6b15
diff --git a/testsuite/tests/deriving/perf/all.T b/testsuite/tests/deriving/perf/all.T
index a6f9cc9..0c3e9a4 100644
--- a/testsuite/tests/deriving/perf/all.T
+++ b/testsuite/tests/deriving/perf/all.T
@@ -1,8 +1,6 @@
 test('T10858',
      [compiler_stats_num_field('bytes allocated',
           [ (wordsize(64), 222312440, 8) ]),
-      only_ways(['normal']),
-      when(msys(), expect_broken(12713))
-      ],
+      only_ways(['normal'])],
      compile,
      ['-O'])
diff --git a/testsuite/timeout/WinCBindings.hsc b/testsuite/timeout/WinCBindings.hsc
index 0c4ff3f..a72cdcf 100644
--- a/testsuite/timeout/WinCBindings.hsc
+++ b/testsuite/timeout/WinCBindings.hsc
@@ -259,9 +259,10 @@ foreign import WINDOWS_CCONV unsafe "windows.h WaitForSingleObject"
 type JOBOBJECTINFOCLASS = CInt
 
 type PVOID = Ptr ()
-
-type ULONG_PTR  = CUIntPtr
 type PULONG_PTR = Ptr ULONG_PTR
+#if !MIN_VERSION_Win32(2,5,0)
+type ULONG_PTR  = CUIntPtr
+#endif
 
 jobObjectExtendedLimitInformation :: JOBOBJECTINFOCLASS
 jobObjectExtendedLimitInformation = #const JobObjectExtendedLimitInformation



More information about the ghc-commits mailing list