diff --git a/src/System/PosixCompat/Files.hsc b/src/System/PosixCompat/Files.hsc
--- a/src/System/PosixCompat/Files.hsc
+++ b/src/System/PosixCompat/Files.hsc
@@ -124,8 +124,12 @@
 import System.IO (IOMode(..), openFile, hFileSize, hSetFileSize, hClose)
 import System.IO.Error
 import System.PosixCompat.Types
-import System.Time (ClockTime(..), getClockTime)
 
+import System.PosixCompat.Internal.Time (
+      getClockTime, clockTimeToEpochTime
+    , modificationTimeToEpochTime
+    )
+
 #ifdef __GLASGOW_HASKELL__
 import GHC.IO.Handle.FD (fdToHandle)
 #endif
@@ -297,7 +301,7 @@
     do perm  <- liftM permsToMode $ getPermissions path
        typ   <- getFileType path
        size  <- if typ == regularFileMode then getFileSize path else return 0
-       mtime <- liftM clockTimeToEpochTime $ getModificationTime path
+       mtime <- liftM modificationTimeToEpochTime $ getModificationTime path
        return $ FileStatus
                 { deviceID         = -1
                 , fileID           = -1
@@ -332,10 +336,6 @@
 getFileSize :: FilePath -> IO FileOffset
 getFileSize path =
     bracket (openFile path ReadMode) hClose (liftM fromIntegral . hFileSize)
-
-clockTimeToEpochTime :: ClockTime -> EpochTime
-clockTimeToEpochTime (TOD s _) = fromInteger s
-
 
 getFdStatus :: Fd -> IO FileStatus
 getFdStatus _ = unsupported "getFdStatus"
diff --git a/src/System/PosixCompat/Internal/Time.hs b/src/System/PosixCompat/Internal/Time.hs
new file mode 100644
--- /dev/null
+++ b/src/System/PosixCompat/Internal/Time.hs
@@ -0,0 +1,46 @@
+{-# LANGUAGE CPP #-}
+{-
+Compatibility wrapper to help manage the transition from
+old-time to time packages. Only used at all on win32.
+-}
+module System.PosixCompat.Internal.Time (
+      ClockTime
+    , getClockTime
+    , clockTimeToEpochTime
+    , ModificationTime
+    , modificationTimeToEpochTime
+    ) where
+
+import System.Posix.Types (EpochTime)
+
+#ifdef OLD_TIME
+
+import System.Time (ClockTime(TOD), getClockTime)
+
+clockTimeToEpochTime :: ClockTime -> EpochTime
+clockTimeToEpochTime (TOD s _) = fromInteger s
+
+type ModificationTime = ClockTime
+
+modificationTimeToEpochTime :: ModificationTime -> EpochTime
+modificationTimeToEpochTime = clockTimeToEpochTime
+
+#else
+
+import Data.Time.Clock (UTCTime)
+import Data.Time.Clock.POSIX (POSIXTime, getPOSIXTime, utcTimeToPOSIXSeconds)
+
+type ClockTime = POSIXTime
+
+getClockTime :: IO ClockTime
+getClockTime = getPOSIXTime
+
+clockTimeToEpochTime :: ClockTime -> EpochTime
+clockTimeToEpochTime = fromInteger . floor
+
+type ModificationTime = UTCTime
+
+modificationTimeToEpochTime :: UTCTime -> EpochTime
+modificationTimeToEpochTime = clockTimeToEpochTime . utcTimeToPOSIXSeconds
+
+#endif
diff --git a/src/System/PosixCompat/Temp.hs b/src/System/PosixCompat/Temp.hs
--- a/src/System/PosixCompat/Temp.hs
+++ b/src/System/PosixCompat/Temp.hs
@@ -21,7 +21,7 @@
 -- can use our own implementation of mkstemp.
 
 import System.IO (Handle)
-import Foreign.C (CInt, CString, withCString, peekCString, throwErrnoIfMinus1)
+import Foreign.C (CInt(..), CString, withCString, peekCString, throwErrnoIfMinus1)
 import GHC.IO.Handle.FD (fdToHandle)
 
 -- | 'mkstemp' - make a unique filename and open it for
diff --git a/src/System/PosixCompat/Time.hs b/src/System/PosixCompat/Time.hs
--- a/src/System/PosixCompat/Time.hs
+++ b/src/System/PosixCompat/Time.hs
@@ -18,16 +18,16 @@
 
 import Control.Monad (liftM)
 import System.Posix.Types (EpochTime)
-import System.Time (ClockTime(..), getClockTime)
 
+import System.PosixCompat.Internal.Time (
+      getClockTime, clockTimeToEpochTime
+    )
+
 -- | The portable version of @epochTime@ calls 'getClockTime' to obtain the
 --   number of seconds that have elapsed since the epoch (Jan 01 00:00:00 GMT
 --   1970).
 epochTime :: IO EpochTime
 epochTime = liftM clockTimeToEpochTime getClockTime
-
-clockTimeToEpochTime :: ClockTime -> EpochTime
-clockTimeToEpochTime (TOD s _) = fromInteger s
 
 #endif
 
diff --git a/src/System/PosixCompat/Unistd.hs b/src/System/PosixCompat/Unistd.hs
--- a/src/System/PosixCompat/Unistd.hs
+++ b/src/System/PosixCompat/Unistd.hs
@@ -25,7 +25,7 @@
 
 import Control.Concurrent (threadDelay)
 import Foreign.C.String (CString, peekCString)
-import Foreign.C.Types (CInt, CSize)
+import Foreign.C.Types (CInt(..), CSize(..))
 import Foreign.Marshal.Array (allocaArray)
 
 data SystemID = SystemID {
diff --git a/unix-compat.cabal b/unix-compat.cabal
--- a/unix-compat.cabal
+++ b/unix-compat.cabal
@@ -1,5 +1,5 @@
 name:           unix-compat
-version:        0.3.0.2
+version:        0.4.0.0
 synopsis:       Portable POSIX-compatibility layer.
 description:    This package provides portable implementations of parts
                 of the unix package. This package re-exports the unix
@@ -19,6 +19,10 @@
   type:     git
   location: git://github.com/jystic/unix-compat.git
 
+flag old-time
+  description: build against old-time package
+  default: False
+
 Library
   hs-source-dirs: src
   ghc-options: -Wall
@@ -35,16 +39,26 @@
     System.PosixCompat.User
 
   if os(windows)
-    build-depends: old-time >= 1.0.0.0 && < 1.2.0.0
     c-sources:
       cbits/HsUname.c
       cbits/mktemp.c
 
-    if impl(ghc < 7)
-      build-depends: directory == 1.0.*
-      cpp-options: -DDIRECTORY_1_0
+    if flag(old-time)
+      build-depends: old-time >= 1.0.0.0 && < 1.2.0.0
+      cpp-options: -DOLD_TIME
+
+      if impl(ghc < 7)
+        build-depends: directory == 1.0.*
+        cpp-options: -DDIRECTORY_1_0
+      else
+        build-depends: directory == 1.1.*
     else
-      build-depends: directory == 1.1.*
+      build-depends: time >= 1.0 && < 1.5
+      build-depends: directory >= 1.2 && < 1.3
+
+    other-modules:
+      System.PosixCompat.Internal.Time
+
   else
     build-depends: unix >= 2.4 && < 2.7
     include-dirs: include
