Skip to content

Commit

Permalink
haddock: Copy interface files to tmp dir
Browse files Browse the repository at this point in the history
In the last commits we started re-using GHC's interface files and
objects in haddock in order to avoid recompilation.

However, if haddock is run with different flags than GHC (say, for example,
`haddock-options: -DSomethingCustom`), it will recompile the interfaces
and objects.

This commit introduces a guardrail to the process of re-using GHC's
compilation files: instead of running haddock directly on the
directories where GHC placed its output, copy the directory contents to
a temporary directory and point haddock to the objects and interfaces
there. Even if recompilation is triggered by haddock, the objects
produced by GHC will be left untouched.
  • Loading branch information
alt-romes authored and Mikolaj committed May 30, 2024
1 parent 68fcd33 commit a1e14a7
Show file tree
Hide file tree
Showing 2 changed files with 211 additions and 151 deletions.
Loading

0 comments on commit a1e14a7

Please sign in to comment.