#1372: Recompilation checker should consider package versions (and other 
factors)
-------------------------+--------------------------------------------------
    Reporter:  bringert  |        Owner:  simonmar  
        Type:  bug       |       Status:  new       
    Priority:  normal    |    Milestone:  6.8 branch
   Component:  Compiler  |      Version:  6.6       
    Severity:  normal    |   Resolution:            
    Keywords:            |   Difficulty:  Unknown   
          Os:  Unknown   |     Testcase:            
Architecture:  Unknown   |  
-------------------------+--------------------------------------------------
Comment (by simonmar):

 Replying to [comment:10 dons]:

 I'd like to understand what happened a bit better, because I think there
 are actually several different issues.  Correct me if I'm wrong, but the
 error in the thread you referred to was caused by:

  * X11-extras was updated, the API was changed, the version was not bumped
  * xmonad was updated to match
  * it failed to compile against the old X11-extras

 that's expected, right?

 And there seems to be some problem with Cabal not noticing when a .hsc
 file has been modified, that sounds like a Cabal bug.

 The problem you described seems slightly different:

  * X11-extras is modified, the version is bumped
  * xmonad is updated to match (with a dependency on the new version)
  * `darcs pull xmonad`
  * without cleaning first, `setup build`

 Now, Cabal doesn't notice that `xmonad.cabal` has been updated, and hence
 doesn't notice that it needs to depend on the new version of X11-extras.
 If this is the case, it's a Cabal bug - Cabal should refuse to build if
 the `.cabal` file has been modified since the last configure.

 I've been thinking about how to solve the original recompilation problem.
 I even hacked up the fix proposed earlier, but then decided it was wrong.
 We can't rely on packages being registered to notice when things change -
 the compiler really needs to look at the `.hi` files.  Ideally, we need to
 create a fingerprint of the interface (hence SimonPJs message to the
 Haskell mailing list about fingerprints).

 None of this will help unless Cabal invokes GHC to do recompilation
 checking: so if Cabal starts doing its own dependency analysis, we'll be
 in trouble again.

-- 
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/1372#comment:13>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
_______________________________________________
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs

Reply via email to