<div dir="ltr"><div><span style="color:rgb(0,0,0);font-family:Helvetica;font-size:12px">Thanks!</span></div><div><span style="color:rgb(0,0,0);font-family:Helvetica;font-size:12px"><br></span></div><span style="color:rgb(0,0,0);font-family:Helvetica;font-size:12px">This seems to do the trick wonderfully.</span><div style="color:rgb(0,0,0);font-family:Helvetica;font-size:12px">

<div style="margin:0px;font-size:11px;font-family:Menlo;color:rgb(195,55,32)">-ghclibdir     = $(libdir)/ghc-$(ProjectVersion)</div><div style="margin:0px;font-size:11px;font-family:Menlo;color:rgb(52,189,38)">+ghclibdir     = $(libdir)/$(CrossCompilePrefix)ghc-$(ProjectVersion)</div>

<div style="margin:0px;font-size:11px;font-family:Menlo;color:rgb(52,189,38)"><br></div><div style="margin:0px">I&#39;ve just done a clean build with this and it&#39;s working perfectly.</div></div></div><div class="gmail_extra">

<br><br><div class="gmail_quote">On Sat, Aug 31, 2013 at 2:26 PM, Gabor Greif <span dir="ltr">&lt;<a href="mailto:ggreif@gmail.com" target="_blank">ggreif@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

<div class="im">On 8/31/13, Luke Iannini &lt;<a href="mailto:lukexipd@gmail.com">lukexipd@gmail.com</a>&gt; wrote:<br>
</div><div class="im">&gt; Hi Gabor!<br>
&gt; Yes, I believe that&#39;s still the case (we&#39;re working around it by using<br>
&gt; different prefixes for each architecture at the moment). And I think we<br>
&gt; should definitely do what you propose. I&#39;ll see if I can get a patch<br>
&gt; together shortly (or if someone already knows exactly what to do and wants<br>
&gt; to do it first, feel free! : )).<br>
<br>
</div>This is probably where one should start,<br>
<br>
<a href="https://github.com/ghc/ghc/blob/master/mk/install.mk.in#L108" target="_blank">https://github.com/ghc/ghc/blob/master/mk/install.mk.in#L108</a><br>
<br>
but be careful with the &#39;if&#39;s in the makefile!<br>
<br>
Cheers,<br>
<br>
    Gabor<br>
<div class="HOEnZb"><div class="h5"><br>
<br>
&gt;<br>
&gt; Cheers<br>
&gt; Luke<br>
&gt;<br>
&gt;<br>
&gt; On Sat, Aug 31, 2013 at 4:50 AM, Gabor Greif &lt;<a href="mailto:ggreif@gmail.com">ggreif@gmail.com</a>&gt; wrote:<br>
&gt;<br>
&gt;&gt; Hi Luke, devs,<br>
&gt;&gt;<br>
&gt;&gt; Just a quick question, as I haven&#39;t recently built a cross-compiler,<br>
&gt;&gt; but I have noticed a problem with installation of cross-ghc last time.<br>
&gt;&gt;<br>
&gt;&gt; $ ls &lt;prefix&gt;/lib/ghc-7.7.20130412<br>
&gt;&gt;<br>
&gt;&gt; The problem is, that when someone installs a non-cross<br>
&gt;&gt; compiler the same day, the cross-compiler&#39;s<br>
&gt;&gt; libraries and executables get overwritten<br>
&gt;&gt; by the non-cross installation :-(<br>
&gt;&gt;<br>
&gt;&gt; This probably also happens with release versions.<br>
&gt;&gt;<br>
&gt;&gt; Can you confirm this behaviour with HEAD?<br>
&gt;&gt;<br>
&gt;&gt; In case yes, should we consider adding a<br>
&gt;&gt; cross-prefix, like employed in bin/ ?<br>
&gt;&gt;<br>
&gt;&gt; $ ls &lt;prefix&gt;/bin/powerpc-montavista-linux-gnuspe-ghc-pkg-7.7.20130412<br>
&gt;&gt;<br>
&gt;&gt; Of course all the links inside must be re-aligned accordingly.<br>
&gt;&gt;<br>
&gt;&gt; Cheers,<br>
&gt;&gt;<br>
&gt;&gt;     Gabor<br>
&gt;&gt;<br>
&gt;&gt;<br>
&gt;&gt; On 8/31/13, Luke Iannini &lt;<a href="mailto:lukexipd@gmail.com">lukexipd@gmail.com</a>&gt; wrote:<br>
&gt;&gt; &gt; I will tell Stephen!<br>
&gt;&gt; &gt;<br>
&gt;&gt; &gt; I&#39;ve added iOS as Tier 2 — I bet we can find a sponsor for a buildbot<br>
&gt;&gt; down<br>
&gt;&gt; &gt; the line — and I&#39;ve added myself while I wait to hear from Stephen. It<br>
&gt;&gt; &gt; looks like the mailto links on the wiki (e.g. the names in the Platform<br>
&gt;&gt; &gt; Maintainers section) aren&#39;t working, by the way:<br>
&gt;&gt; &gt; <a href="http://ghc.haskell.org/trac/ghc/wiki/CodeOwners" target="_blank">http://ghc.haskell.org/trac/ghc/wiki/CodeOwners</a>.<br>
&gt;&gt; &gt;<br>
&gt;&gt; &gt; Cheers<br>
&gt;&gt; &gt; Luke<br>
&gt;&gt; &gt;<br>
&gt;&gt; &gt;<br>
&gt;&gt; &gt; On Fri, Aug 30, 2013 at 2:04 AM, Simon Peyton-Jones<br>
&gt;&gt; &gt; &lt;<a href="mailto:simonpj@microsoft.com">simonpj@microsoft.com</a>&gt;wrote:<br>
&gt;&gt; &gt;<br>
&gt;&gt; &gt;&gt;  Great.  Please thank Stephen too.. I don’t have his email.****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; ** **<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; Just go ahead and modify ****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; <a href="http://ghc.haskell.org/trac/ghc/wiki/CodeOwners****" target="_blank">http://ghc.haskell.org/trac/ghc/wiki/CodeOwners****</a><br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; <a href="http://ghc.haskell.org/trac/ghc/wiki/Platforms****" target="_blank">http://ghc.haskell.org/trac/ghc/wiki/Platforms****</a><br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; ** **<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; I assume iOS will become a tier-2 platform?****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; ** **<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; Simon****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; ** **<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; *From:* Luke Iannini [mailto:<a href="mailto:lukexipd@gmail.com">lukexipd@gmail.com</a>]<br>
&gt;&gt; &gt;&gt; *Sent:* 30 August 2013 09:07<br>
&gt;&gt; &gt;&gt; *To:* Simon Peyton-Jones<br>
&gt;&gt; &gt;&gt; *Cc:* Austin Seipp<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; *Subject:* Re: [Haskell-cafe] Announcing GHC iOS****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt;  ** **<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; Certainly! And I&#39;d be happy to take on maintainership of GHC iOS if<br>
&gt;&gt; &gt;&gt; that&#39;s<br>
&gt;&gt; &gt;&gt; what you mean — I&#39;ve committed to a very large project using it so<br>
&gt;&gt; &gt;&gt; I&#39;ll<br>
&gt;&gt; &gt;&gt; be<br>
&gt;&gt; &gt;&gt; maintaining it anyway : ). I&#39;d guess Stephen would feel the same.****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; ** **<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; And thanks so much for the kind words, it means the world! Thank you<br>
&gt;&gt; &gt;&gt; infinitely for Haskell : ).****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; ** **<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; Cheers****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; Luke****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; ** **<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; On Fri, Aug 30, 2013 at 12:32 AM, Simon Peyton-Jones &lt;<br>
&gt;&gt; &gt;&gt; <a href="mailto:simonpj@microsoft.com">simonpj@microsoft.com</a>&gt; wrote:****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt;  Should we update the “Platform maintainers” on<br>
&gt;&gt; &gt;&gt; <a href="http://ghc.haskell.org/trac/ghc/wiki/TeamGHC****" target="_blank">http://ghc.haskell.org/trac/ghc/wiki/TeamGHC****</a><br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; or the list of supported platforms on<br>
&gt;&gt; &gt;&gt; <a href="http://ghc.haskell.org/trac/ghc/wiki/Platforms?****" target="_blank">http://ghc.haskell.org/trac/ghc/wiki/Platforms?****</a><br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt;  ****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; *From:* Haskell-Cafe [mailto:<a href="mailto:haskell-cafe-bounces@haskell.org">haskell-cafe-bounces@haskell.org</a>] *On<br>
&gt;&gt; Behalf<br>
&gt;&gt; &gt;&gt; Of *Luke Iannini<br>
&gt;&gt; &gt;&gt; *Sent:* 29 August 2013 21:56<br>
&gt;&gt; &gt;&gt; *To:* Haskell Cafe<br>
&gt;&gt; &gt;&gt; *Subject:* Re: [Haskell-cafe] Announcing GHC iOS****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt;  ****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; Stephen provided some more credits — thanks so much to all!****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt;  ****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; Three connected projects concerning cross-compilation:****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt;  ****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; *Registerised ARM support, added using David Terei&#39;s LLVM compiler<br>
&gt;&gt; &gt;&gt; back<br>
&gt;&gt; &gt;&gt; end with Stephen Blackheath doing an initial ARMv5 version and LLVM<br>
&gt;&gt; patch<br>
&gt;&gt; &gt;&gt; and Karel Gardas working on floating point support, ARMv7<br>
&gt;&gt; &gt;&gt; compatibility<br>
&gt;&gt; &gt;&gt; and<br>
&gt;&gt; &gt;&gt; LLVM headaches. Ben Gamari did work on the runtime linker for ARM.****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt;  ****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; *General cross-compiling, with much work by Stephen Blackheath and<br>
&gt;&gt; &gt;&gt; Gabor<br>
&gt;&gt; &gt;&gt; Greif (though many others have worked on this).****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt;  ****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; *A cross-compiler for Apple iOS. iOS-specific parts were mostly<br>
&gt;&gt; &gt;&gt; Stephen<br>
&gt;&gt; &gt;&gt; Blackheath with Luke Iannini on the Cabal patch, testing and<br>
&gt;&gt; &gt;&gt; supporting<br>
&gt;&gt; &gt;&gt; infrastructure, also with assistance and testing by Miëtek Bak and<br>
&gt;&gt; &gt;&gt; Jonathan<br>
&gt;&gt; &gt;&gt; Fischoff, and thanks to many others for testing; The iOS cross<br>
&gt;&gt; &gt;&gt; compiler<br>
&gt;&gt; &gt;&gt; was<br>
&gt;&gt; &gt;&gt; started back in 2009 by Stephen Blackheath with funding from Ryan<br>
&gt;&gt; Trinkle<br>
&gt;&gt; &gt;&gt; of iPwn Studios.****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt;  ****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; Thanks to Ian Lynagh for making it easy for us with integration,<br>
&gt;&gt; makefile<br>
&gt;&gt; &gt;&gt; refactoring and patience, and to David Terei for LLVM assistance.****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt;  ****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt;  ****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; On Thu, Aug 29, 2013 at 1:43 PM, Luke Iannini &lt;<a href="mailto:lukexipd@gmail.com">lukexipd@gmail.com</a>&gt;<br>
&gt;&gt; &gt;&gt; wrote:*<br>
&gt;&gt; &gt;&gt; ***<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt;  Hi all!****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; (in case you don&#39;t read /r/haskell : ))****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt;  ****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; Stephen Blackheath and I are extremely happy to report that as of<br>
&gt;&gt; &gt;&gt; today,<br>
&gt;&gt; &gt;&gt; GHC can natively build binaries for iOS devices and the iOS<br>
&gt;&gt; &gt;&gt; Simulator.****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt;  ****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; You&#39;ll find everything you need here:<br>
&gt;&gt; &gt;&gt; <a href="http://ghc.haskell.org/trac/ghc/wiki/Building/CrossCompiling/iOS****" target="_blank">http://ghc.haskell.org/trac/ghc/wiki/Building/CrossCompiling/iOS****</a><br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt;  ****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; The short of it is you can use &quot;ghc-ios myFiles.hs&quot; to get a universal<br>
&gt;&gt; &gt;&gt; ARMv7/ARMv7s/i386 static library to drop straight into an Xcode<br>
&gt;&gt; &gt;&gt; project.**<br>
&gt;&gt; &gt;&gt; **<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt;  ****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; Stephen&#39;s already working on some wonderful FRP-powered games, I&#39;m<br>
&gt;&gt; &gt;&gt; working<br>
&gt;&gt; &gt;&gt; on a project called SpaceTime that I&#39;ll announce shortly, and you may<br>
&gt;&gt; now<br>
&gt;&gt; &gt;&gt; all begin creating insanely great iOS software using the finest<br>
&gt;&gt; &gt;&gt; language<br>
&gt;&gt; &gt;&gt; in<br>
&gt;&gt; &gt;&gt; the world : ).****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt;  ****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt; Stephen deserves the lion&#39;s share of the credit for this project —<br>
&gt;&gt; &gt;&gt; it&#39;s<br>
&gt;&gt; &gt;&gt; been over 3 years in the making! Many thanks to Maxwell Swadling for<br>
&gt;&gt; &gt;&gt; generalizing static library builds into a -staticlib flag for GHC,<br>
&gt;&gt; Carter<br>
&gt;&gt; &gt;&gt; Schonwald for compilation guidance, and the venerable Austin Seipp for<br>
&gt;&gt; &gt;&gt; reviewing and merging our patches.****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt;   ****<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;&gt;  ** **<br>
&gt;&gt; &gt;&gt;<br>
&gt;&gt; &gt;<br>
&gt;&gt;<br>
&gt;<br>
</div></div></blockquote></div><br></div>