Usually, when ghccompiling the source code, it creates at least a file .o(object) and .hi(interface).
In the interest of reducing compilation time, if I only need an interface file, can I somehow order ghcto abandon everything else and just give me the specified interface file? Or, otherwise, get this interface using any little trick?
I found this ghcpart of the user manual and it does not say anything. This one does not mention the “interface” anywhere in the text. (In particular, it -fno-codedoes not generate it.) This does not mean that there is no easy way. In this matter, since five years ago , nothing has surfaced, but by chance now everything is different?
Most likely, I expect it to crack ghc. If so, then I would like to:
- Is it possible to send a request to the trac function , or (most likely) should I go for it myself?
- How is a file
.hidifferent from something like -ddump-types, just binary? - Is there any certainty that
.histrictly fewer compilation steps are required for linking a file than a complete file .o? (For example, if .hithere are hashes of fragments of machine code, probably the appropriate code should be generated, which means that nothing needs to be done here.)
Otherwise, maybe I can just extract the related parts from the code ghc, then to compile the file .hifrom the output -ddump-typesor the like?
source
share