    Win32.removeDirectory path
  #else
    Posix.removeDirectory path
-@@ -622,7 +709,9 @@
+@@ -622,7 +708,9 @@
  
  removeFile :: FilePath -> IO ()
  removeFile path =

 -- builds, so we use this ugly workaround where we simply paste the C string
 -- literal directly in here.  This will probably break if the EXE_EXTENSION
diff -Nru upstream/pkg/directory/System/Directory.hs boot/pkg/directory/System/Directory.hs
--- upstream/pkg/directory/System/Directory.hs	2018-01-09 08:27:52.000000000 +0000
+++ boot/pkg/directory/System/Directory.hs	2018-01-09 08:27:52.198658973 +0000
@@ -1,9 +1,17 @@
 {-# LANGUAGE CPP #-}
+#if !defined(mingw32_HOST_OS) && !defined(ghcjs_HOST_OS)

   Win32.createDirectory path Nothing
 #else
   Posix.createDirectory path 0o777
@@ -399,7 +473,11 @@
               unless canIgnore (ioError e)
           | otherwise              -> ioError e
       where
