[GHC] #10568: Regression from 7.8.4, loading GLUT into GHCI fails on the Mac

GHC ghc-devs at haskell.org
Fri Jun 26 23:58:13 UTC 2015


#10568: Regression from 7.8.4, loading GLUT into GHCI fails on the Mac
-------------------------------+-----------------------------------------
        Reporter:  George      |                   Owner:
            Type:  bug         |                  Status:  infoneeded
        Priority:  normal      |               Milestone:  7.10.2
       Component:  Compiler    |                 Version:  7.10.1
      Resolution:              |                Keywords:
Operating System:  MacOS X     |            Architecture:  x86_64 (amd64)
 Type of failure:  GHCi crash  |               Test Case:
      Blocked By:              |                Blocking:
 Related Tickets:              |  Differential Revisions:
-------------------------------+-----------------------------------------

Comment (by Rydgel):

 Disclaimer: I'm not a pro on "linking" subjects but I did use otool (not
 sure if it's the way to do it properly on os x):


 {{{
 otool -L .cabal-sandbox/lib/x86_64-osx-
 ghc-7.10.1/GLUT-2.7.0.1-0waW9bZutCf5s5H5zSV4Oh/libHSGLUT-2.7.0.1
 -0waW9bZutCf5s5H5zSV4Oh-ghc7.10.1.dylib
 .cabal-sandbox/lib/x86_64-osx-
 ghc-7.10.1/GLUT-2.7.0.1-0waW9bZutCf5s5H5zSV4Oh/libHSGLUT-2.7.0.1
 -0waW9bZutCf5s5H5zSV4Oh-ghc7.10.1.dylib:

 @rpath/libHSGLUT-2.7.0.1-0waW9bZutCf5s5H5zSV4Oh-ghc7.10.1.dylib
 (compatibility version 0.0.0, current version 0.0.0)
 @rpath/libHScontainers-0.5.6.2-47ajk3tbda43DFWyeF3oHQ-ghc7.10.1.dylib
 (compatibility version 0.0.0, current version 0.0.0)
 @rpath/libHSOpenGL-2.12.0.1-EpjHCLjhm8PK9gj1WiMLLT-ghc7.10.1.dylib
 (compatibility version 0.0.0, current version 0.0.0)
 @rpath/libHStext-1.2.0.4-IINWRW1LxFGIctooOLjJAI-ghc7.10.1.dylib
 (compatibility version 0.0.0, current version 0.0.0)
 @rpath/libHSbytestring-0.10.6.0-6vj5EoliHgNHISHCVCb069-ghc7.10.1.dylib
 (compatibility version 0.0.0, current version 0.0.0)
 @rpath/libHSdeepseq-1.4.1.1-FpR4obOZALU1lutWnrBldi-ghc7.10.1.dylib
 (compatibility version 0.0.0, current version 0.0.0)
 @rpath/libHSStateVar-1.1.0.0-FY7FZJIuVXGGZZi7Rs1xyW-ghc7.10.1.dylib
 (compatibility version 0.0.0, current version 0.0.0)
 @rpath/libHSstm-2.4.4-877J9sNBpfS5cK4JeYiRK0-ghc7.10.1.dylib
 (compatibility version 0.0.0, current version 0.0.0)
 @rpath/libHSarray-0.5.1.0-FaHmcBFfuRM8kmZLEY8D5S-ghc7.10.1.dylib
 (compatibility version 0.0.0, current version 0.0.0)
 @rpath/libHSObjectName-1.1.0.0-Fs9LwEoYTY29YOLwQayVnG-ghc7.10.1.dylib
 (compatibility version 0.0.0, current version 0.0.0)
 @rpath/libHSGLURaw-1.5.0.1-9IfVeAwyYToLvYIDA0QjxP-ghc7.10.1.dylib
 (compatibility version 0.0.0, current version 0.0.0)
 @rpath/libHSOpenGLRaw-2.5.0.0-GkhI7NuLynWIs968DbpvQs-ghc7.10.1.dylib
 (compatibility version 0.0.0, current version 0.0.0)
 @rpath/libHStransformers-0.4.2.0-ALYlebOVzVI4kxbFX5SGhm-ghc7.10.1.dylib
 (compatibility version 0.0.0, current version 0.0.0)
 @rpath/libHSbase-4.8.0.0-I5BErHzyOm07EBNpKBEeUv-ghc7.10.1.dylib
 (compatibility version 0.0.0, current version 0.0.0)
 @rpath/libHSinteger-gmp-1.0.0.0-2aU3IZNMF9a7mQ0OzsZ0dS-ghc7.10.1.dylib
 (compatibility version 0.0.0, current version 0.0.0)
 @rpath/libHSghc-prim-0.4.0.0-8TmvWUcS1U1IKHT0levwg3-ghc7.10.1.dylib
 (compatibility version 0.0.0, current version 0.0.0)
 /usr/lib/libiconv.2.dylib (compatibility version 7.0.0, current version
 7.0.0)
 /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version
 1213.0.0)
 }}}

 I don't see any reference to GLUT framework though I don't think it is the
 issue. Let me explain: I checked a similar project with an OpenGL lib that
 use the Mac OS X OpenGL Framework. He does not show up inside the
 {{{libHSOpenGLRaw...dylib}}} too, but GHCI is working fine and the
 bindings work.

 ----

 I also tried something else: instead of using GLUT as a library for a
 project, I cloned the project itself and tried to load it up on GHCI.
 Building seems fine but the result of loading the lib in the repl is the
 same though the error is slightly different:

 {{{
 cabal repl

 Resolving dependencies...
 Configuring GLUT-2.7.0.1...
 Preprocessing library GLUT-2.7.0.1...
 GHCi, version 7.10.1: http://www.haskell.org/ghc/  :? for help
 ghc: panic! (the 'impossible' happened)
   (GHC version 7.10.1 for x86_64-apple-darwin):
         Loading temp shared object failed:
 dlopen(/var/folders/gb/2s37knjd0kjg9w40npfwkh0c0000gn/T/ghc92017_0/libghc92017_1.dylib,
 5): Symbol not found: _glutBitmap8By13
   Referenced from:
 /var/folders/gb/2s37knjd0kjg9w40npfwkh0c0000gn/T/ghc92017_0/libghc92017_1.dylib
   Expected in: flat namespace
  in
 /var/folders/gb/2s37knjd0kjg9w40npfwkh0c0000gn/T/ghc92017_0/libghc92017_1.dylib

 Please report this as a GHC bug:  http://www.haskell.org/ghc/reportabug
 }}}

--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/10568#comment:13>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler


More information about the ghc-tickets mailing list