Fix writing COFF files when cross-compiling on OSX

Rafael Espíndola rafael.espindola at gmail.com
Thu Sep 4 11:47:55 PDT 2014


Can you add a testcase to the patch?

On 28 May 2014 11:34, Stanislav Karchebny <berkus at madfire.net> wrote:
> The issue: Trying to build an EFI application with clang on OSX host.
>
> Specifying -target i386-pe—coff resulted in abort from MCWinCOFFStreamer:
>
> fatal error in backend: alignment is limited to 32-bytes
>
> Turns out, that while the streamer was created for coff, the asm backend and asminfo were created for ELF output.
> The attached patch fixes it by creating appropriate objects when COFF output is requested.
>
> After applying the patch I was able to successfully build and run my EFI application using only clang/lld (no GNU or MSVC tools involved).
>
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>




More information about the llvm-commits mailing list