* Henning Thielemann <lemm...@henning-thielemann.de> [2014-02-28 22:48:59+0100] > Am 28.02.2014 22:31, schrieb Roman Cheplyaka: > >* Henning Thielemann <lemm...@henning-thielemann.de> [2014-02-28 > >22:21:39+0100] > >>>[1]: http://hackage.haskell.org/package/hse-cpp > >> > >>It would still be nicer to have a solution that also works with HSC, > >>CHS and maybe others. I have also not checked LHS so far. > > > >hse-cpp takes care of .lhs, too. As for .hsc and .chs, those are > > handled by cabal. The idea is that hse-cpp adds the same > > transformations to haskell-src-exts as ghc has. > > Nice! Is there a recommended way to transfer CPP options from the > Cabal file to the CpphsOptions record?
Yes, haskell-packages[2] lets you easily create a cabal-integrated "compiler". See the compile method[3] in particular. For an example of how this all glues together, see [4]. [2]: http://hackage.haskell.org/package/haskell-packages [3]: http://hackage.haskell.org/package/haskell-packages-0.2.3.4/docs/Distribution-HaskellSuite-Compiler.html#v:compile [4]: https://github.com/haskell-suite/haskell-names/blob/master/hs-gen-iface/src/hs-gen-iface.hs#L70
signature.asc
Description: Digital signature
_______________________________________________ cabal-devel mailing list cabal-devel@haskell.org http://www.haskell.org/mailman/listinfo/cabal-devel