[Haskell-cafe] OS X ghci problem

Carter Schonwald carter.schonwald at gmail.com
Mon Sep 16 17:57:31 CEST 2013


Christian,
Yes, ghc 7.7/7.8 *should* fix all the ghci linker related problems on
platforms that support dynamic linking!

If (or anyone else) finds problems with the ghci linker on 7.7, please
report them post haste!

I'm also glad to hear that someone's finally tested out the new ghci
functionality properly!

-Carter


On Mon, Sep 16, 2013 at 8:52 AM, Christiaan Baaij <
christiaan.baaij at gmail.com> wrote:

> Here's a binary dist of my build:
> https://www.dropbox.com/s/d37rij0dnvjiqqy/ghc-7.7.20130915-x86_64-apple-darwin.tar.bz2
> In case someone wants to confirm my findings.
>
> Cheers,
>
> Christiaan
>
> On Sep 16, 2013, at 2:24 PM, Christiaan Baaij <christiaan.baaij at gmail.com>
> wrote:
>
> > Hi,
> >
> > I saw the same issue/crash on my machine using ghc 7.6.3.
> >
> > I just build a "perf" build of GHC-head with
> > "85a9e2468dc74b9e5ccde0dd61be86219fd323a2" as the latest commit.
> >
> > Now running, I get:
> > 1) > cabal install bindings-glfw
> > 2) > ghci
> > 3) ghci> :m Bindings.GLFW
> > 4) ghci> Bindings.GLFW.c'glfwInit
> > 5) ghci> 1
> >
> > And doing:
> > 1.) > cabal install GLFW-b
> > 2.) > ghci -package GLFW-b
> > 3.) ghci> import Graphics.UI.GLFW as GLFW
> > 4.) ghci> GLFW.init
> > 5.) ghci> True
> >
> > My platform:
> > - OSX 10.8.4
> > - ghc(i) 7.7.20130915
> > - cabal 1.18.0.1 (using 1.18.0 of the Cabal library)
> > - xcode cltools 4.6.2
> >
> > So it seems that the new ghci linking infrastructure fixes things
> >
> > Cheers,
> >
> > Christiaan
> >
> > On Sep 14, 2013, at 9:00 PM, Jan-Philip Loos <maxdaten at gmail.com> wrote:
> >
> >>> What I do for GLFW is use a dylib, then you don't rely on GHCi's
> static-ish linker.
> >>> The only wrinkle is figuring out where you want the dylib.
> >>> I think homebrew will put one in /usr/local/lib, which works out
> nicely, but they don't have GLFW 3 yet.
> >>> Another option is to build the dylib yourself from the GLFW source
> bundled with the GLFW-b package, then tell cabal where to find it.
> >>
> >> Hi,
> >> for me the problem relocates now to the "bindings-glfw" package, since
> >> the native bindings moved to this package and are wrapped up with
> >> "glfw-b".
> >>
> >> My way to the same exception already mentioned by Brian Lewis:
> >> 1) > cabal install bindings-glfw
> >> 2) > ghci
> >> 3) ghci> :m Bindings.GLFW
> >> 4) ghci> Bindings.GLFW.c'glfwInit
> >> 5) ghci terminates with exception: *** Terminating app due to uncaught
> >> exception 'NSInvalidArgumentException', reason: '-[NSAutoreleasePool
> >> init]: unrecognized selector sent to instance 0x7fc443c01b30'
> >>
> >> Anthony Cowley mentioned to use ghci with GLFW as a dylib, I have no
> >> clue how to do this. I built the according glfw version on my own as a
> >> dylib and loaded ghci with it explicitly, this didn't help. I guess
> >> the compiled bindings-glfw is already statically packed up.
> >>
> >> How can I get ghci to use the native glfw dylib in combination with
> >> bindings-glfw? If I have to compile bindings-glfw with different
> >> settings, which settings? I have some oversight over haskell but no
> >> really deep knowledge according to bindings and lib-loading of ghci,
> >> but I'm willing to learn it ;)
> >>
> >> My Platform:
> >> - OSX 10.8.5
> >> - ghc(i) 7.6.3
> >> - cabal 1.18.0.1
> >> - xcode dev tools 4.6.3
> >>
> >> Thanks and Greetings
> >>
> >> Jan
> >> _______________________________________________
> >> Haskell-Cafe mailing list
> >> Haskell-Cafe at haskell.org
> >> http://www.haskell.org/mailman/listinfo/haskell-cafe
> >
>
> _______________________________________________
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org
> http://www.haskell.org/mailman/listinfo/haskell-cafe
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/haskell-cafe/attachments/20130916/3db25641/attachment.htm>


More information about the Haskell-Cafe mailing list