Hadrian: Fix untracked dependencies
This is a preparation for #16295: https://ghc.haskell.org/trac/ghc/ticket/16295 This commit mostly focuses on getting rid of untracked dependencies, which prevent Shake's new `--shared` feature from appropriately caching build rules. There are three different solutions to untracked dependencies: * Track them! This is the obvious and the best approach, but in some situations we cannot use it, for example, because a build rule creates files whose names are not known statically and hence cannot be specified as the rule's outputs. * Use Shake's `produces` to record outputs dynamically, within the rule. * Use Shake's `historyDisable` to disable caching for a particular build rule. We currently use this approach only for `ghc-pkg` which mutates the package database and the file `package.cache`. These two tickets are fixed as the result: Ticket #16271: https://ghc.haskell.org/trac/ghc/ticket/16271 Ticket #16272: https://ghc.haskell.org/trac/ghc/ticket/16272 (this one is fixed only partially: we correctly record the dependency, but we still copy files into the RTS build tree).
Showing
- hadrian/hadrian.cabal 1 addition, 1 deletionhadrian/hadrian.cabal
- hadrian/src/Base.hs 14 additions, 8 deletionshadrian/src/Base.hs
- hadrian/src/Builder.hs 8 additions, 6 deletionshadrian/src/Builder.hs
- hadrian/src/Context.hs 4 additions, 12 deletionshadrian/src/Context.hs
- hadrian/src/Hadrian/Haskell/Cabal.hs 1 addition, 2 deletionshadrian/src/Hadrian/Haskell/Cabal.hs
- hadrian/src/Hadrian/Haskell/Cabal/Parse.hs 36 additions, 22 deletionshadrian/src/Hadrian/Haskell/Cabal/Parse.hs
- hadrian/src/Hadrian/Haskell/Cabal/Type.hs 29 additions, 28 deletionshadrian/src/Hadrian/Haskell/Cabal/Type.hs
- hadrian/src/Hadrian/Oracles/Cabal/Rules.hs 6 additions, 1 deletionhadrian/src/Hadrian/Oracles/Cabal/Rules.hs
- hadrian/src/Oracles/ModuleFiles.hs 8 additions, 1 deletionhadrian/src/Oracles/ModuleFiles.hs
- hadrian/src/Packages.hs 26 additions, 7 deletionshadrian/src/Packages.hs
- hadrian/src/Rules.hs 2 additions, 2 deletionshadrian/src/Rules.hs
- hadrian/src/Rules/Compile.hs 51 additions, 74 deletionshadrian/src/Rules/Compile.hs
- hadrian/src/Rules/Configure.hs 2 additions, 0 deletionshadrian/src/Rules/Configure.hs
- hadrian/src/Rules/Dependencies.hs 14 additions, 22 deletionshadrian/src/Rules/Dependencies.hs
- hadrian/src/Rules/Documentation.hs 7 additions, 10 deletionshadrian/src/Rules/Documentation.hs
- hadrian/src/Rules/Generate.hs 27 additions, 38 deletionshadrian/src/Rules/Generate.hs
- hadrian/src/Rules/Gmp.hs 22 additions, 27 deletionshadrian/src/Rules/Gmp.hs
- hadrian/src/Rules/Libffi.hs 32 additions, 27 deletionshadrian/src/Rules/Libffi.hs
- hadrian/src/Rules/Register.hs 58 additions, 32 deletionshadrian/src/Rules/Register.hs
- hadrian/src/Settings.hs 12 additions, 2 deletionshadrian/src/Settings.hs
Loading
Please register or sign in to comment