Joachim Breitner <m...@joachim-breitner.de> writes:

> Hi Ben,
>
>
> Am Freitag, den 28.11.2014, 18:27 -0500 schrieb Ben Gamari:
>> I've written down some thoughts on the current status and future
>> direction of the LLVM backend here [1].
>
> thanks. I tried to build ghc-7.8.4-rc1 on Debian, and it failed on arm*.
> First, because it picked llvm-3.5. After I tightened the dependencies to
> use llvm-3.4, it failed with 
>         dll-split: internal error: evacuate(static): strange closure
>         type 0
>             (GHC version 7.8.3.20141119 for arm_unknown_linux)

Indeed this looks like ld.bfd is being used.

> I then followed your advice from somewhere else and passed
> "--with-ld=ld.gold" to ./configure, but with the same effect:

Unfortunately I don't think this will be sufficient. I believe this
will only set the `LD` variable in the build system, which as far qas I
know is never used. We always call gcc to do our linking for us;
gcc will in turn just use whatever `ld` it finds in `PATH`. For this
reason I have resorted to simply adding a directory containing a symlink
to `ld.gold` to `PATH`. This is what this script[1] does.

Unfortunately it's also a bit more subtle than this; it's very likely
that the ghc you are bootstrapping from contains relocations that aren't
supported by gold. For this reason you'll likely need to build some of
the utilities with `ld.bfd` the continue the build with `ld.gold`. The
above script implements this fairly reliably.

Cheers,

- Ben


[1] https://gist.github.com/bgamari/9399430

Attachment: pgpNowSMepbYK.pgp
Description: PGP signature

_______________________________________________
ghc-devs mailing list
ghc-devs@haskell.org
http://www.haskell.org/mailman/listinfo/ghc-devs

Reply via email to