Commit 8d86ac8f authored by Duncan Coutts's avatar Duncan Coutts
Browse files

Pass dist dir and verbosity flags to build and install phases

parent 19c56374
......@@ -337,15 +337,22 @@ installUnpackedPackage verbosity scriptOptions miscOptions configFlags
= onFailure ConfigureFailed $ do
setup configureCommand (filterConfigureFlags configFlags)
onFailure BuildFailed $ do
setup buildCommand (const Cabal.emptyBuildFlags)
setup buildCommand buildFlags
onFailure InstallFailed $ do
case rootCmd miscOptions of
(Just cmd) -> reexec cmd
Nothing -> setup Cabal.installCommand
(const Cabal.emptyInstallFlags)
Nothing -> setup Cabal.installCommand installFlags
return BuildOk
where
buildCommand = Cabal.buildCommand defaultProgramConfiguration
buildFlags _ = Cabal.emptyBuildFlags {
Cabal.buildDistPref = Cabal.configDistPref configFlags,
Cabal.buildVerbosity = Cabal.toFlag verbosity
}
installFlags _ = Cabal.emptyInstallFlags {
Cabal.installDistPref = Cabal.configDistPref configFlags,
Cabal.installVerbosity = Cabal.toFlag verbosity
}
setup cmd flags = do
logFileHandle <- case useLogFile of
Nothing -> return Nothing
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment