osx install fail

Hamish Mackenzie hamish at firestream.co.uk
Sat Jul 25 03:01:07 EDT 2009

2009/7/25 erik flister <erik.flister at gmail.com>:
> -i think i figured out the cause of the debugging problem.  when i push the
> 'use ghci debugger to build and run' button, the log prints out "Setup:
> Cannot find the program 'ghc' at 'leksahecho' or on the path".  but ghc is
> on my path, i promise (you've been building, after all!).
> erik-flisters-macbook-pro:~ eflister$ which ghc
> /opt/local/bin/ghc

Actually this is a trick we do to find out the arguments to pass to
GHCi (Cabal does not have a debugging support yet).  We run the normal
build but tell it to use leksahecho (just like echo but by having our
own it works on windows too) as the GHC compiler.  That way it spits
out the command line arguments it wanted to use to stdout.  We process
them a bit and pass them on to GHCi.

So this error indicates the directory containing leksahecho is not in
the path.  The launch script for the .app should add it automatically.
 For your own build you will need to make sure leksahecho is in your
path.  I think I will make it conditionally use "echo" instead on non
windows platforms to relax this restriction.

> -compiling is like 20x slower than in ghc or ghci (which are instantaneous
> for my project vs. ~2sec in leksah).

It could be the time taken to compile Setup.hs.  How does it compare
to "runhaskell Setup.hs build"?
Building when ghci should be fine though as it just sends :reload.

Another possibility is that Leksah is hogging all the RAM.  If you
compile with ghc while Leksah is running is it still fast?

I'll do some tests here with a Hello World app and see if I can reproduce it.


More information about the Leksah mailing list