cvs commit: fptools/libraries/Cabal/Distribution/Simple Build.hs

Isaac Jones ijones at haskell.org
Fri Jan 7 02:33:35 EST 2005


ijones      2005/01/06 23:33:35 PST

  Modified files:
    libraries/Cabal/Distribution/Simple Build.hs 
  Log:
  fixed case where two main modules are in the same directory
  
  It's pretty common to have a situation where two modules with
  different filenames are both named Main.  If they're in the same
  directory, and we use the -odir and -hidir flags, ghc --make uses the
  Main.o produced from the first build to link the 2nd!
  
  I added a pretty tricky test case for this, after it was reported by
  Ganes Sittampalam while trying to build the HaXmL executables.
  
  I fixed it today by adding the executable name to the -odir and -hidir
  paths, to make sure that they don't use the same Main.o... this is a
  bit inefficient, though, because I'm pretty sure that means it will
  rebuild any bits of the library it depends on for each executable.
  
  Any objections to this?
  
  Revision  Changes    Path
  1.15      +5 -3      fptools/libraries/Cabal/Distribution/Simple/Build.hs


More information about the Cvs-libraries mailing list