1. 21 Mar, 2005 1 commit
    • simonmar's avatar
      [project @ 2005-03-21 10:50:22 by simonmar] · 50159f6c
      simonmar authored
      Complete the transition of -split-objs into a dynamic flag (looks like I
      half-finished it in the last commit).
      
      Also: complete the transition of -tmpdir into a dynamic flag, which
      involves some rearrangement of code from SysTools into DynFlags.
      
      Someday, initSysTools should move wholesale into initDynFlags, because
      most of the state that it initialises is now part of the DynFlags
      structure, and the rest could be moved in easily.
      50159f6c
  2. 18 Mar, 2005 1 commit
    • simonmar's avatar
      [project @ 2005-03-18 13:37:27 by simonmar] · d1c1b7d0
      simonmar authored
      Flags cleanup.
      
      Basically the purpose of this commit is to move more of the compiler's
      global state into DynFlags, which is moving in the direction we need
      to go for the GHC API which can have multiple active sessions
      supported by a single GHC instance.
      
      Before:
      
      $ grep 'global_var' */*hs | wc -l
           78
      
      After:
      
      $ grep 'global_var' */*hs | wc -l
           27
      
      Well, it's an improvement.  Most of what's left won't really affect
      our ability to host multiple sessions.
      
      Lots of static flags have become dynamic flags (yay!).  Notably lots
      of flags that we used to think of as "driver" flags, like -I and -L,
      are now dynamic.  The most notable static flags left behind are the
      "way" flags, eg. -prof.  It would be nice to fix this, but it isn't
      urgent.
      
      On the way, lots of cleanup has happened.  Everything related to
      static and dynamic flags lives in StaticFlags and DynFlags
      respectively, and they share a common command-line parser library in
      CmdLineParser.  The flags related to modes (--makde, --interactive
      etc.) are now private to the front end: in fact private to Main
      itself, for now.
      d1c1b7d0
  3. 22 Feb, 2005 1 commit
    • simonpj's avatar
      [project @ 2005-02-22 16:29:41 by simonpj] · fed0cc3f
      simonpj authored
      -------------------------------------------------------
      	Change -include-prelude to -include-pkg-deps for ghc -M
      	-------------------------------------------------------
      
      	Merge to STABLE
      
      This commit just renames the flag for ghc -M to something more
      sensible.
      fed0cc3f
  4. 15 Feb, 2005 1 commit
  5. 04 Feb, 2005 1 commit
  6. 02 Feb, 2005 1 commit
  7. 27 Jan, 2005 2 commits
    • simonmar's avatar
      [project @ 2005-01-27 14:38:29 by simonmar] · 2cf37ff9
      simonmar authored
      Fix explicit layout
      2cf37ff9
    • simonpj's avatar
      [project @ 2005-01-27 10:44:00 by simonpj] · 508a505e
      simonpj authored
      --------------------------------------------
                Replace hi-boot files with hs-boot files
        	--------------------------------------------
      
      This major commit completely re-organises the way that recursive modules
      are dealt with.
      
        * It should have NO EFFECT if you do not use recursive modules
      
        * It is a BREAKING CHANGE if you do
      
      ====== Warning: .hi-file format has changed, so if you are
      ======		updating into an existing HEAD build, you'll
      ======		need to make clean and re-make
      
      
      The details:  [documentation still to be done]
      
      * Recursive loops are now broken with Foo.hs-boot (or Foo.lhs-boot),
        not Foo.hi-boot
      
      * An hs-boot files is a proper source file.  It is compiled just like
        a regular Haskell source file:
      	ghc Foo.hs		generates Foo.hi, Foo.o
      	ghc Foo.hs-boot		generates Foo.hi-boot, Foo.o-boot
      
      * hs-boot files are precisely a subset of Haskell. In particular:
      	- they have the same import, export, and scoping rules
      	- errors (such as kind errors) in hs-boot files are checked
        You do *not* need to mention the "original" name of something in
        an hs-boot file, any more than you do in any other Haskell module.
      
      * The Foo.hi-boot file generated by compiling Foo.hs-boot is a machine-
        generated interface file, in precisely the same format as Foo.hi
      
      * When compiling Foo.hs, its exports are checked for compatibility with
        Foo.hi-boot (previously generated by compiling Foo.hs-boot)
      
      * The dependency analyser (ghc -M) knows about Foo.hs-boot files, and
        generates appropriate dependencies.  For regular source files it
        generates
      	Foo.o : Foo.hs
      	Foo.o : Baz.hi		-- Foo.hs imports Baz
      	Foo.o : Bog.hi-boot	-- Foo.hs source-imports Bog
      
        For a hs-boot file it generates similar dependencies
      	Bog.o-boot : Bog.hs-boot
      	Bog.o-boot : Nib.hi	-- Bog.hs-boto imports Nib
      
      * ghc -M is also enhanced to use the compilation manager dependency
        chasing, so that
      	ghc -M Main
        will usually do the job.  No need to enumerate all the source files.
      
      * The -c flag is no longer a "compiler mode". It simply means "omit the
        link step", and synonymous with -no-link.
      508a505e
  8. 18 Jan, 2005 1 commit
    • simonpj's avatar
      [project @ 2005-01-18 12:18:11 by simonpj] · ac80e0de
      simonpj authored
      ------------------------
          Reorganisation of hi-boot files
        	------------------------
      
      The main point of this commit is to arrange that in the Compilation
      Manager's dependendency graph, hi-boot files are proper nodes. This
      is important to make sure that we compile everything in the right
      order.  It's a step towards hs-boot files.
      
      * The fundamental change is that CompManager.ModSummary has a new
        field, ms_boot :: IsBootInterface
      
        I also tided up CompManager a bit.  No change to the Basic Plan.
      
        ModSummary is now exported abstractly from CompManager (was concrete)
      
      * Hi-boot files now have import declarations.  The idea is they are
        compulsory, so that the dependency analyser can find them
      
      * I changed an invariant: the Compilation Manager used to ensure that
        hscMain was given a HomePackageTable only for the modules 'below' the
        one being compiled.  This was really only important for instances and
        rules, and it was a bit inconvenient.  So I moved the filter to the
        compiler itself: see HscTypes.hptInstances and hptRules.
      
      * Module Packages.hs now defines
          data PackageIdH
          = HomePackage 		-- The "home" package is the package
       				-- curently being compiled
          | ExtPackage PackageId	-- An "external" package is any other package
      
         It was just a Maybe type before, so this makes it a bit clearer.
      
      * I tried to add a bit better location info to the IfM monad, so that
        errors in interfaces come with a slightly more helpful error message.
        See the if_loc field in TcRnTypes --- and follow-on consequences
      
      * Changed Either to Maybes.MaybeErr in a couple of places (more perspicuous)
      ac80e0de
  9. 14 Jan, 2005 1 commit
    • simonmar's avatar
      [project @ 2005-01-14 17:57:41 by simonmar] · c464eda3
      simonmar authored
      HEADS UP!  You now need to use an up to date Happy from CVS to build
      GHC.  Happy version 1.15 will be released shortly.
      
      Replace the slow hacked up String-based GetImports with one based on
      the real Haskell parser.  This requires a new addition to Happy to
      support parsing partial files.  We now avoid reading each source file
      off the disk twice: once to get its module name and imports, and again
      to parse it.  Instead we just slurp it once, and cache the StringBuffer.
      
      This should result in improved startup times for ghc --make,
      especially when there are lots of source files.
      c464eda3
  10. 26 Nov, 2004 1 commit
    • simonmar's avatar
      [project @ 2004-11-26 16:19:45 by simonmar] · ef5b4b14
      simonmar authored
      Further integration with the new package story.  GHC now supports
      pretty much everything in the package proposal.
      
        - GHC now works in terms of PackageIds (<pkg>-<version>) rather than
          just package names.  You can still specify package names without
          versions on the command line, as long as the name is unambiguous.
      
        - GHC understands hidden/exposed modules in a package, and will refuse
          to import a hidden module.  Also, the hidden/eposed status of packages
          is taken into account.
      
        - I had to remove the old package syntax from ghc-pkg, backwards
          compatibility isn't really practical.
      
        - All the package.conf.in files have been rewritten in the new syntax,
          and contain a complete list of modules in the package.  I've set all
          the versions to 1.0 for now - please check your package(s) and fix the
          version number & other info appropriately.
      
        - New options:
      
      	-hide-package P    sets the expose flag on package P to False
      	-ignore-package P  unregisters P for this compilation
      
      	For comparison, -package P sets the expose flag on package P
              to True, and also causes P to be linked in eagerly.
      
              -package-name is no longer officially supported.  Unofficially, it's
      	a synonym for -ignore-package, which has more or less the same effect
      	as -package-name used to.
      
      	Note that a package may be hidden and yet still be linked into
      	the program, by virtue of being a dependency of some other package.
      	To completely remove a package from the compiler's internal database,
              use -ignore-package.
      
      	The compiler will complain if any two packages in the
              transitive closure of exposed packages contain the same
              module.
      
      	You *must* use -ignore-package P when compiling modules for
              package P, if package P (or an older version of P) is already
              registered.  The compiler will helpfully complain if you don't.
      	The fptools build system does this.
      
         - Note: the Cabal library won't work yet.  It still thinks GHC uses
           the old package config syntax.
      
      Internal changes/cleanups:
      
         - The ModuleName type has gone away.  Modules are now just (a
           newtype of) FastStrings, and don't contain any package information.
           All the package-related knowledge is in DynFlags, which is passed
           down to where it is needed.
      
         - DynFlags manipulation has been cleaned up somewhat: there are no
           global variables holding DynFlags any more, instead the DynFlags
           are passed around properly.
      
         - There are a few less global variables in GHC.  Lots more are
           scheduled for removal.
      
         - -i is now a dynamic flag, as are all the package-related flags (but
           using them in {-# OPTIONS #-} is Officially Not Recommended).
      
         - make -j now appears to work under fptools/libraries/.  Probably
           wouldn't take much to get it working for a whole build.
      ef5b4b14
  11. 30 Sep, 2004 1 commit
    • simonpj's avatar
      [project @ 2004-09-30 10:35:15 by simonpj] · 23f40f0e
      simonpj authored
      ------------------------------------
      	Add Generalised Algebraic Data Types
      	------------------------------------
      
      This rather big commit adds support for GADTs.  For example,
      
          data Term a where
       	  Lit :: Int -> Term Int
      	  App :: Term (a->b) -> Term a -> Term b
      	  If  :: Term Bool -> Term a -> Term a
      	  ..etc..
      
          eval :: Term a -> a
          eval (Lit i) = i
          eval (App a b) = eval a (eval b)
          eval (If p q r) | eval p    = eval q
          		    | otherwise = eval r
      
      
      Lots and lots of of related changes throughout the compiler to make
      this fit nicely.
      
      One important change, only loosely related to GADTs, is that skolem
      constants in the typechecker are genuinely immutable and constant, so
      we often get better error messages from the type checker.  See
      TcType.TcTyVarDetails.
      
      There's a new module types/Unify.lhs, which has purely-functional
      unification and matching for Type. This is used both in the typechecker
      (for type refinement of GADTs) and in Core Lint (also for type refinement).
      23f40f0e
  12. 24 Jun, 2004 1 commit
  13. 17 Nov, 2003 1 commit
  14. 18 Jul, 2003 1 commit
    • simonmar's avatar
      [project @ 2003-07-18 13:18:06 by simonmar] · 2d532e45
      simonmar authored
      Revision to the filename policy changes of yesterday.  This fixes the
      broken stage2 and library builds.
      
      The new story is this:
      
        A Haskell source filename should take the form
      
      	<path>/<basename>.<extension>
      
        where
      
      	<path>      is any directory
      	<basename>  is the name of the module, with dots replaced by slashes.
      	<extension> is ".hs" or ".lhs".
      
        given a source filename in this form, GHC will produce object and
        interface files named respectively:
      
              <hidir>/<basename>.<hisuf>
      	<odir>/<basename>.<osuf>
      
        where
      
      	<hidir>   is the value of the -hidir flag, if one was given, or
      		  the value of <path> from the source file otherwise.
      
      	<odir>    the same, for the -odir flag.
      
              <osuf>	  the object suffix (settable with the -osuf flag)
      	<hisuf>   the hi suffix (settable with the -hisuf flag)
      
      For example, if I have a module A.B.C, in source file foo/A/B/C.hs,
      then GHC will create foo/A/B/C.hi and foo/A/B/C.o.
      
      If GHC is given a source filename which is *not* of the form
      <path>/<basename>.<extension>, then it uses a different strategy.
      This happens if the filename does not follow the module name.  In this
      case, GHC will set <path> to be the directory in which the source file
      resides, and <basename> to the module name with dots replaced by
      slashes, and then use the rules above.
      
      For example, if we put module A.B.C in foo/bar/baz.hs, then GHC will
      produce foo/bar/A/B/C.o and foo/bar/A/B/C.hi.
      2d532e45
  15. 17 Jul, 2003 1 commit
    • simonmar's avatar
      [project @ 2003-07-17 12:04:50 by simonmar] · 6677029a
      simonmar authored
      Filename-related cleanup & fixes
      --------------------------------
      
      This commit rationalises some of our filename policies.  The new story
      is this:
      
        When compiling a Haskell module A.B.C:
      
          The object file is placed in <obj-path>/A/B/C.o
          The interface file is placed in <hi-path>/A/B/C.hi
      
          Where <objpath> is
      	- the argument of the -odir flag, if one was given
      	- the element of the search path in which the source file was found,
      	  when in --make mode.
      	- "." otherwise.
      
          Where <hipath> is
      	- the argument of the -hidir flag, if one was given
      	- the element of the search path in which the source file was found,
      	  when in --make mode.
      	- "." otherwise.
      
      NOTE, in particular, that the name of the source file has no bearing
      on the name of the object or interface file any more.  This is a
      nchange from the previous semantics, where the name of the object file
      would, under certain circumstances, follow the name of the source file.
      
      eg. before, if you said
      
      	ghc -c dir/foo.hs
      
      you would get dir/foo.o.  Now, you get something like Main.o,
      depending on what module is in foo.hs.  This means that the driver
      pipeline machinery now needs to pass around a Maybe ModLocation, which
      is filled in by the Hsc phase and used later on to figure out the name
      of the object file (this was fairly painful, but seems to be the only
      way to get the right behaviour).
      6677029a
  16. 04 Jun, 2003 1 commit
    • simonmar's avatar
      [project @ 2003-06-04 15:47:58 by simonmar] · 70b6c54b
      simonmar authored
      Grrr, started off making a small bugfix and ended up doing a major
      cleanup operartion.
      
      Anyway, the problem was that -odir wasn't putting the object files in
      the right place when the module in question has a hierarchical name.
      This was due to the object filename being generated in two different
      places: once by the compilation pipeline machinery, and again in the
      Finder.  It now works properly when --make is used; I haven't managed
      to fix it for one-shot compilations though (some replumbing is
      needed).
      
      While I was here, I cleaned up the compilation pipeline machinery
      somewhat.  The previous scheme of generating a data structure
      representing the phases that need to be executed before actually
      executing them was wrong because the structure of the pipeline can
      change while it is being executed (eg. if we see {-# OPTIONS -fasm #-}
      during the CPP phase).  There were various hacks to deal with this,
      but it turned out to be quite messy.
      
      So the new story is that each compilation phase returns the name of
      the next phase to execute, and also figures out which file to put its
      output in.  This unfortunately means that the knowledge about what
      phases are done in what order is now spread throughout the module, but
      there are fewer hacks at the higher levels, and overall it seems to be
      an improvement.
      70b6c54b
  17. 08 Jan, 2003 1 commit
    • simonmar's avatar
      [project @ 2003-01-08 15:28:04 by simonmar] · b1f1b152
      simonmar authored
      Improve missing-module error messages.  eg.
      
      hello2.hs:1:
          Failed to load interface for `Foo':
              Could not find interface file for `Foo'
              (use -v to see a list of the files searched for)
      
      and if we add the -v flag:
      
      hello2.hs:1:
          Failed to load interface for `Foo':
              Could not find interface file for `Foo'
              locations searched:
                  Foo.hi
                  Foo.hi-boot-6
                  Foo.hi-boot
                  /home/simonmar/builds/i386-unknown-linux/libraries/haskell-src/Foo.hi
                  /home/simonmar/builds/i386-unknown-linux/libraries/haskell98/Foo.hi
                  /home/simonmar/builds/i386-unknown-linux/libraries/readline/Foo.hi
                  /home/simonmar/builds/i386-unknown-linux/libraries/unix/Foo.hi
                  /home/simonmar/builds/i386-unknown-linux/libraries/network/Foo.hi
                  /home/simonmar/builds/i386-unknown-linux/libraries/base/Foo.hi
      b1f1b152
  18. 08 Nov, 2002 1 commit
  19. 17 Oct, 2002 1 commit
    • simonmar's avatar
      [project @ 2002-10-17 14:26:16 by simonmar] · 06575d67
      simonmar authored
      Finder overhaul.
      
      The finder had got pretty complicated; this commit is mainly a
      cleanup, with one new feature:
      
        - the finder has a cache (again).  The cache may be flushed by
          calling flushFinderCache, which actually only flushes home modules
          from the cache, because package modules are assumed not to move.
          This change is apropos of some other changes which will result in
          the finder being called more often, so we think a cache is going
          to be worthwhile.
      
      Also a couple of bugs were fixed:
      
        - the field ml_hi_file in a ModLocation is now *always* the name
          of the .hi file.  If you need a .hi-boot file, you have to make
          it up by changing the suffix of ml_hi_file.  (DriverMkDepend and
          RnHiFiles do this).  This was the cause of a bug, but I can't
          remember the details.
      
        - The -odir flag now works in a more reasonable way: hierarchical
          modules get put in subdirectories of the -odir directory.  eg.
          if your module is A.B.C, and -odir D is specified, then the object
          will be D/A/B/C.o; previously it would have been D/C.o.
      06575d67
  20. 09 Oct, 2002 1 commit
    • simonpj's avatar
      [project @ 2002-10-09 15:03:48 by simonpj] · 8c1b6bd7
      simonpj authored
      -----------------------------------
      	Lots more Template Haskell stuff
      	-----------------------------------
      
      At last!  Top-level declaration splices work!
      Syntax is
      
      	$(f x)
      
      not "splice (f x)" as in the paper.
      
      Lots jiggling around, particularly with the top-level plumbining.
      Note the new data type HsDecls.HsGroup.
      8c1b6bd7
  21. 18 Sep, 2002 1 commit
    • simonmar's avatar
      [project @ 2002-09-18 10:51:01 by simonmar] · fb1b5b07
      simonmar authored
      Fix up exception handling when reading an interface file, and make it
      compile with 4.08.x again.
      
      GhcExceptions weren't being caught by readIface, so an error when
      reading an interface could be unintentionally fatal (errors should be
      soft when reading the old interface file for the current module).
      Also, the Interrupted exception should not be caught by readIface,
      because we want ^C to behave as normal when reading interface files
      (currently it causes an interface-file read error rather than
      interrupting the whole compiler).
      
      Some exception-related compatibility functions have been moved from
      Util to Panic.
      fb1b5b07
  22. 13 Sep, 2002 1 commit
    • simonpj's avatar
      [project @ 2002-09-13 15:02:25 by simonpj] · 9af77fa4
      simonpj authored
      --------------------------------------
      	Make Template Haskell into the HEAD
      	--------------------------------------
      
      This massive commit transfers to the HEAD all the stuff that
      Simon and Tim have been doing on Template Haskell.  The
      meta-haskell-branch is no more!
      
      WARNING: make sure that you
      
        * Update your links if you are using link trees.
          Some modules have been added, some have gone away.
      
        * Do 'make clean' in all library trees.
          The interface file format has changed, and you can
          get strange panics (sadly) if GHC tries to read old interface files:
          e.g.  ghc-5.05: panic! (the `impossible' happened, GHC version 5.05):
      	  Binary.get(TyClDecl): ForeignType
      
        * You need to recompile the rts too; Linker.c has changed
      
      
      However the libraries are almost unaltered; just a tiny change in
      Base, and to the exports in Prelude.
      
      
      NOTE: so far as TH itself is concerned, expression splices work
      fine, but declaration splices are not complete.
      
      
      		---------------
      		The main change
      		---------------
      
      The main structural change: renaming and typechecking have to be
      interleaved, because we can't rename stuff after a declaration splice
      until after we've typechecked the stuff before (and the splice
      itself).
      
      * Combine the renamer and typecheker monads into one
      	(TcRnMonad, TcRnTypes)
        These two replace TcMonad and RnMonad
      
      * Give them a single 'driver' (TcRnDriver).  This driver
        replaces TcModule.lhs and Rename.lhs
      
      * The haskell-src library package has a module
      	Language/Haskell/THSyntax
        which defines the Haskell data type seen by the TH programmer.
      
      * New modules:
      	hsSyn/Convert.hs 	converts THSyntax -> HsSyn
      	deSugar/DsMeta.hs 	converts HsSyn -> THSyntax
      
      * New module typecheck/TcSplice type-checks Template Haskell splices.
      
      		-------------
      		Linking stuff
      		-------------
      
      * ByteCodeLink has been split into
      	ByteCodeLink	(which links)
      	ByteCodeAsm	(which assembles)
      
      * New module ghci/ObjLink is the object-code linker.
      
      * compMan/CmLink is removed entirely (was out of place)
        Ditto CmTypes (which was tiny)
      
      * Linker.c initialises the linker when it is first used (no need to call
        initLinker any more).  Template Haskell makes it harder to know when
        and whether to initialise the linker.
      
      
      	-------------------------------------
      	Gathering the LIE in the type checker
      	-------------------------------------
      
      * Instead of explicitly gathering constraints in the LIE
      	tcExpr :: RenamedExpr -> TcM (TypecheckedExpr, LIE)
        we now dump the constraints into a mutable varabiable carried
        by the monad, so we get
      	tcExpr :: RenamedExpr -> TcM TypecheckedExpr
      
        Much less clutter in the code, and more efficient too.
        (Originally suggested by Mark Shields.)
      
      
      		-----------------
      		Remove "SysNames"
      		-----------------
      
      Because the renamer and the type checker were entirely separate,
      we had to carry some rather tiresome implicit binders (or "SysNames")
      along inside some of the HsDecl data structures.  They were both
      tiresome and fragile.
      
      Now that the typechecker and renamer are more intimately coupled,
      we can eliminate SysNames (well, mostly... default methods still
      carry something similar).
      
      		-------------
      		Clean up HsPat
      		-------------
      
      One big clean up is this: instead of having two HsPat types (InPat and
      OutPat), they are now combined into one.  This is more consistent with
      the way that HsExpr etc is handled; there are some 'Out' constructors
      for the type checker output.
      
      So:
      	HsPat.InPat	--> HsPat.Pat
      	HsPat.OutPat	--> HsPat.Pat
      	No 'pat' type parameter in HsExpr, HsBinds, etc
      
      	Constructor patterns are nicer now: they use
      		HsPat.HsConDetails
      	for the three cases of constructor patterns:
      		prefix, infix, and record-bindings
      
      	The *same* data type HsConDetails is used in the type
      	declaration of the data type (HsDecls.TyData)
      
      Lots of associated clean-up operations here and there.  Less code.
      Everything is wonderful.
      9af77fa4
  23. 29 Aug, 2002 1 commit
    • simonmar's avatar
      [project @ 2002-08-29 15:44:11 by simonmar] · ce9687a5
      simonmar authored
      Housekeeping:
      
        - The main goal is to remove dependencies on hslibs for a
          bootstrapped compiler, leaving only a requirement that the
          packages base, haskell98 and readline are built in stage 1 in
          order to bootstrap.  We're almost there: Posix is still required
          for signal handling, but all other dependencies on hslibs are now
          gone.
      
          Uses of Addr and ByteArray/MutableByteArray array are all gone
          from the compiler.  PrimPacked defines the Ptr type for GHC 4.08
          (which didn't have it), and it defines simple BA and MBA types to
          replace uses of ByteArray and MutableByteArray respectively.
      
        - Clean up import lists.  HsVersions.h now defines macros for some
          modules which have moved between GHC versions.  eg. one now
          imports 'GLAEXTS' to get at unboxed types and primops in the
          compiler.
      
          Many import lists have been sorted as per the recommendations in
          the new style guidelines in the commentary.
      
      I've built the compiler with GHC 4.08.2, 5.00.2, 5.02.3, 5.04 and
      itself, and everything still works here.  Doubtless I've got something
      wrong, though.
      ce9687a5
  24. 21 Mar, 2002 1 commit
  25. 20 Mar, 2002 1 commit
  26. 05 Mar, 2002 1 commit
  27. 05 Feb, 2002 1 commit
  28. 04 Dec, 2001 1 commit
  29. 03 Aug, 2001 1 commit
    • sof's avatar
      [project @ 2001-08-03 07:44:47 by sof] · 65142ed3
      sof authored
      Make dependency generation work a little bit better
      (stage1 goes through OK; yet to do a stage2, but
      thought I'd commit before I hit the sack).
      65142ed3
  30. 02 Aug, 2001 1 commit
  31. 26 Jun, 2001 1 commit
  32. 14 Jun, 2001 1 commit
    • simonpj's avatar
      [project @ 2001-06-14 12:50:05 by simonpj] · 16d5d1c7
      simonpj authored
      ----------------------
      	Installation packaging
      	----------------------
      
      GHC runs various system programs like
      	cp, touch
      	gcc, as, ld etc
      
      On Windows we plan to deliver these programs along with GHC,
      so we have to be careful about where to find them.
      
      This commit isolates all these dependencies in a single module
      
      	main/SysTools.lhs
      
      Most of the #ifdefery for mingw has moved into this module.
      There's some documentation in SysTools.lhs
      
      Along the way I did lots of other cleanups.  In particular
      
        * There is no more 'globbing' needed when calling runSomething
        * All file removal goes via the standard Directory.removeFile
        * TmpFiles.hs has gone; absorbed into SysTools
        * Some DynFlag stuff has moved from DriverFlags to CmdLineOpts
      
      
      Still to do:
      
        **	I'm a bit concerned that calling removeFile one at a time
      	when deleting masses of split-object files is going to be
      	rather slow
      
        **	GHC now expects to find split,mangle,unlit in
      		libdir/extra-bin
      	instead of just
      		libdir
      
      	So something needs to change in the Unix installation scripts
      
        **    The "ineffective C preprocessor" is a perversion and should die
      16d5d1c7
  33. 28 May, 2001 1 commit
    • sof's avatar
      [project @ 2001-05-28 03:31:19 by sof] · 4cef3202
      sof authored
      Misc minor changes to integrate GHC a little bit better on Win32 platforms.
      Specifically, the commit does the following (assuming you've configured
      fptools/ with the option --enable-minimal-unix-deps on a mingw platform):
      
       * when GHC uses System.system, it expects an MSDOS command processor to
         interpret the command. This implies that 'normal' UNIX shell utils will
         no longer be used, but substituted with MSDOS equivalents.
       * the GHC backend relies on gcc and perl to handle .s/.hc/.o/.a files. GHC
         will now assume that these all live in one 'tool directory', making it
         easier to bundle these backend tools with GHC.
      
      The upshot of these changes is that it is now possible for the user not to
      have to install cygwin prior to installing GHC (as the upcoming ghc-win32
      binary release will prove).
      4cef3202
  34. 26 Apr, 2001 1 commit
  35. 28 Mar, 2001 2 commits
    • simonmar's avatar
      [project @ 2001-03-28 16:51:02 by simonmar] · da25d580
      simonmar authored
      Cleaning up error reporting, 2nd attempt.
      
        - The UserError name is already bagged by Exception (for
          userErrors).  So we use ProgramError instead, which is
          more appropriate.
      
        - some previously UserErrors are now CmdLineErrors.  GHCi
          catches CmdLineErrors and prints them without the "ghc: "
          prefix.
      da25d580
    • simonmar's avatar
      [project @ 2001-03-28 11:01:19 by simonmar] · f4eba96b
      simonmar authored
      Clean up GHC's error reporting.
      
        - the GhcException type has some more constructors: CmdLineError,
          UserError, and InstallationError.  OtherError has gone.
      
        - most error messages should begin with "<location>:".  When the
          error is on the command-line or in GHC itself, <location> is
          "ghc", for consistency with std Unix semantics.
      
        - GHCi no longer prints a superfluous "ghc: " before certain error
          messages.
      f4eba96b
  36. 12 Dec, 2000 1 commit
  37. 21 Nov, 2000 1 commit
    • simonmar's avatar
      [project @ 2000-11-21 14:31:58 by simonmar] · e663f7b8
      simonmar authored
      Mostly verbosity changes.
      
      GONE AWAY:  -dshow-passes, -ddump-all, -ddump-most.
      
      NEW:
          -v<n>, where <n> is
      
          0	|   print errors & warnings only
          1   |   minimal verbosity: print "compiling M ... done." for each module.
          2   |   equivalent to -dshow-passes
          3   |   equivalent to existing "ghc -v"
          4   |   "ghc -v -ddump-most"
          5   |   "ghc -v -ddump-all"
      
      4 & 5 are the same at the moment.  -dshow-passes also prints out the
      passes in the driver, and some in the compilation manager.
      e663f7b8
  38. 15 Nov, 2000 1 commit
    • sewardj's avatar
      [project @ 2000-11-15 15:43:30 by sewardj] · d68df63f
      sewardj authored
      Overhaul of CM, reducing the complexity of recursive module machinery.
      Also, don't compute package dependencies at all, and don't pass them
      to the linker.
      d68df63f