diff options
author | Matthew Pickering <matthewtpickering@gmail.com> | 2018-12-16 08:58:41 +0000 |
---|---|---|
committer | Matthew Pickering <matthewtpickering@gmail.com> | 2019-01-09 14:32:21 +0000 |
commit | 6486c6e49c53e75f37ed732b38c5be7ae64785e8 (patch) | |
tree | 187785dd532474cd34aa4e66846b12f28f09f8b9 /hadrian/src/Context.hs | |
parent | 6b70cf611e5ddc475edaa54b893d20990699ddb8 (diff) | |
download | haskell-6486c6e49c53e75f37ed732b38c5be7ae64785e8.tar.gz |
Hadrian: Add support for building stage3
This ticket enables the building of a `stage3` compiler by making the
build logic more consistent and predictable in Hadrian.
Two of the main changes are:
1. In order to build anything at stageN we use the package database
present at stageN. Fixing #16069
2. `haddock` and `ghc-tags` are built
as stage1 executables (with the stage1 compiler) rather than as
stage2 compiler. Fixing
[hadrian#661](https://github.com/snowleopard/hadrian/issues/661)
In order to build a stage3 compiler, you have to set the new `finalStage` hadrian option to `Stage3`.
Diffstat (limited to 'hadrian/src/Context.hs')
-rw-r--r-- | hadrian/src/Context.hs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/hadrian/src/Context.hs b/hadrian/src/Context.hs index 672b3a6004..8036eb00bc 100644 --- a/hadrian/src/Context.hs +++ b/hadrian/src/Context.hs @@ -103,9 +103,9 @@ pkgGhciLibraryFile context@Context {..} = do -- | Path to the configuration file of a given 'Context'. pkgConfFile :: Context -> Action FilePath pkgConfFile Context {..} = do - root <- buildRoot pid <- pkgIdentifier package - return $ root -/- relativePackageDbPath stage -/- pid <.> "conf" + dbPath <- packageDbPath stage + return $ dbPath -/- pid <.> "conf" -- | Given a 'Context' and a 'FilePath' to a source file, compute the 'FilePath' -- to its object file. For example: |