
11 Dec
2008
11 Dec
'08
8:19 p.m.
On Fri, 2008-12-12 at 01:01 +0000, Duncan Coutts wrote:
On Fri, 2008-12-12 at 01:01 +0100, Sean Leather wrote:
Call the original haddockHook with the updated flags rather than the haddock command.
No change in output.
Ah, sorry I misread the code. This works:
Or simpler: import Distribution.Simple import Distribution.Simple.LocalBuildInfo (LocalBuildInfo(withPrograms)) import Distribution.Simple.Program (userSpecifyArgs) main = defaultMainWithHooks simpleUserHooks { haddockHook = \pkg lbi h f -> let progs = userSpecifyArgs "haddock" ["--optghc=-D__HADDOCK__"] (withPrograms lbi) in haddockHook simpleUserHooks pkg lbi { withPrograms = progs } h f }