X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=ghc%2Fcompiler%2Fmain%2FDriverState.hs;h=e8f83a21f6b2ba147af400fb56c7cd87e267b76c;hb=7cbba64b65967d947f5b028c80c0e2320376aabd;hp=78ee4d30d9e7aa7aae1e3b29e864541b50fd07f7;hpb=957bf3756ffd56f5329a2aabe1022d6f996dd641;p=ghc-hetmet.git diff --git a/ghc/compiler/main/DriverState.hs b/ghc/compiler/main/DriverState.hs index 78ee4d3..e8f83a2 100644 --- a/ghc/compiler/main/DriverState.hs +++ b/ghc/compiler/main/DriverState.hs @@ -1,5 +1,5 @@ ----------------------------------------------------------------------------- --- $Id: DriverState.hs,v 1.90 2003/02/04 15:09:40 simonpj Exp $ +-- $Id: DriverState.hs,v 1.96 2003/09/04 11:08:47 simonmar Exp $ -- -- Settings for the driver -- @@ -47,6 +47,7 @@ data GhcMode | DoMake -- ghc --make | DoInteractive -- ghc --interactive | DoLink -- [ the default ] + | DoEval String -- ghc -e deriving (Eq,Show) GLOBAL_VAR(v_GhcMode, DoLink, GhcMode) @@ -95,6 +96,8 @@ GLOBAL_VAR(v_Scale_sizes_by, 1.0, Double) GLOBAL_VAR(v_Static, True, Bool) GLOBAL_VAR(v_NoLink, False, Bool) GLOBAL_VAR(v_NoHsMain, False, Bool) +GLOBAL_VAR(v_MainModIs, Nothing, Maybe String) +GLOBAL_VAR(v_MainFunIs, Nothing, Maybe String) GLOBAL_VAR(v_Recomp, True, Bool) GLOBAL_VAR(v_Collect_ghc_timing, False, Bool) GLOBAL_VAR(v_Do_asm_mangling, True, Bool) @@ -211,7 +214,6 @@ hsc_minusNoO_flags = hsc_minusO_flags = [ "-fignore-asserts", - "-ffoldr-build-on", "-fdo-eta-reduction", "-fdo-lambda-eta-expansion", "-fcase-merge", @@ -466,8 +468,8 @@ mungePackagePaths top_dir ps = map munge_pkg ps munge_paths = map munge_path munge_path p - | Just p' <- my_prefix_match "$libdir" p = top_dir ++ p' - | otherwise = p + | Just p' <- maybePrefixMatch "$libdir" p = top_dir ++ p' + | otherwise = p -- ----------------------------------------------------------------------------- @@ -478,7 +480,12 @@ mungePackagePaths top_dir ps = map munge_pkg ps -- earlier packages may depend on later ones, but not vice versa GLOBAL_VAR(v_ExplicitPackages, initPackageList, [PackageName]) -initPackageList = [rtsPackage] +initPackageList = [basePackage, rtsPackage] + -- basePackage is part of this list entirely because of + -- wired-in names in GHCi. See the notes on wired-in names in + -- Linker.linkExpr. By putting the base backage in initPackageList + -- we make sure that it'll always by linked. + -- add a package requested from the command-line addPackage :: String -> IO () @@ -773,7 +780,9 @@ way_details = (WaySMP, Way "s" "SMP" [ "-fsmp" , "-optc-pthread" +#ifndef freebsd_TARGET_OS , "-optl-pthread" +#endif , "-optc-DSMP" , "-fvia-C" ]),