Package abi hash and interface file versions

Joachim Breitner nomeata at
Wed Jul 13 14:09:58 CEST 2011

Dear Simon,

Am Mittwoch, den 13.07.2011, 09:11 +0100 schrieb Simon Marlow:
> On 11/07/2011 21:56, Joachim Breitner wrote:
> > in Debian, we use the ghc-pkg ABI hashes to find out what packages we
> > need to rebuild when. So far, the system has worked great. But now
> > something unfortunate happened: Yesterday, I upgraded ghc from 7.0.3 to
> > 7.0.4. The ABI hash of base and other libraries changed only on amd64
> > and kfreebsd-amd64, while they stays unmodified on the other
> > architectures. That by itself is interesting, but nothing to worry
> > about, as I assumed that the hashes ensure that packages are rebuild
> > where required.
> >
> > But now I see this build log:
> >
> > with the relevant line:
> > Text/ParserCombinators/MTLParse/MTLParseCore.hs:69:1:
> >      Bad interface file: /usr/lib/haskell-packages/ghc/lib/mtl-
> >          mismatched interface file versions (wanted "7004", got "7003")
> I don't quite understand - how did 7.0.4 come to be using packages from 
> 7.0.3?  The packages go into different directories don't they?

not here, and not any more. I was assuming that I can use the same
packages across the two versions and changed the path (ghclibdir) to
make that happen, hoping to avoid needless recompilations. You are right
that this cannot happen with default settings.

> Perhaps we should factor the version into the ABI hash.  But I'd like to 
> understand more about how things are going wrong for you - I think your 
> use case is one we hadn't considered.

Even if you do not plan to support modules across minor versions of ghc,
I’d like to get that into the hash. This would save us the trouble of
tracking which package was built with what version of ghc and the same
rebuild logic would apply that already handles the case of updated
package dependencies.


Joachim "nomeata" Breitner
Debian Developer
  nomeata at | ICQ# 74513189 | GPG-Keyid: 4743206C
  JID: nomeata at |
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part
URL: <>

More information about the Glasgow-haskell-users mailing list