[Haskell-cafe] Cabal, GHC and Preprocessors

Ashley Yakeley ashley at semantic.org
Mon Apr 12 04:20:56 EDT 2010


On Mon, 2010-04-12 at 06:51 +0100, Malcolm Wallace wrote:
> Even without that, it may be possible to get what you want, using
>     -pgmPcpphs -optP-cpp -optP-ansi
> that is, to override ghc's addition of -traditional with -ansi.   
> However I'm not sure exactly what order the preprocessor arguments  
> will reach cpphs - in a choice between -traditional and -ansi, it is  
> the last one on the cpphs commandline that will take effect.

This worked in my .cabal file:

cpp-options: --cpp -ansi
ghc-options: -pgmPcpphs

Thanks!

-- 
Ashley Yakeley



More information about the Haskell-Cafe mailing list