From 23864c59abfc6dad5a6b137941d618903817e1e3 Mon Sep 17 00:00:00 2001 From: Daniel Gröber Date: Sun, 4 Aug 2019 21:14:45 +0200 Subject: Allow passing override-env to process functions Unfortunately we need this to pass a custom GHC executable path to stack, since it doesn't have an option to override it on the commandline (yet?). --- src/CabalHelper/Compiletime/Cabal.hs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/CabalHelper/Compiletime/Cabal.hs') diff --git a/src/CabalHelper/Compiletime/Cabal.hs b/src/CabalHelper/Compiletime/Cabal.hs index 85ab83c..ef6de8c 100644 --- a/src/CabalHelper/Compiletime/Cabal.hs +++ b/src/CabalHelper/Compiletime/Cabal.hs @@ -182,15 +182,15 @@ unpackCabalHackage cabalVer tmpdir variant = do dir = tmpdir cabal variant_opts = case variant of Pristine -> [ "--pristine" ]; _ -> [] args = [ "get", cabal ] ++ variant_opts - callProcessStderr (Just tmpdir) (cabalProgram ?progs) args + callProcessStderr (Just tmpdir) [] (cabalProgram ?progs) args return $ CabalSourceDir dir unpackCabalHEAD :: Env => FilePath -> IO (CommitId, CabalSourceDir) unpackCabalHEAD tmpdir = do let dir = tmpdir "cabal-head.git" url = "https://github.com/haskell/cabal.git" - callProcessStderr (Just "/") "git" [ "clone", "--depth=1", url, dir] - callProcessStderr (Just (dir "Cabal")) "cabal" + callProcessStderr (Just "/") [] "git" [ "clone", "--depth=1", url, dir] + callProcessStderr (Just (dir "Cabal")) [] "cabal" [ "act-as-setup", "--", "sdist" , "--output-directory=" ++ tmpdir "Cabal" ] commit <- takeWhile isHexDigit <$> -- cgit v1.2.3