git.iko.soy/typeable/pandoc
on master help sign in
Fixed Interact.hs to handle the cpp macros in UTF8.
492d5e9John MacFarlane
Interact.hs+1−1
@@ -20,7 +20,7 @@ main = do
20 let setupConfig = read $ unlines $ drop 1 $ lines setupConfig'
20 let setupConfig = read $ unlines $ drop 1 $ lines setupConfig'
21 let (Just (ComponentLocalBuildInfo { componentPackageDeps = deps })) = libraryConfig setupConfig
21 let (Just (ComponentLocalBuildInfo { componentPackageDeps = deps })) = libraryConfig setupConfig
22 let packageSpecs = map (toPackageSpec . snd) deps
22 let packageSpecs = map (toPackageSpec . snd) deps
23− let args = ["-cpp","-i../dist/build/autogen"] ++ concatMap (\p -> ["-package",p]) packageSpecs
23+ let args = ["-optP-include", "-optP../dist/build/autogen/cabal_macros.h","-cpp","-I../dist/build/autogen","-i../dist/build/autogen"] ++ concatMap (\p -> ["-package",p]) packageSpecs
24 print args
24 print args
25 ph <- runProcess "ghci" args (Just "src") Nothing Nothing Nothing Nothing
25 ph <- runProcess "ghci" args (Just "src") Nothing Nothing Nothing Nothing
26 waitForProcess ph
26 waitForProcess ph