<html><head><meta http-equiv="Content-Type" content="text/html charset=windows-1252"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;">I don’t know the cause of the error, I commented on this related cabal issue I found: <a href="https://github.com/haskell/cabal/issues/1700">https://github.com/haskell/cabal/issues/1700</a><div><div><br><div><div>On Mar 10, 2014, at 14:41, Carter Schonwald <<a href="mailto:carter.schonwald@gmail.com">carter.schonwald@gmail.com</a>> wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div dir="ltr">So, was the issue cabal not catching the linker error?</div><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Mar 10, 2014 at 12:04 PM, Federico Mastellone <span dir="ltr"><<a href="mailto:fmaste@gmail.com" target="_blank">fmaste@gmail.com</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word">Found the problem,<div><br></div><div>I did not have the modules that were used but not exposed enumerated under "other-modules” on cabal's library definition. This builds OK on 7.6.3 even with a correct code coverage report, but fails to build with the linking error under 7.8-rc2. When I add the “other-modules” it works on both.</div>

<div><div class="h5"><div><br></div><div><br><div><div>On Mar 9, 2014, at 17:26, Carter Schonwald <<a href="mailto:carter.schonwald@gmail.com" target="_blank">carter.schonwald@gmail.com</a>> wrote:</div><br><blockquote type="cite">

<div dir="ltr">great!<div>Thanks for taking the time to shrink the bug, look forward to helping on the ticket</div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Sun, Mar 9, 2014 at 12:32 PM, Federico Mastellone <span dir="ltr"><<a href="mailto:fmaste@gmail.com" target="_blank">fmaste@gmail.com</a>></span> wrote:<br>



<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="auto"><div>With a package of mine that I reduced it to just two modules, the one on the link below. </div><div>



I did not file a bug, I wanted to ask here first. I'll do it now</div><div><div><br>On 09/03/2014, at 11:41, Carter Schonwald <<a href="mailto:carter.schonwald@gmail.com" target="_blank">carter.schonwald@gmail.com</a>> wrote:<br>



<br></div><blockquote type="cite">Ok. What cabal package?  Have you filed a bug report on ghc trac?<span></span><br><br>On Sunday, March 9, 2014, Federico Mastellone <<a href="mailto:fmaste@gmail.com" target="_blank">fmaste@gmail.com</a>> wrote:<br>



<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div style="word-wrap:break-word">Downloaded gcc-4.9 binary from <a href="http://hpc.sourceforge.net/" target="_blank">http://hpc.sourceforge.net</a> and tested again with both 7.6.3 and 7.8-rc2<div><br><div>Fails with the same error with 7.8-rc2 and does not fail with 7.6.3</div>




<div><br><div>ld: illegal text reloc in '_enablezmlibraryzmcoveragezm0zi0zi1_Library_sendMsg2_info' to '__hpc_tickboxes_enablezmlibraryzmcoveragezm0zi0zi1_Util_hpc' for architecture x86_64<br>collect2: error: ld returned 1 exit status</div>




<div><br><div><div>On Mar 7, 2014, at 16:58, Carter Schonwald <<a>carter.schonwald@gmail.com</a>> wrote:</div><br><blockquote type="cite">No.  Try real GCC.  Follow my linked directions.  Xcode GCC is fake.  It's clang.  Follow my directions please. <span></span><br>




<br>On Friday, March 7, 2014, Federico Mastellone <<a>fmaste@gmail.com</a>> wrote:<br>
<blockquote style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div style="word-wrap:break-word"><div>It’s the same error with and without the clang-xcode5-wrapper that is named as an alternative solution </div>





<div><br></div><div><div>On Mar 7, 2014, at 13:10, Carter Schonwald <<a>carter.schonwald@gmail.com</a>> wrote:</div><br><blockquote type="cite"><div dir="ltr">try using real GCC<div><br></div><div>i have these directions <a href="https://gist.github.com/cartazio/7131371" target="_blank">https://gist.github.com/cartazio/7131371</a></div>





</div><div><br><br><div>

On Fri, Mar 7, 2014 at 10:47 AM, Federico Mastellone <span dir="ltr"><<a>fmaste@gmail.com</a>></span> wrote:<br><blockquote style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

<div style="word-wrap:break-word">Hi,<div><br></div><div>On Mac OS X 10.9.2 with ghc 7.8.0.20140228 and cabal 1.18.0.3</div><div><br></div><div>Doing:</div><div><span style="line-height:18px;color:rgb(51,51,51);white-space:pre-wrap;font-family:Consolas,'Liberation Mono',Courier,monospace">cabal configure --enable-library-coverage</span></div>







<div><span style="line-height:18px;color:rgb(51,51,51);white-space:pre-wrap;font-family:Consolas,'Liberation Mono',Courier,monospace">cabal build</span></div><div><span style="line-height:18px;color:rgb(51,51,51);white-space:pre-wrap;font-family:Consolas,'Liberation Mono',Courier,monospace"><br>







</span></div><div>Fails with:</div><div><blockquote type="cite"><div style="margin:0px;font-size:11px;font-family:Menlo;background-color:rgb(254,244,156)">ld: illegal text reloc in '_enablezmlibraryzmcoveragezm0zi0zi1_Library_sendMsg2_info' to '__hpc_tickboxes_enablezmlibraryzmcoveragezm0zi0zi1_Util_hpc' for architecture x86_64</div>







<div style="margin:0px;font-size:11px;font-family:Menlo;background-color:rgb(254,244,156)">clang: error: linker command failed with exit code 1 (use -v to see invocation)</div></blockquote><br></div><div>But without the coverage flag it’s OK.</div>







<div><br></div><div>I found it when switching from 7.6.3 to 7.8.1RC2 on a project I have and was able to strip it to this:</div><div><a href="https://github.com/fmaste/ghc-7.8.0.20140228-enable-library-coverage" target="_blank">https://github.com/fmaste/ghc-7.8.0.20140228-enable-library-coverage</a></div>







<div><br></div><div>Don’t know if this is a cabal or ghc problem and I don’t know how to continue.</div><div><br></div><div>Thanks!</div><div><br></div><div>My ghc —info:</div><div> [("Project name","The Glorious Glasgow Haskell Compilation System")<br>







 ,("GCC extra via C opts"," -fwrapv")<br> ,("C compiler command","/usr/bin/gcc")<br> ,("C compiler flags"," -m64 -fno-stack-protector")<br> ,("C compiler link flags"," -m64")<br>







 ,("ld command","/usr/bin/ld")<br> ,("ld flags"," -arch x86_64")<br> ,("ld supports compact unwind","YES")<br> ,("ld supports build-id","NO")<br>







 ,("ld supports filelist","YES")<br> ,("ld is GNU ld","NO")<br> ,("ar command","/usr/bin/ar")<br> ,("ar flags","clqs")<br> ,("ar supports at file","NO")<br>







 ,("touch command","touch")<br> ,("dllwrap command","/bin/false")<br> ,("windres command","/bin/false")<br> ,("libtool command","libtool")<br>







 ,("perl command","/usr/bin/perl")<br> ,("target os","OSDarwin")<br> ,("target arch","ArchX86_64")<br> ,("target word size","8")<br> ,("target has GNU nonexec stack","False")<br>







 ,("target has .ident directive","True")<br> ,("target has subsections via symbols","True")<br> ,("Unregisterised","NO")<br> ,("LLVM llc command","llc")<br>







 ,("LLVM opt command","opt")<br> ,("Project version","7.8.0.20140228")<br> ,("Booter version","7.6.3")<br> ,("Stage","2")<br> ,("Build platform","x86_64-apple-darwin")<br>







 ,("Hos</div></div></blockquote></div></div></blockquote></div></div></blockquote></blockquote></div></div></div></div></div></blockquote>
</blockquote></div></div></blockquote></div><br></div>
</blockquote></div><br></div></div></div></div></blockquote></div><br></div>
</blockquote></div><br></div></div></body></html>