[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Bug#232727: ghc6: ghci doesn't start on Alpha



tag 232727 +help
thanks

On Sat, Feb 14, 2004 at 07:19:13PM -0600, John Goerzen wrote:
> Package: ghc6
> Version: 6.2-3
> Severity: important
> 
> Consider this:
> 
> erwin ~$ ghci
>    ___         ___ _
>   / _ \ /\  /\/ __(_)
>  / /_\// /_/ / /  | |      GHC Interactive, version 6.2, for Haskell 98.
> / /_\\/ __  / /___| |      http://www.haskell.org/ghc/
> \____/\/ /_/\____/|_|      Type :? for help.
> 
> Loading package base ... /usr/lib/ghc-6.2/HSbase.o: unsupported ELF
> format
> ghc-6.2: panic! (the `impossible' happened, GHC version 6.2):
>         loadObj: failed
> 
> Please report it as a compiler bug to glasgow-haskell-bugs@haskell.org,
> or http://sourceforge.net/projects/ghc/.
> 
> 
> Very strange.  ghci works fine on my i386 box.
> 
> erwin ~$ file /usr/lib/ghc-6.2/HSbase.o
> /usr/lib/ghc-6.2/HSbase.o: ELF 64-bit LSB relocatable, Alpha
> (unofficial), version 1 (SYSV), not stripped

Unfortunately GHC doesn't use dlopen/dlsym
(http://www.haskell.org/pipermail/cvs-fptools/2000-November/000032.html),
instead using its own hand-written linker. This needs support for each
arch to be added separately. I've never hacked on this before, but
thought I'd give it a go.

However, I seem to have stumbled at the first hurdle - finding
alpha-specific ELF docs! It looks like
http://www.linuxbase.org/spec/refspecs/ had the same problem. If anyone
can point me at such a thing then that would be good  :-)

Of course, if anyone is familiar with these things and is willing to
spend some time on it then that would be great! The latest version of
the file in question is at
http://cvs.haskell.org/cgi-bin/cvsweb.cgi/fptools/ghc/rts/Linker.c?rev=1.145&content-type=text/x-cvsweb-markup
(search for R_SPARC_WDISP30 to find the relevant bit) - if you get in
touch I can give you some more details.


Thanks
Ian (not on debian-alpha)



Reply to: