X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=compiler%2Fmain%2FSysTools.lhs;h=49dd4275bcef2fed73abdc8ea5c0a1cb9fd05a64;hb=79b22beb4d2eca1877d99d55838ba6ce69658405;hp=88d42eef70e72aadcce3bb3c8d61d17856b180bb;hpb=c933c909cbc122e63a055afed55969234422521a;p=ghc-hetmet.git diff --git a/compiler/main/SysTools.lhs b/compiler/main/SysTools.lhs index 88d42ee..49dd427 100644 --- a/compiler/main/SysTools.lhs +++ b/compiler/main/SysTools.lhs @@ -222,7 +222,7 @@ initSysTools mbMinusB dflags0 -- gcc can cope -- (see comments with declarations of global variables) gcc_b_arg = Option ("-B" ++ installed "gcc-lib/") - gcc_mingw_include_arg = Option ("-I" ++ installed "include/mingw/") + gcc_mingw_include_arg = Option ("-I" ++ installed "include/mingw") (gcc_prog,gcc_args) | isWindowsHost && am_installed -- We tell gcc where its specs file + exes are (-B) @@ -350,8 +350,11 @@ runCpp :: DynFlags -> [Option] -> IO () runCpp dflags args = do let (p,args0) = pgm_P dflags args1 = args0 ++ args - mb_env <- getGccEnv args1 - runSomethingFiltered dflags id "C pre-processor" p args1 mb_env + args2 = if dopt Opt_WarnIsError dflags + then Option "-Werror" : args1 + else args1 + mb_env <- getGccEnv args2 + runSomethingFiltered dflags id "C pre-processor" p args2 mb_env runPp :: DynFlags -> [Option] -> IO () runPp dflags args = do