Hi Joerg,

This problem is almost certainly bug #751.

This gives a compiler crash if the threaded run time system
is used.  The latest darwinports ghc (which I maintain) builds
the run time without threads.  What is the output of

sudo port info ghc

?
If you do not have revision 2 of the 6.4.2 portfile, you need to
update:

sudo port selfupdate

If you are running the latest version, your experiences
are... interesting.

Best Wishes,
Greg


On Jul 17, 2006, at 5:36 AM, Joerg van den Hoff wrote:

hi,

my very first tries with ghc, using the 'program'

module Fact where
fact :: Integer -> Integer
fact n = product [1..n]


gave the following compiler crash under MacOS X 10.4.7 (ghc installed from source via DarwinPorts):

Compiling Fact             ( fact.hs, interpreted )
ghc-6.4.2: internal error: scavenge_stack: weird activation record found on stack: 463
    Please report this as a compiler bug.  See:
    http://www.haskell.org/ghc/reportabug


more irritating, this error was _not_ reproducible. a second try did run through:

`ghc -c fact.hs' yielded a file `fact.o'

but `ghc -o fact fact.o' yielded:

/usr/bin/ld: Undefined symbols:
_ZCMain_main_closure
___stginit_ZCMain
collect2: ld returned 1 exit status


and `ghc -v --make fact' yielded


Glasgow Haskell Compiler, Version 6.4.2, for Haskell 98, compiled by GHC version 6.4.2
Using package config file: /opt/local/lib/ghc-6.4.2/package.conf
Using package config file: /Users/vdh/.ghc/powerpc-darwin-6.4.2/ package.conf
Hsc static flags: -static
*** Chasing dependencies:
Chasing modules from: fact
Stable modules:
*** Compiling Fact             ( fact.hs, fact.o ):
compile: input file fact.hs
*** Checking old interface for Fact:
Skipping  Fact             ( fact.hs, fact.o )
*** Deleting temp files
Deleting: /tmp/ghc18926.s
Warning: deleting non-existent /tmp/ghc18926.s
Upsweep completely successful.
*** Deleting temp files
Deleting:
link(batch): upsweep (partially) failed OR
   Main.main not exported; not linking.
*** Deleting temp files
Deleting:


what I got where two files `fact.o' and `fact.hi' (attached).

hope this helps in one way or the other


all the best

joerg van den hoff





<fact.o>
module Fact where
fact :: Integer -> Integer
fact n = product [1..n]
<fact.hi>
_______________________________________________
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs

_______________________________________________
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs

Reply via email to