X-Git-Url: http://git.megacz.com/?p=ghc-hetmet.git;a=blobdiff_plain;f=compiler%2Fmain%2FDriverPipeline.hs;h=16a172598351af288384511ed61ff21e0f9b0c8a;hp=67ef57d70d6ec0e866dfff9d2c792c0cf081d521;hb=b1ab4b8a607addc4d097588db5761313c996a41f;hpb=aee2068e034aca6ddaf6f20f85902137ecf718b7 diff --git a/compiler/main/DriverPipeline.hs b/compiler/main/DriverPipeline.hs index 67ef57d..16a1725 100644 --- a/compiler/main/DriverPipeline.hs +++ b/compiler/main/DriverPipeline.hs @@ -30,7 +30,6 @@ import Packages import HeaderInfo import DriverPhases import SysTools -import qualified SysTools import HscMain import Finder import HscTypes @@ -60,7 +59,6 @@ import Control.Monad import Data.List ( isSuffixOf ) import Data.Maybe import System.Exit -import System.Cmd import System.Environment -- --------------------------------------------------------------------------- @@ -250,7 +248,7 @@ compileStub dflags mod location = do -- --------------------------------------------------------------------------- -- Link -link :: GhcMode -- interactive or batch +link :: GhcLink -- interactive or batch -> DynFlags -- dynamic flags -> Bool -- attempt linking in batch mode? -> HomePackageTable -- what to link @@ -264,15 +262,15 @@ link :: GhcMode -- interactive or batch -- will succeed. #ifdef GHCI -link Interactive dflags batch_attempt_linking hpt +link LinkInMemory dflags batch_attempt_linking hpt = do -- Not Linking...(demand linker will do the job) return Succeeded #endif -link JustTypecheck dflags batch_attempt_linking hpt +link NoLink dflags batch_attempt_linking hpt = return Succeeded -link BatchCompile dflags batch_attempt_linking hpt +link LinkBinary dflags batch_attempt_linking hpt | batch_attempt_linking = do let @@ -317,7 +315,7 @@ link BatchCompile dflags batch_attempt_linking hpt -- Don't showPass in Batch mode; doLink will do that for us. let link = case ghcLink dflags of MkDLL -> doMkDLL - StaticLink -> staticLink + LinkBinary -> staticLink link dflags obj_files pkg_deps debugTraceMsg dflags 3 (text "link: done") @@ -377,7 +375,7 @@ doLink dflags stop_phase o_files | otherwise = case ghcLink dflags of NoLink -> return () - StaticLink -> staticLink dflags o_files link_pkgs + LinkBinary -> staticLink dflags o_files link_pkgs MkDLL -> doMkDLL dflags o_files link_pkgs where -- Always link in the haskell98 package for static linking. Other @@ -1106,18 +1104,18 @@ mk_pvm_wrapper_script pvm_executable pvm_executable_base sysMan = unlines $ "", "args: while ($a = shift(@ARGV)) {", " if ( $a eq '+RTS' ) {", - " $in_RTS_args = 1;", + " $in_RTS_args = 1;", " } elsif ( $a eq '-RTS' ) {", - " $in_RTS_args = 0;", + " $in_RTS_args = 0;", " }", " if ( $a eq '-d' && $in_RTS_args ) {", - " $debug = '-';", + " $debug = '-';", " } elsif ( $a =~ /^-qN(\\d+)/ && $in_RTS_args ) {", - " $nprocessors = $1;", + " $nprocessors = $1;", " } elsif ( $a =~ /^-qp(\\d+)/ && $in_RTS_args ) {", - " $nprocessors = $1;", + " $nprocessors = $1;", " } else {", - " push(@nonPVM_args, $a);", + " push(@nonPVM_args, $a);", " }", "}", "",