File tree Expand file tree Collapse file tree 4 files changed +3
-6
lines changed Expand file tree Collapse file tree 4 files changed +3
-6
lines changed Original file line number Diff line number Diff line change @@ -177,7 +177,6 @@ writeFlagCache gid flags deps = do
177177 let cache = ConfigCache
178178 { configCacheOpts = flags
179179 , configCacheDeps = deps
180- , configCabalFileModTime = Nothing -- FIXME I'm not convinced this should even be in ConfigCache
181180 }
182181 liftIO $ do
183182 createDirectoryIfMissing True $ toFilePath $ parent file
Original file line number Diff line number Diff line change @@ -326,7 +326,6 @@ checkDirtiness ps (Library installed) package present = do
326326 configCache = ConfigCache
327327 { configCacheOpts = map encodeUtf8 configOpts
328328 , configCacheDeps = present
329- , configCabalFileModTime = Nothing
330329 }
331330 moldOpts <- tryGetFlagCache installed
332331 case moldOpts of
Original file line number Diff line number Diff line change @@ -292,9 +292,11 @@ singleBuild ActionContext {..} ExecuteEnv {..} task@Task {..} =
292292 -- Determine the old and new configuration in the local directory, to
293293 -- determine if we need to reconfigure.
294294 mOldConfigCache <- tryGetConfigCache pkgDir
295+ -- FIXME check if the .cabal file has changed
296+ -- mOldCabalMod <- tryGetCabalMod pkgDir
297+ -- now <- liftIO (getModificationTime (toFilePath cabalfp))
295298
296299 idMap <- liftIO $ readTVarIO eeGhcPkgIds
297- now <- liftIO (getModificationTime (toFilePath cabalfp))
298300 let getMissing ident =
299301 case Map. lookup ident idMap of
300302 Nothing -> error " singleBuild: invariant violated, missing package ID missing"
@@ -307,7 +309,6 @@ singleBuild ActionContext {..} ExecuteEnv {..} task@Task {..} =
307309 newConfigCache = ConfigCache
308310 { configCacheOpts = map encodeUtf8 configOpts
309311 , configCacheDeps = allDeps
310- , configCabalFileModTime = Just $ modTime now
311312 }
312313
313314 when (mOldConfigCache /= Just newConfigCache) $ withMVar eeConfigureLock $ \ _ -> do
Original file line number Diff line number Diff line change @@ -315,8 +315,6 @@ data ConfigCache = ConfigCache
315315 -- the complete GhcPkgId (only a PackageIdentifier) in the configure
316316 -- options, just using the previous value is insufficient to know if
317317 -- dependencies have changed.
318- , configCabalFileModTime :: ! (Maybe ModTime )
319- -- ^ Last time the .cabal file was changed.
320318 }
321319 deriving (Generic ,Eq ,Show )
322320instance Binary ConfigCache
You can’t perform that action at this time.
0 commit comments