Window build broken

Simon Peyton Jones simonpj at microsoft.com
Wed Nov 18 08:31:28 UTC 2015


I’m happy to do experiments to help narrow it down, but I haven’t the foggiest idea where to start, and am utterly stalled on GHC

Thanks

Simon

From: ghc-devs [mailto:ghc-devs-bounces at haskell.org] On Behalf Of lonetiger at gmail.com
Sent: 17 November 2015 23:51
To: Ryan Scott; ghc-devs at haskell.org
Subject: RE: Window build broken

Well the error is correct, it’s just checking against the machine type in the PE spec:

IMAGE_FILE_MACHINE_AMD64

0x8664

x64


So somewhere along the line an invalid PE file was generated (or for the wrong architecture).

From: Ryan Scott
Sent: Wednesday, November 18, 2015 00:44
To: ghc-devs at haskell.org<mailto:ghc-devs at haskell.org>
Subject: Re: Window build broken


Wow, I happened to try building GHC on Windows for the first time ever
today, and I also experienced this error :)

Interestingly, someone reported a very similar error to this on Trac,
but for GHC 7.8.3 [1]. Here's where the error message comes from [2]
in Linker.c:

    static int verifyCOFFHeader
    (COFF_header *hdr, pathchar *fileName)
    {
      if (hdr->Machine != 0x8664) {
        errorBelch("%" PATH_FMT ": Not x86_64 PEi386", fileName);
        return 0;
      }
      ...
    }

Ryan S.
-----
[1] https://ghc.haskell.org/trac/ghc/ticket/10437
[2] https://github.com/ghc/ghc/blob/233d1312bf15940fca5feca6884f965e7944b555/rts/Linker.c#L3355
_______________________________________________
ghc-devs mailing list
ghc-devs at haskell.org<mailto:ghc-devs at haskell.org>
http://mail.haskell.org/cgi-bin/mailman/listinfo/ghc-devs


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-devs/attachments/20151118/a49c211f/attachment.html>


More information about the ghc-devs mailing list