Repository : ssh://darcs.haskell.org//srv/darcs/ghc

On branch  : master

http://hackage.haskell.org/trac/ghc/changeset/5e383469a9cb1fc17af3882f6217e5382a80fc67

>---------------------------------------------------------------

commit 5e383469a9cb1fc17af3882f6217e5382a80fc67
Author: David Terei <[email protected]>
Date:   Sun Mar 4 23:53:37 2012 -0500

    Get correct options when calling 'clang' inplace of 'as' (#5903)

>---------------------------------------------------------------

 compiler/main/DriverPipeline.hs |   13 ++++++++-----
 1 files changed, 8 insertions(+), 5 deletions(-)

diff --git a/compiler/main/DriverPipeline.hs b/compiler/main/DriverPipeline.hs
index fab7600..488df37 100644
--- a/compiler/main/DriverPipeline.hs
+++ b/compiler/main/DriverPipeline.hs
@@ -1176,14 +1176,17 @@ runPhase As input_fn dflags
                         = do
                             llvmVer <- io $ figureLlvmVersion dflags
                             return $ case llvmVer of
-                                Just n | n >= 30 -> SysTools.runClang
-                                _                -> SysTools.runAs
+                                -- using cGccLinkerOpts here but not clear if
+                                -- opt_c isn't a better choice
+                                Just n | n >= 30 ->
+                                    (SysTools.runClang, cGccLinkerOpts)
+
+                                _ -> (SysTools.runAs, getOpts dflags opt_a)
 
                         | otherwise
-                        = return SysTools.runAs
+                        = return (SysTools.runAs, getOpts dflags opt_a)
 
-        as_prog <- whichAsProg
-        let as_opts = getOpts dflags opt_a
+        (as_prog, as_opts) <- whichAsProg
         let cmdline_include_paths = includePaths dflags
 
         next_phase <- maybeMergeStub



_______________________________________________
Cvs-ghc mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/cvs-ghc

Reply via email to