Re: getting the -B topdir for a GHC-API app

2006-10-22 Thread Lemmih

On 10/22/06, Mathew Mills <[EMAIL PROTECTED]> wrote:

What is the "right" way to get the topDir for use with the GHC API.
I have a little app that I would like to cabalize and release, but I
am not sure what is the approved way of getting the '-B' option set-up.

I think it would be great if I could use template-haskell to insert
the topDir from the ghc used to compile the app, but I am not sure
how to get the topDir from the compiler.  Is this possible?


You can find the topDir by running: /path/to/ghc --print-libdir

This setup script does almost every thing you need:
http://www.cse.unsw.edu.au/~dons/code/hs-plugins/scripts/Setup-with-ghc.lhs

--
Cheers,
 Lemmih
___
Glasgow-haskell-users mailing list
Glasgow-haskell-users@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users


getting the -B topdir for a GHC-API app

2006-10-22 Thread Mathew Mills
What is the "right" way to get the topDir for use with the GHC API.   
I have a little app that I would like to cabalize and release, but I  
am not sure what is the approved way of getting the '-B' option set-up.


I think it would be great if I could use template-haskell to insert  
the topDir from the ghc used to compile the app, but I am not sure  
how to get the topDir from the compiler.  Is this possible?


Does cabal already provide a means to install a "driver" script like  
that used for the ghc suite?



Also, I am looking for a code-review.  If you have some time, I would  
love some "style" guidance.


The work in progress can be found here:
   http://mathewmills.com/runTests/runTests.lhs


___
Glasgow-haskell-users mailing list
Glasgow-haskell-users@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users