cabal: question on compiling build prerequisites
hesselink at gmail.com
Sun Dec 8 20:37:33 UTC 2013
On Sun, Dec 8, 2013 at 7:50 PM, Peter Selinger <selinger at mathstat.dal.ca> wrote:
> thanks for your reply! So say my package directory contains two files:
> What you are suggesting is:
> ghc Test.hs -F -pgmF ./PreProc
> However, this gives the error message:
> ghc: could not execute: ./PreProc
> And indeed, while GHC is smart enough to automatically run a
> preprocessor, it is not smart enough to automatically *compile* the
> preprocessor. So it needs to be compiled beforehand, which would be
> Cabal's job.
Not per se. You could try making it executable, and prepending a line like:
That way you can run your preprocessor like a script, without compiling it.
More information about the cabal-devel