Help with build ordering issue

Ben Gamari ben at well-typed.com
Sun Feb 25 20:30:41 UTC 2018


Sylvain Henry <sylvain at haskus.fr> writes:

> On 20/02/2018 03:25, Ben Gamari wrote:
>> Sylvain Henry <sylvain at haskus.fr> writes:
>>
>>> Hi,
>>>
>>> @Bodigrim is working on a patch (https://phabricator.haskell.org/D4212)
>>> to fix #14170.
>>>
>>> The build fails because of interface file errors: "bad interface file"
>>> for GHC.Natural and "failed to load interface" for GHC.Types.
>>>
>>> I suspect it is a wired-in module build ordering issue but I haven't
>>> been able to help fixing it. If anyone with more insights could help it
>>> would be much appreciated!
>>>
>> Can you paste the full error? What module is failing to compile? Which
>> definition is it loading the interface for?
>>
>> Cheers,
>>
>> - Ben
>>
>
> "inplace/bin/ghc-stage1" -hisuf hi -osuf  o -hcsuf hc -static  -O0 -H64m -Wall      -this-unit-id base-4.11.0.0 -hide-all-packages -i -ilibraries/base/. -ilibraries/base/dist-install/build -Ilibraries/base/dist-install/build -ilibraries/base/dist-install/build/./autogen -Ilibraries/base/dist-install/build/./autogen -Ilibraries/base/include   -optP-DOPTIMISE_INTEGER_GCD_LCM -optP-include -optPlibraries/base/dist-install/build/./autogen/cabal_macros.h -package-id rts -package-id ghc-prim-0.5.2.0 -package-id integer-gmp-1.0.1.0 -this-unit-id base -XHaskell2010 -O  -no-user-package-db -rtsopts  -Wno-trustworthy-safe -Wno-deprecated-flags     -Wnoncanonical-monad-instances  -odir libraries/base/dist-install/build -hidir libraries/base/dist-install/build -stubdir libraries/base/dist-install/build   -dynamic-too -c libraries/base/./GHC/Natural.hs -o libraries/base/dist-install/build/GHC/Natural.o -dyno libraries/base/dist-install/build/GHC/Natural.dyn_o
>
> <interactive>:1:1: error:
>      Bad interface file: libraries/base/dist-install/build/GHC/Natural.hi
>          libraries/base/dist-install/build/GHC/Natural.hi: openBinaryFile: does not exist (No such file or directory)
>
Hmm, I'm afraid that's not particularly illuminating.

It would be helpful to see the output from -ddump-if-trace as this will
tell you why GHC is trying to load this interface file.

Cheers,

- Ben
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 487 bytes
Desc: not available
URL: <http://mail.haskell.org/pipermail/ghc-devs/attachments/20180225/968a0603/attachment.sig>


More information about the ghc-devs mailing list