1 {-# LANGUAGE OverloadedStrings #-}
3 module Main
(main
) where
5 import Distribution
.Simple
6 import Distribution
.Simple
.LocalBuildInfo
7 import Distribution
.Simple
.PreProcess
8 import Distribution
.Simple
.Program
9 import Distribution
.Types
.BuildInfo
10 import Distribution
.Verbosity
12 import System
.Directory
14 ppHGen
:: BuildInfo
-> LocalBuildInfo
-> ComponentLocalBuildInfo
-> PreProcessor
15 ppHGen _bi lbi _clbi
= PreProcessor
16 { platformIndependent
= True
17 , ppOrdering
= unsorted
18 , runPreProcessor
= mkSimplePreProcessor
$ \inFile outFile verbosity
->
19 copyFile inFile outFile
23 main
= defaultMainWithHooks simpleUserHooks
24 { hookedPreProcessors
= ("hgen", ppHGen
) : hookedPreProcessors simpleUserHooks