From 3f50a4df4fc951f8876cc38c093471451cee2b88 Mon Sep 17 00:00:00 2001 From: Daniel Gröber Date: Mon, 7 Sep 2015 04:28:58 +0200 Subject: Fix exe caching when using --with-cabal-pkg-db --- CabalHelper/Compile.hs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/CabalHelper/Compile.hs b/CabalHelper/Compile.hs index 4d14dce..0de69b8 100644 --- a/CabalHelper/Compile.hs +++ b/CabalHelper/Compile.hs @@ -69,7 +69,10 @@ compileHelper opts cabalVer projdir distdir = withHelperSources $ \chdir -> do , cachedCabalPkg chdir , MaybeT (Just <$> compilePrivatePkgDb chdir) ] - mdb -> compileWithPkg chdir mdb cabalVer + mdb -> + run [ Right <$> MaybeT (cachedExe cabalVer) + , liftIO $ compileWithPkg chdir mdb cabalVer + ] where run actions = fromJust <$> runMaybeT (msum actions) -- cgit v1.2.3