diff --git a/System/Posix.hs b/System/Posix.hs
index b5b221af5db2c198552cf0b2a4d9f2b5ea2d01b6..de7d08ca780bf7f727417b4586f95998bbe523bf 100644
--- a/System/Posix.hs
+++ b/System/Posix.hs
@@ -5,7 +5,7 @@
 -- Module      :  System.Posix
 -- Copyright   :  (c) The University of Glasgow 2002
 -- License     :  BSD-style (see the file libraries/base/LICENSE)
--- 
+--
 -- Maintainer  :  libraries@haskell.org
 -- Stability   :  provisional
 -- Portability :  non-portable (requires POSIX)
@@ -60,7 +60,7 @@ Here we detail our support for the IEEE Std 1003.1-2001 standard.  For
 each header file defined by the standard, we categorise its
 functionality as
 
- - "supported" 
+ - "supported"
 
    Full equivalent functionality is provided by the specified Haskell
    module.
@@ -69,7 +69,7 @@ functionality as
 
    The functionality is not currently provided.
 
- - "to be supported" 
+ - "to be supported"
 
    Currently unsupported, but support is planned for the future.
 
@@ -131,17 +131,17 @@ Unsupported interfaces
 aio.h
 assert.h
 complex.h
-cpio.h 
-ctype.h 
+cpio.h
+ctype.h
 fenv.h
 float.h
 fmtmsg.h
 fnmatch.h
 ftw.h
 glob.h
-iconv.h 
-inttypes.h 
-iso646.h 
+iconv.h
+inttypes.h
+iso646.h
 langinfo.h
 libgen.h
 locale.h	(see System.Locale)
diff --git a/System/Posix/ByteString.hs b/System/Posix/ByteString.hs
index 7f0b266668cd8e4ccfcfd270ae6a742095b248fe..22df91037d78304eb405369417d6ce17121be7a8 100644
--- a/System/Posix/ByteString.hs
+++ b/System/Posix/ByteString.hs
@@ -5,7 +5,7 @@
 -- Module      :  System.Posix.ByteString
 -- Copyright   :  (c) The University of Glasgow 2002
 -- License     :  BSD-style (see the file libraries/base/LICENSE)
--- 
+--
 -- Maintainer  :  libraries@haskell.org
 -- Stability   :  provisional
 -- Portability :  non-portable (requires POSIX)
diff --git a/System/Posix/Env.hsc b/System/Posix/Env.hsc
index 6d7f61b72f9987d7fd1ccf37fc5d8719f43feb0b..999daec3d4ffb04c371fae5facaa490d485048e2 100644
--- a/System/Posix/Env.hsc
+++ b/System/Posix/Env.hsc
@@ -8,7 +8,7 @@
 -- Module      :  System.Posix.Env
 -- Copyright   :  (c) The University of Glasgow 2002
 -- License     :  BSD-style (see the file libraries/base/LICENSE)
--- 
+--
 -- Maintainer  :  libraries@haskell.org
 -- Stability   :  provisional
 -- Portability :  non-portable (requires POSIX)
diff --git a/System/Posix/IO.hsc b/System/Posix/IO.hsc
index b3f4c842da078fd6d1b523934f8bcb203629057f..ec510f76423cc068062c9c4b896790583fa2f646 100644
--- a/System/Posix/IO.hsc
+++ b/System/Posix/IO.hsc
@@ -8,7 +8,7 @@
 -- Module      :  System.Posix.IO
 -- Copyright   :  (c) The University of Glasgow 2002
 -- License     :  BSD-style (see the file libraries/base/LICENSE)
--- 
+--
 -- Maintainer  :  libraries@haskell.org
 -- Stability   :  provisional
 -- Portability :  non-portable (requires POSIX)
@@ -63,7 +63,7 @@ module System.Posix.IO (
 
     -- ** Converting file descriptors to\/from Handles
     handleToFd,
-    fdToHandle,  
+    fdToHandle,
 
   ) where
 
@@ -90,4 +90,4 @@ openFd name how maybe_mode flags = do
 
 createFile :: FilePath -> FileMode -> IO Fd
 createFile name mode
-  = openFd name WriteOnly (Just mode) defaultFileFlags{ trunc=True } 
+  = openFd name WriteOnly (Just mode) defaultFileFlags{ trunc=True }
diff --git a/System/Posix/IO/ByteString.hsc b/System/Posix/IO/ByteString.hsc
index d387f0e2d42742a5c22a8c257ccca8b6553bebbe..2ce5ed61963f38cb43f157c4a06d4a69beb5f85e 100644
--- a/System/Posix/IO/ByteString.hsc
+++ b/System/Posix/IO/ByteString.hsc
@@ -8,7 +8,7 @@
 -- Module      :  System.Posix.IO.ByteString
 -- Copyright   :  (c) The University of Glasgow 2002
 -- License     :  BSD-style (see the file libraries/base/LICENSE)
--- 
+--
 -- Maintainer  :  libraries@haskell.org
 -- Stability   :  provisional
 -- Portability :  non-portable (requires POSIX)
@@ -63,7 +63,7 @@ module System.Posix.IO.ByteString (
 
     -- ** Converting file descriptors to\/from Handles
     handleToFd,
-    fdToHandle,  
+    fdToHandle,
 
   ) where
 
@@ -90,4 +90,4 @@ openFd name how maybe_mode flags = do
 
 createFile :: RawFilePath -> FileMode -> IO Fd
 createFile name mode
-  = openFd name WriteOnly (Just mode) defaultFileFlags{ trunc=True } 
+  = openFd name WriteOnly (Just mode) defaultFileFlags{ trunc=True }
diff --git a/System/Posix/SharedMem.hsc b/System/Posix/SharedMem.hsc
index a6326a72f8c59fc61d36cf1c2182f84600379a76..ab31764d9cd0e7dd7228ef85c28f7d483d22cc8d 100644
--- a/System/Posix/SharedMem.hsc
+++ b/System/Posix/SharedMem.hsc
@@ -35,11 +35,11 @@ import Foreign.C
 import Data.Bits
 #endif
 
-data ShmOpenFlags = ShmOpenFlags 
+data ShmOpenFlags = ShmOpenFlags
     { shmReadWrite :: Bool,
-      -- ^ If true, open the shm object read-write rather than read-only. 
+      -- ^ If true, open the shm object read-write rather than read-only.
       shmCreate :: Bool,
-      -- ^ If true, create the shm object if it does not exist. 
+      -- ^ If true, create the shm object if it does not exist.
       shmExclusive :: Bool,
       -- ^ If true, throw an exception if the shm object already exists.
       shmTrunc :: Bool
@@ -54,16 +54,16 @@ shmOpen name flags mode =
        cflags1 <- return $ cflags0 .|. (if shmReadWrite flags
                                         then #{const O_RDWR}
                                         else #{const O_RDONLY})
-       cflags2 <- return $ cflags1 .|. (if shmCreate flags then #{const O_CREAT} 
+       cflags2 <- return $ cflags1 .|. (if shmCreate flags then #{const O_CREAT}
                                         else 0)
-       cflags3 <- return $ cflags2 .|. (if shmExclusive flags 
-                                        then #{const O_EXCL} 
+       cflags3 <- return $ cflags2 .|. (if shmExclusive flags
+                                        then #{const O_EXCL}
                                         else 0)
-       cflags4 <- return $ cflags3 .|. (if shmTrunc flags then #{const O_TRUNC} 
+       cflags4 <- return $ cflags3 .|. (if shmTrunc flags then #{const O_TRUNC}
                                         else 0)
        withCAString name (shmOpen' cflags4)
     where shmOpen' cflags cname =
-              do fd <- throwErrnoIfMinus1 "shmOpen" $ 
+              do fd <- throwErrnoIfMinus1 "shmOpen" $
                        shm_open cname cflags mode
                  return $ Fd fd
 #else
diff --git a/System/Posix/Temp.hsc b/System/Posix/Temp.hsc
index 398414480892da3fb848398b87975d9718a645d2..711a696d4e7a1a511e65f96c7d489f57edcac109 100644
--- a/System/Posix/Temp.hsc
+++ b/System/Posix/Temp.hsc
@@ -78,7 +78,7 @@ mkstemps prefix suffix = do
     h <- fdToHandle (Fd fd)
     return (name, h)
 #else
-mkstemps = error "System.Posix.Temp.mkstemps: not available on this platform" 
+mkstemps = error "System.Posix.Temp.mkstemps: not available on this platform"
 #endif
 
 #if HAVE_MKDTEMP
diff --git a/System/Posix/Temp/ByteString.hsc b/System/Posix/Temp/ByteString.hsc
index 0e30c6f345e11b285f4ce6f32bf75e7092b8398d..f66f847f0fda5ba157aba74e3a668875d0bdc83b 100644
--- a/System/Posix/Temp/ByteString.hsc
+++ b/System/Posix/Temp/ByteString.hsc
@@ -63,7 +63,7 @@ foreign import capi unsafe "HsUnix.h mkstemps"
   c_mkstemps :: CString -> CInt -> IO CInt
 #endif
 
--- |'mkstemps' - make a unique filename with a given prefix and suffix 
+-- |'mkstemps' - make a unique filename with a given prefix and suffix
 -- and open it for reading\/writing (only safe on GHC & Hugs).
 -- The returned 'RawFilePath' is the (possibly relative) path of
 -- the created file, which contains  6 random characters in between
@@ -79,7 +79,7 @@ mkstemps prefix suffix = do
     h <- fdToHandle (Fd fd)
     return (name, h)
 #else
-mkstemps = error "System.Posix.Temp.mkstemps: not available on this platform" 
+mkstemps = error "System.Posix.Temp.mkstemps: not available on this platform"
 #endif
 
 #if HAVE_MKDTEMP